Skip to content

Commit 8b02766

Browse files
committed
yml
1 parent 27fa9e1 commit 8b02766

File tree

1 file changed

+9
-20
lines changed

1 file changed

+9
-20
lines changed

.github/workflows/gh-pages.yml

Lines changed: 9 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -15,45 +15,34 @@ concurrency:
1515
cancel-in-progress: false
1616

1717
jobs:
18-
# Build job
1918
build:
2019
runs-on: ubuntu-latest
2120
steps:
2221
- name: Checkout
23-
uses: actions/checkout@v2
22+
uses: actions/checkout@v3 # Updated to v3
2423
- name: Set up Node.js
2524
uses: actions/setup-node@v3
2625
with:
27-
node-version: '16'
26+
node-version: '20' # Use a supported Node.js version
2827
- name: Install dependencies
2928
run: npm install
3029
- name: Build React app
31-
run: npm run build:react
32-
- name: Bundle the app with Webpack
33-
run: npm run build:bundle
30+
run: npm run build
3431
- name: Upload artifact
35-
uses: actions/upload-artifact@v3
32+
uses: actions/upload-artifact@v4 # Updated to v4
3633
with:
3734
name: react-build
38-
path: build
35+
path: ./build
3936

40-
# Deployment job
4137
deploy:
42-
environment:
43-
name: github-pages
44-
url: ${{ steps.deployment.outputs.page_url }}
4538
runs-on: ubuntu-latest
4639
needs: build
4740
steps:
4841
- name: Checkout
49-
uses: actions/checkout@v2
42+
uses: actions/checkout@v3
5043
- name: Deploy to GitHub Pages
51-
id: deployment
52-
uses: peaceiris/actions-gh-pages@v3
44+
uses: peaceiris/actions-gh-pages@v4 # Updated to v4
5345
with:
5446
github_token: ${{ secrets.GITHUB_TOKEN }}
55-
publish_branch: gh-pages
56-
publish_dir: build
57-
- name: Debug URL Output
58-
run: |
59-
echo "Deployed to GitHub Pages: ${{ steps.deployment.outputs.page_url }}"
47+
publish_branch: gh-pages
48+
publish_dir: ./build

0 commit comments

Comments
 (0)