Update uv version for Docker, add comments to workflows (#3487) #185
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: Frontend | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- translate/** | |
- .github/workflows/frontend.yml | |
pull_request: | |
branches: | |
- main | |
paths: | |
- translate/** | |
- .github/workflows/frontend.yml | |
workflow_dispatch: | |
jobs: | |
typescript: | |
name: TypeScript | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: { node-version: '18' } | |
- name: Install dependencies | |
run: npm ci | |
- name: Check TypeScript | |
run: npm run types -- --pretty | |
working-directory: translate | |
- name: build | |
run: npm run build | |
working-directory: translate | |
licenses: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: { node-version: '18' } | |
- name: Install globals | |
run: npm install --global [email protected] | |
- name: Install dependencies | |
run: npm ci | |
- name: Check licenses | |
run: | | |
# --failOn doesn't print the licenses on failure. | |
# Use jq to print only minimal info, then print a summary when | |
# checking for GPL packages. | |
license-checker-rseidelsohn --json | jq -r 'to_entries[] | "\(.key): \(.value.licenses)"' | |
license-checker-rseidelsohn --summary --failOn 'GPL' | |
jest: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: { node-version: '18' } | |
- name: Install globals | |
run: npm install --global npm@8 | |
- name: Install dependencies | |
run: npm ci | |
- name: Test | |
run: npm test --coverage | |
working-directory: translate | |
- uses: codecov/codecov-action@v4 | |
with: | |
flags: frontend | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |