docusaurus/lib
Joel Marcey c14a8d2e77
Always use PROJECT_NAME, even for user and org pages (#384)
* Always use PROJECT_NAME, even for user and org pages

The symptom was that if we had a user or org page (e.g., https://JoelMarcey.github.io), we would try to copy files to a directory within a directory, getting errors like:

```
Error: Copying build assets failed with error 'Error: Cannot copy '/Users/joelm/dev/JoelMarcey.github.io/website/build' to a subdirectory of itself, '/Users/joelm/dev/JoelMarcey.github.io/website/build/JoelMarcey.github.io-master'.'
```

This is because we were setting the end of `fromPath` to empty if we were using an org or user page.

But we don't need to do that. The `PROJECT_NAME` (set in `siteConfig.js` as `projectName`) is the user or org repo

e.g., https://github.com/JoelMarcey/JoelMarcey.github.io/ has a `projectName` of `JoelMarcey.github.io` with an `organizationName` of `JoelMarcey`.

So now the `fromPath` and `toPath` look like:

`fromPath`: `build/JoelMarcey.github.io`
`toPath`: `buuid/JoelMarcey.github.io-master`
2018-01-09 09:11:07 -08:00
..
__tests__ Add first set of docusaurus-build tests using Jest (#259) 2017-12-18 14:40:52 -08:00
core Do not set html lang attribute if there is no language set (#362) 2017-12-27 15:19:32 -08:00
server Fix build on Windows (#381) 2018-01-08 15:44:50 -08:00
static Ensured that any H1 elements in content appear correct size (#306) 2017-12-18 10:17:15 -08:00
build-files.js Add notification that a site was built successfully 2017-12-12 14:15:14 -08:00
copy-examples.js Fix example website output path when copying examples 2017-12-14 09:13:21 -08:00
generate-feed.js Add Prettier Formatting (#258) 2017-12-04 19:21:02 -08:00
publish-gh-pages.js Always use PROJECT_NAME, even for user and org pages (#384) 2018-01-09 09:11:07 -08:00
rename-version.js Add newlines at end of generated files (#283) 2017-12-13 13:55:40 -08:00
start-server.js Prettier formatting fixes 2017-12-18 10:04:27 -08:00
version.js Add newlines at end of generated files (#283) 2017-12-13 13:55:40 -08:00
write-translations.js cleanup startup logs (#291) 2017-12-16 16:51:52 -08:00