Skip to content

Commit b2dbd5e

Browse files
committed
chore: update workflow to use official Astro action and configure site URL
1 parent 094967d commit b2dbd5e

File tree

2 files changed

+7
-41
lines changed

2 files changed

+7
-41
lines changed

.github/workflows/deploy.yml

+6-41
Original file line numberDiff line numberDiff line change
@@ -16,45 +16,12 @@ jobs:
1616
steps:
1717
- name: Checkout your repository using git
1818
uses: actions/checkout@v4
19-
20-
- name: Setup PNPM
21-
uses: pnpm/action-setup@v2
22-
with:
23-
version: 8
24-
25-
- name: Setup Node
26-
uses: actions/setup-node@v4
27-
with:
28-
node-version: 20
29-
cache: "pnpm"
30-
cache-dependency-path: "./site/pnpm-lock.yaml"
31-
32-
- name: Install dependencies
33-
working-directory: ./site
34-
run: pnpm install
35-
36-
- name: Build site
37-
working-directory: ./site
38-
run: |
39-
pnpm build
40-
echo "Build complete. Checking dist directory:"
41-
ls -la dist/
42-
43-
- name: Debug directory structure
44-
run: |
45-
echo "Current directory structure:"
46-
ls -R ./site/dist/
47-
48-
- name: Create artifact directory
49-
run: |
50-
mkdir -p ./_site
51-
cp -r ./site/dist/* ./_site/
52-
53-
- name: Upload Pages artifact
54-
uses: actions/upload-pages-artifact@v3
19+
- name: Install, build, and upload your site
20+
uses: withastro/action@v3
5521
with:
56-
name: github-pages
57-
path: ./_site
22+
path: ./site # The root location of your Astro project inside the repository
23+
node-version: 20 # The specific version of Node that should be used to build your site
24+
package-manager: pnpm@latest # Use pnpm as the package manager
5825

5926
deploy:
6027
needs: build
@@ -65,6 +32,4 @@ jobs:
6532
steps:
6633
- name: Deploy to GitHub Pages
6734
id: deployment
68-
uses: actions/deploy-pages@v2
69-
with:
70-
artifact_name: github-pages
35+
uses: actions/deploy-pages@v4

site/astro.config.mjs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import { tags } from "./src/markdoc/tags";
1414

1515
// https://astro.build/config
1616
export default defineConfig({
17+
site: "https://rmbrntt.github.io",
1718
integrations: [
1819
tailwind({
1920
applyBaseStyles: false,

0 commit comments

Comments
 (0)