Noe/scw login new #1061
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: Typescript CI | |
on: | |
pull_request: | |
branches: | |
- main | |
- release/* | |
paths: | |
- "**/*.ts" | |
- "**/*.tsx" | |
- "package.json" | |
jobs: | |
tsc: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20.x | |
cache: "yarn" | |
- run: yarn | |
- run: yarn typecheck | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20.x | |
cache: "yarn" | |
- run: yarn | |
- run: yarn lint | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20.x | |
cache: "yarn" | |
- run: yarn | |
- run: yarn test | |
performance-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20.x | |
cache: "yarn" | |
- run: | | |
BASELINE_BRANCH=${GITHUB_BASE_REF:="main"} | |
# Required for `git switch` on CI | |
git fetch origin | |
# Gather baseline perf measurements | |
git switch "$BASELINE_BRANCH" | |
yarn | |
yarn reassure --baseline | |
# Gather current perf measurements & compare results | |
git switch --detach - | |
yarn | |
yarn reassure --branch | |
- name: Run Danger.js | |
run: yarn danger ci | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |