File tree 1 file changed +9
-14
lines changed
1 file changed +9
-14
lines changed Original file line number Diff line number Diff line change @@ -3,28 +3,23 @@ name: Deploy to GitHub Pages
3
3
on :
4
4
push :
5
5
branches :
6
- - main # Or the branch you're working on
6
+ - main # Trigger deployment only on push to the 'main' branch
7
7
8
8
jobs :
9
9
deploy :
10
10
runs-on : ubuntu-latest
11
+
11
12
steps :
13
+ # Checkout the code
12
14
- name : Checkout code
13
15
uses : actions/checkout@v2
14
-
15
- - name : Set up Node.js
16
- uses : actions/setup-node@v2
17
16
with :
18
- node-version : ' 14'
19
-
20
- - name : Install dependencies
21
- run : npm install
22
-
23
- - name : Build the project
24
- run : npm run build # This depends on your build system (e.g., React, Vue, etc.)
17
+ ref : main # Ensure you're deploying from the correct branch (main)
25
18
19
+ # Deploy to GitHub Pages
26
20
- name : Deploy to GitHub Pages
27
- uses : JamesIves/github-pages-deploy-action@4 .2.0
21
+ uses : JamesIves/github-pages-deploy-action@v4 .2.0
28
22
with :
29
- branch : gh-pages # Deployment branch
30
- folder : src # Folder to deploy (set to where the build output is)
23
+ branch : gh-pages # The branch where the content will be deployed (default is gh-pages)
24
+ folder : src # The folder to deploy (in your case, it's 'src')
25
+ token : ${{ secrets.GITHUB_TOKEN }} # Automatically used token for authentication
You can’t perform that action at this time.
0 commit comments