Bump @babel/core from 7.22.10 to 7.22.11 #111
Workflow file for this run
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
# Workflow used as Continous Integration every time we have a PR. | |
name: Typescript | |
on: | |
# Only build when pushed to main | |
push: | |
branches: | |
- main | |
paths: | |
- 'packages/**' | |
- 'package.json' | |
# Build all pull requests | |
pull_request: | |
branches: | |
- main | |
paths: | |
- 'packages/**' | |
- 'package.json' | |
# TODO: Determine is this the safe permission. We probably don't want to allow all. | |
permissions: write-all | |
jobs: | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
- name: Setup Node | |
uses: actions/setup-node@v3 | |
with: | |
registry-url: 'https://npm.pkg.github.com' | |
scope: '@saferplace' | |
cache: pnpm | |
- name: Install Dependencies | |
run: pnpm install --frozen-lockfile | |
env: | |
# Generate a new Classic PAT | |
# - scopes: read:packages | |
NODE_AUTH_TOKEN: ${{ secrets.GH_NPM_TOKEN }} | |
- name: Lint | |
continue-on-error: true | |
run: pnpm run ci:lint | |
- name: Annotate Linting Results | |
uses: ataylorme/[email protected] | |
with: | |
repo-token: "${{ github.token }}" | |
report-json: eslint_report.json | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false # Allow completion of the task if another package fails. | |
matrix: | |
# TODO: can this be a shared variable? | |
workspace: | |
- pwa | |
- review-ui | |
include: | |
- workspace: pwa | |
deploy: true | |
cloudflareProjectName: saferplace-app | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Check Affected Workspaces | |
id: changes | |
uses: dorny/[email protected] | |
with: | |
filters: | | |
affected: | |
- packages/${{ matrix.workspace }}/** | |
- name: Skipping Workspace | |
if: steps.changes.outputs.affected == 'false' | |
run: echo "Skipping ${{ matrix.workspace }} as it has not changed" | |
- name: Setup pnpm | |
if: steps.changes.outputs.affected == 'true' | |
uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
- name: Setup Node | |
if: steps.changes.outputs.affected == 'true' | |
uses: actions/setup-node@v3 | |
with: | |
registry-url: 'https://npm.pkg.github.com' | |
scope: '@saferplace' | |
cache: pnpm | |
- name: Install Dependencies | |
if: steps.changes.outputs.affected == 'true' | |
run: pnpm install --frozen-lockfile | |
env: | |
# Generate a new Classic PAT | |
# - scopes: read:packages | |
NODE_AUTH_TOKEN: ${{ secrets.GH_NPM_TOKEN }} | |
- name: Build | |
if: steps.changes.outputs.affected == 'true' | |
working-directory: packages/${{ matrix.workspace }} | |
run: pnpm run build | |
- name: Deploy | |
if: matrix.deploy && steps.changes.outputs.affected == 'true' | |
uses: cloudflare/pages-action@v1 | |
with: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
projectName: ${{ matrix.cloudflareProjectName }} | |
accountId: 77fe99c5bfc86a6c12a8092954daec44 | |
directory: packages/${{ matrix.workspace }}/dist | |
gitHubToken: ${{ github.token }} | |