Skip to content

Commit

Permalink
docs: ✏️ add explanation for User and Organization Pages sites
Browse files Browse the repository at this point in the history
Closes: #15
  • Loading branch information
peaceiris committed Sep 8, 2019
1 parent 568c603 commit 844594e
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ Next, Go to **Repository Settings**

### (2) Create `.github/workflows/gh-pages.yml`

#### Repository type - Project

An example yaml file with Hugo action.

- [peaceiris/actions-hugo: GitHub Actions for Hugo extended](https://github.com/peaceiris/actions-hugo)
Expand Down Expand Up @@ -70,6 +72,25 @@ jobs:
PUBLISH_DIR: ./public
```
The above example is for [Project Pages sites]. (`<username>/<project_name>` repository)

#### Repository type - User and Organization

For [User and Organization Pages sites] (`<username>/<username>.github.io` repository),
we have to set `master` branch to `PUBLISH_BRANCH`.

```yaml
on:
push:
branches:
- source # default branch
PUBLISH_BRANCH: master # deploying branch
```

[Project Pages sites]: https://help.github.com/en/articles/user-organization-and-project-pages#project-pages-sites
[User and Organization Pages sites]: https://help.github.com/en/articles/user-organization-and-project-pages#user-and-organization-pages-sites

### Options

#### Pull action image from Docker Hub
Expand All @@ -93,7 +114,7 @@ By pulling docker images, you can reduce the overall execution time of your work

#### `PERSONAL_TOKEN`

[Create 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`.
[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`.

```diff
- ACTIONS_DEPLOY_KEY: ${{ secrets.ACTIONS_DEPLOY_KEY }}
Expand Down

0 comments on commit 844594e

Please sign in to comment.