@@ -21,13 +21,13 @@ Table of Contents
21
21
- [ Getting started] ( #getting-started )
22
22
- [ (1) Add ssh deploy key] ( #1-add-ssh-deploy-key )
23
23
- [ (2) Create ` .github/workflows/gh-pages.yml ` ] ( #2-create-githubworkflowsgh-pagesyml )
24
- - [ : star : Repository type - Project] ( #star -repository-type---project )
25
- - [ : star : Repository type - User and Organization] ( #star -repository-type---user-and-organization )
24
+ - [ ⭐️ Repository type - Project] ( #%EF%B8%8F -repository-type---project )
25
+ - [ ⭐️ Repository type - User and Organization] ( #%EF%B8%8F -repository-type---user-and-organization )
26
26
- [ Options] ( #options )
27
- - [ : star : Pull action image from Docker Hub] ( #star -pull-action-image-from-docker-hub )
28
- - [ : star : ` PERSONAL_TOKEN ` ] ( #star -personal_token )
29
- - [ : star : ` GITHUB_TOKEN ` ] ( #star -github_token )
30
- - [ : star : Suppressing empty commits] ( #star -suppressing-empty-commits )
27
+ - [ ⭐️ Pull action image from Docker Hub] ( #%EF%B8%8F -pull-action-image-from-docker-hub )
28
+ - [ ⭐️ ` PERSONAL_TOKEN ` ] ( #%EF%B8%8F -personal_token )
29
+ - [ ⭐️ ` GITHUB_TOKEN ` ] ( #%EF%B8%8F -github_token )
30
+ - [ ⭐️ Suppressing empty commits] ( #%EF%B8%8F -suppressing-empty-commits )
31
31
- [ Tips and FAQ] ( #tips-and-faq )
32
32
- [ How to add ` CNAME ` ] ( #how-to-add-cname )
33
33
- [ Deployment completed but you cannot read] ( #deployment-completed-but-you-cannot-read )
@@ -62,9 +62,17 @@ Next, Go to **Repository Settings**
62
62
- Go to ** Deploy Keys** and add your public key with the ** Allow write access**
63
63
- Go to ** Secrets** and add your private key as ` ACTIONS_DEPLOY_KEY `
64
64
65
+ | Add your public key | Success |
66
+ | ---| ---|
67
+ | ![ ] ( ./images/deploy-keys-1.jpg ) | ![ ] ( ./images/deploy-keys-2.jpg ) |
68
+
69
+ | Add your private key | Success |
70
+ | ---| ---|
71
+ | ![ ] ( ./images/secrets-1.jpg ) | ![ ] ( ./images/secrets-2.jpg ) |
72
+
65
73
### (2) Create ` .github/workflows/gh-pages.yml `
66
74
67
- #### : star : Repository type - Project
75
+ #### ⭐️ Repository type - Project
68
76
69
77
An example workflow for Hugo.
70
78
@@ -107,7 +115,15 @@ jobs:
107
115
108
116
The above example is for [Project Pages sites]. (` <username>/<project_name>` repository)
109
117
110
- # ### :star: Repository type - User and Organization
118
+ | Actions log overview | Build step log |
119
+ |---|---|
120
+ |  |  |
121
+
122
+ | Deploy step log | GitHub Pages log |
123
+ |---|---|
124
+ |  |  |
125
+
126
+ # ### ⭐️ Repository type - User and Organization
111
127
112
128
For [User and Organization Pages sites] (`<username>/<username>.github.io` repository),
113
129
we have to set `master` branch to `PUBLISH_BRANCH`.
@@ -124,9 +140,11 @@ PUBLISH_BRANCH: master # deploying branch
124
140
[Project Pages sites] : https://help.github.com/en/articles/user-organization-and-project-pages#project-pages-sites
125
141
[User and Organization Pages sites] : https://help.github.com/en/articles/user-organization-and-project-pages#user-and-organization-pages-sites
126
142
143
+ 
144
+
127
145
# ## Options
128
146
129
- # ### :star: Pull action image from Docker Hub
147
+ # ### ⭐️ Pull action image from Docker Hub
130
148
131
149
You can pull a public docker image from Docker Hub.
132
150
By pulling docker images, you can reduce the overall execution time of your workflow. In addition, `latest` tag is provided.
@@ -138,7 +156,7 @@ By pulling docker images, you can reduce the overall execution time of your work
138
156
139
157
- [peaceiris/gh-pages - Docker Hub](https://hub.docker.com/r/peaceiris/gh-pages)
140
158
141
- # ### :star: `PERSONAL_TOKEN`
159
+ # ### ⭐️ `PERSONAL_TOKEN`
142
160
143
161
[Generate a personal access token (`repo`)](https://github.com/settings/tokens) and add it to Secrets as `PERSONAL_TOKEN`, it works as well as `ACTIONS_DEPLOY_KEY`.
144
162
@@ -147,16 +165,20 @@ By pulling docker images, you can reduce the overall execution time of your work
147
165
+ PERSONAL_TOKEN: ${{ secrets.PERSONAL_TOKEN }}
148
166
` ` `
149
167
150
- # ### :star: `GITHUB_TOKEN`
168
+ # ### ⭐️ `GITHUB_TOKEN`
169
+
170
+ > **NOTES**: Do not use `GITHUB_TOKEN`.
171
+ >
172
+ > This action supports `GITHUB_TOKEN` but it has some problems to deploy to GitHub Pages. See [Issue # 9]
151
173
152
- > **NOTES**: This action supports `GITHUB_TOKEN` but it has some problems to deploy to GitHub Pages. See # 9
174
+ [Issue # 9]: https://github.com/peaceiris/actions-gh-pages/issues/ 9
153
175
154
176
` ` ` diff
155
177
- ACTIONS_DEPLOY_KEY: ${{ secrets.ACTIONS_DEPLOY_KEY }}
156
178
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
157
179
` ` `
158
180
159
- # ### :star: Suppressing empty commits
181
+ # ### ⭐️ Suppressing empty commits
160
182
161
183
By default, a commit will always be generated and pushed to the `PUBLISH_BRANCH`, even if nothing changed. If you want to suppress this behavior, set the optional parameter `emptyCommits` to `false`. cf. [Issue # 21]
162
184
0 commit comments