2025 content update #14
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: Pull Request | |
on: | |
pull_request: | |
jobs: | |
setup: | |
name: Setup client | |
runs-on: ubuntu-latest | |
steps: | |
- name: Cancel previous | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ secrets.GITHUB_TOKEN }} | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: "20.x" | |
cache: "npm" | |
cache-dependency-path: "package-lock.json" | |
- name: Install deps | |
run: npm ci | |
- name: Cache node_modules | |
uses: actions/cache/save@v3 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
lint: | |
name: Lint client | |
needs: setup | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: "20.x" | |
- name: Restore node_modules | |
uses: actions/cache/restore@v3 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
fail-on-cache-miss: true | |
- name: Lint JS and Vue | |
run: npm run lint | |
test: | |
name: Test client | |
needs: setup | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: "20.x" | |
- name: Restore node_modules | |
uses: actions/cache/restore@v3 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
fail-on-cache-miss: true | |
- uses: szenius/[email protected] | |
with: | |
timezoneLinux: "America/New_York" | |
- name: Run tests | |
run: npm run test:ci | |
build: | |
name: Build client | |
needs: setup | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: "20.x" | |
- name: Restore node_modules | |
uses: actions/cache/restore@v3 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
fail-on-cache-miss: true | |
- name: Build app | |
run: npm run build |