docs: Update Docusaurus workflow example (#229)

* Updating Docusaurus config to make it work
* docs: Fix publish_dir

There were some issues, it was impossible to get it working just with a simple copy/paste

* Test repo: https://github.com/peaceiris/test-docusaurus
* Reference: https://docusaurus.io/docs/en/installation

Co-authored-by: peaceiris <30958501+peaceiris@users.noreply.github.com>
This commit is contained in:
Pierre Mavro 2020-04-13 16:27:34 +02:00 committed by GitHub
parent 9f90987bad
commit fb15409be9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -678,7 +678,7 @@ jobs:
An example workflow for [Docusaurus](https://docusaurus.io/).
`npx @docusaurus/init@next init` is useful to create a new Docusaurus project.
`npx @docusaurus/init@next init website classic` is useful to create a new Docusaurus project.
```yaml
name: github pages
@ -712,13 +712,15 @@ jobs:
${{ runner.os }}-yarn-
- run: yarn install
working-directory: ./website
- run: yarn build
working-directory: ./website
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
publish_dir: ./website/build
```
### ⭐️ Static Site Generators with Python