This repository has been archived by the owner on Jul 20, 2024. It is now read-only.
Bump the pandacss group with 2 updates #1203
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: "Preview" | |
on: | |
pull_request: | |
branches: | |
- main | |
concurrency: | |
group: preview-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
changed: | |
runs-on: ubuntu-22.04 | |
outputs: | |
docs: ${{ steps.needs.outputs.docs }} | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Paths Changes Filter | |
uses: dorny/[email protected] | |
id: changes | |
with: | |
filters: | | |
docs: | |
- 'apps/docs/**/*' | |
- 'package.json' | |
- name: Output Needs | |
id: needs | |
run: | | |
echo "docs=${{ steps.changes.outputs.docs == 'true' }}" >> $GITHUB_OUTPUT | |
preview-docs: | |
runs-on: ubuntu-22.04 | |
needs: changed | |
if: needs.changed.outputs.docs == 'true' | |
permissions: | |
contents: write | |
deployments: write | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Create GitHub App Token | |
uses: actions/[email protected] | |
id: app-token | |
with: | |
app-id: ${{ vars.BOT_APP_ID }} | |
private-key: ${{ secrets.BOT_PRIVATE_KEY }} | |
- name: Setup Node.js environment | |
uses: actions/[email protected] | |
with: | |
node-version-file: 'package.json' | |
- name: Setup pnpm | |
uses: pnpm/[email protected] | |
- name: Clean install using pnpm | |
shell: bash | |
run: pnpm install --filter=docs --frozen-lockfile | |
- name: Build | |
run: pnpm run build --filter=docs | |
- name: Publish to Cloudflare Pages | |
uses: cloudflare/[email protected] | |
id: cloudflare-pages | |
with: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
accountId: ${{ vars.CLOUDFLARE_ACCOUNT_ID }} | |
projectName: web-application-template-docs | |
directory: ./apps/docs/dist | |
gitHubToken: ${{ steps.app-token.outputs.token }} | |
branch: preview${{ github.ref }} |