Skip to content

Commit

Permalink
docs: update siteConfig documentation for publishing with GitHub Pages (
Browse files Browse the repository at this point in the history
facebook#1038)

* Updated Publishing with GitHub Pages

Updated docs to resolve facebook#1029

* Update getting-started-publishing.md
  • Loading branch information
alexdriedger authored and yangshun committed Oct 15, 2018
1 parent 1c333ee commit a28ac3b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/getting-started-publishing.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,14 @@ Deploying your Docusaurus site to GitHub Pages is straightforward if you are alr
Most of the work to publish to GitHub pages is done for you automatically through the [`publish-gh-pages`](./api-commands.md#docusaurus-publish) script. You just need to determine the values for a few parameters required by the script.

Two of the required parameters are set in the [`siteConfig.js`](api-site-config.md):
The following parameters need to be set in the [`siteConfig.js`](api-site-config.md):

| Name | Description |
| ------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `organizationName` | The GitHub user or organization that owns the repository. In the case of Docusaurus, that would be the "facebook" GitHub organization. |
| `projectName` | The name of the GitHub repository for your project. For example, Docusaurus is hosted at https://github.com/facebook/docusaurus, so our project name in this case would be "docusaurus". |
| `url` | Your website's URL. For projects hosted on GitHub pages, this will be "https://_username_.github.io" |
| `baseUrl` | Base URL for your project. For projects hosted on GitHub pages, it follows the format "/_projectName_/". For https://github.com/facebook/docusaurus, `baseUrl` is `/docusaurus/`. |

> Docusaurus also supports deploying [user or organization sites](https://help.github.com/articles/user-organization-and-project-pages/#user--organization-pages). To do this, just set `projectName` to "_username_.github.io" (where _username_ is your username or organization name on GitHub) and `organizationName` to "_username_".
> For user or org sites, the publish script will deploy these sites to the root of the `master` branch of the _username_.github.io repo. In this case, note that you will want to have the Docusaurus infra, your docs, etc. either in another branch of the _username_.github.io repo (e.g., maybe call it `source`), or in another, separated repo (e.g. in the same as the documented source code).
Expand Down

0 comments on commit a28ac3b

Please sign in to comment.