deps: bump the safe-dependencies group with 24 updates #223
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 Events | |
on: pull_request | |
permissions: | |
contents: write | |
id-token: write | |
pull-requests: write | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
test-unit: | |
name: Unit tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: ⬇️ Set up code | |
uses: actions/checkout@v4 | |
with: | |
show-progress: false | |
- name: 📦 Setup PNPM | |
uses: pnpm/action-setup@v4 | |
with: | |
version: 9 | |
- name: ⎔ Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
cache: pnpm | |
- name: 📥 Download dependencies | |
run: pnpm i | |
- name: 🧹 Lint | |
run: pnpm run lint | |
- name: 🧪 Run tests | |
run: pnpm test | |
deploy-preview: | |
name: Firebase preview | |
runs-on: ubuntu-latest | |
needs: test-unit | |
if: ${{ github.event.sender.type == 'User' }} | |
environment: | |
name: dev | |
steps: | |
- name: 🚀 Deploy | |
uses: agrc/firebase-website-deploy-composite-action@v1 | |
with: | |
identity-provider: ${{ secrets.IDENTITY_PROVIDER }} | |
service-account-email: ${{ secrets.SERVICE_ACCOUNT_EMAIL }} | |
project-id: ${{ secrets.PROJECT_ID }} | |
preview: yes | |
build-command: pnpm run build:stage | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
rebuild-docs: | |
name: Rebuild config docs | |
runs-on: ubuntu-latest | |
steps: | |
- name: ⬇️ Checkout Code | |
uses: actions/checkout@v4 | |
with: | |
show-progress: false | |
- name: 📦 Setup PNPM | |
uses: pnpm/action-setup@v4 | |
with: | |
version: 9 | |
- name: ⎔ Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
cache: pnpm | |
- name: 📥 Download dependencies | |
run: pnpm i | |
- name: 📚 Update Config Docs | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gh pr checkout ${{ github.event.pull_request.number }} | |
pnpm run update-config-docs | |
if [[ `git status --porcelain` ]]; then | |
git config --global user.email "${{ secrets.UGRC_RELEASE_BOT_EMAIL }}" | |
git config --global user.name "${{ secrets.UGRC_RELEASE_BOT_NAME }}" | |
git add docs | |
git commit -m "docs: update config docs" | |
git push | |
fi |