diff --git a/docgen/README.md b/docgen/README.md index 990fd2e3b47..90d02d4f75f 100644 --- a/docgen/README.md +++ b/docgen/README.md @@ -16,7 +16,7 @@ GIT_USER=your_git_user GITHUB_USERNAME=facebook GITHUB_REPONAME=react-native nod This will perform a sparse checkout of the `docs/` folder from `master`, generating a clean set of markdown docs in the local `docs/` folder. It will also write to disk an updated `sidebars.json` file based on these docs. -## build.js +## build-autodocs-markdownjs Runs the usual autodocs generation scripts used by the `react-page-middleware` variant of the React Native website, but provides markdown instead of HTML. Run this script prior to building the website. @@ -25,6 +25,5 @@ Runs the usual autodocs generation scripts used by the `react-page-middleware` v Run the following commands locally (the generate script needs to run first): ``` -node server/generate.js -node server/build.js +node server/build-autodocs-markdown.js ``` \ No newline at end of file diff --git a/website/build-and-start.js b/docgen/server/build-autodocs-markdown.js similarity index 92% rename from website/build-and-start.js rename to docgen/server/build-autodocs-markdown.js index 5d1773118ed..b5a531c7d58 100755 --- a/website/build-and-start.js +++ b/docgen/server/build-autodocs-markdown.js @@ -10,7 +10,7 @@ const { cd, cp, echo, exec, exit, ls, mkdir, rm, which } = require("shelljs"); -cd(`../docs`); +cd(`../../docs`); rm(`-rf`, `autogen_*.md`); cd(`..`); cd(`docgen`); @@ -28,7 +28,3 @@ if (exec(`node server/build.js`).code !== 0) { echo(`Error: Generating Markdown failed`); exit(1); } - -cd(`..`); -cd(`website`); -// exec(`npm start`);