misc #173
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: Lighthouse CI | |
on: | |
pull_request: | |
branches: [main] | |
jobs: | |
lighthouse: | |
name: Lighthouse Audit | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
- name: Install dependencies | |
run: yarn | |
- name: Start server | |
run: yarn start & | |
- name: Wait for server to be ready | |
run: sleep 10 | |
- name: Lighthouse mobile audit | |
run: yarn lhci:mobile --add-args="--cache-clear" | |
env: | |
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }} | |
- name: Lighthouse desktop audit | |
run: yarn lhci:desktop --add-args="--cache-clear" | |
env: | |
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }} |