Merge pull request #23 from highlight/dependabot/npm_and_yarn/babel/t… #54
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
CI: true | |
SSH_AUTH_SOCK: /tmp/ssh_agent.sock | |
USE_SSH: true | |
NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} | |
steps: | |
- name: Begin CI... | |
uses: actions/checkout@v3 | |
- name: Use Node 16 | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 16.x | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "::set-output name=dir::$(yarn cache dir)" | |
- uses: actions/cache@v2 | |
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: yarn install | |
run: | | |
yarn install --frozen-lockfile | |
yarn install --frozen-lockfile --cwd site | |
npx playwright install-deps | |
- name: run lint and tests | |
run: | | |
yarn lint | |
yarn typecheck | |
yarn test --ci | |
yarn e2e | |
- name: Release | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
run: | | |
rm -rf dist | |
npm publish --access=public |