Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 4 additions & 18 deletions .github/workflows/astro-check-pr.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,19 @@
# Sample workflow for building and deploying an Astro site to GitHub Pages
#
# To get started with Astro see: https://docs.astro.build/en/getting-started/
#
name: Astro Check

on:
# Runs on pushes targeting the default branch
pull_request:
branches: ["main"]
paths: ["src", "public", ".github/workflows"]

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "check"
cancel-in-progress: false

env:
BUILD_PATH: "." # default value when not using subfolders
# BUILD_PATH: subfolder
BUILD_PATH: "."

jobs:
check:
Expand Down Expand Up @@ -54,15 +44,11 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: "20"
node-version: "22"
cache: ${{ steps.detect-package-manager.outputs.manager }}
cache-dependency-path: ${{ env.BUILD_PATH }}/${{ steps.detect-package-manager.outputs.lockfile }}
- name: Install dependencies
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
working-directory: ${{ env.BUILD_PATH }}
- name: Check with Astro
run: |
${{ steps.detect-package-manager.outputs.runner }} astro check \
--site "${{ steps.pages.outputs.origin }}" \
--base "${{ steps.pages.outputs.base_path }}"
working-directory: ${{ env.BUILD_PATH }}
run: ${{ steps.detect-package-manager.outputs.runner }} astro check
1 change: 1 addition & 0 deletions .github/workflows/astro.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]
paths: ["src", "public"]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down
Loading