-
-
Notifications
You must be signed in to change notification settings - Fork 388
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: Add emptyCommits option (@kingofzeal) * docs: Update README about emptyCommits option (@kingofzeal) * gha: Update trigger of docker image ci workflow (@peaceiris) Close #21
- Loading branch information
1 parent
dea149a
commit 241ef9f
Showing
4 changed files
with
37 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,6 +27,7 @@ Table of Contents | |
- [:star: Pull action image from Docker Hub](#star-pull-action-image-from-docker-hub) | ||
- [:star: `PERSONAL_TOKEN`](#star-personal_token) | ||
- [:star: `GITHUB_TOKEN`](#star-github_token) | ||
- [:star: Suppressing empty commits](#star-suppressing-empty-commits) | ||
- [Examples](#examples) | ||
- [Static Site Generators with Node.js](#static-site-generators-with-nodejs) | ||
- [Gatsby](#gatsby) | ||
|
@@ -156,6 +157,25 @@ By pulling docker images, you can reduce the overall execution time of your work | |
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
``` | ||
|
||
#### :star: Suppressing empty commits | ||
|
||
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] | ||
|
||
[Issue #21]: https://github.com/peaceiris/actions-gh-pages/issues/21 | ||
|
||
For example: | ||
|
||
```yaml | ||
- name: deploy | ||
uses: peaceiris/[email protected] | ||
env: | ||
ACTIONS_DEPLOY_KEY: ${{ secrets.ACTIONS_DEPLOY_KEY }} | ||
PUBLISH_BRANCH: gh-pages | ||
PUBLISH_DIR: ./public | ||
with: | ||
emptyCommits: false | ||
``` | ||
|
||
|
||
|
||
## Examples | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters