The workflow for developing locally and for building production are now two different workflows.
Local build/preview is done by creating a link to a local project folder outside the project.
Production builds pull content data from a specified repository and branch.
Environment variables
Local and production build workflows are configured using environment variables.
A .env.example file is included in the project listing the environment variables needed for local and production builds.
This PR converts the project to a doc shell instead of a doc site project.
Major changes
This PR contains the following significant changes
Content-agnostic shell
The project is now a content-agnostic shell. It can be pointed to a content repository to create the doc site.
Content repository example: https://github.com/jcalcaben/external-markdown-content
Asymmetrical workflows
The workflow for developing locally and for building production are now two different workflows. Local build/preview is done by creating a link to a local project folder outside the project. Production builds pull content data from a specified repository and branch.
Environment variables
Local and production build workflows are configured using environment variables. A
.env.example
file is included in the project listing the environment variables needed for local and production builds.Testing
.env.local
and.env.production
files to create a.env
fileLOCAL_PROJECT_DIRECTORY
to the absolute path of the content repoREMOTE_REPOSITORY
to the git clone address of the content repoREMOTE_REPOSITORY_BRANCH
to a valid remote branch in the content repoyarn install
yarn develop
data
andmarkdown
have been created under thesrc/external
directoryyarn develop
yarn build
src/external
have been deleted.cache/gatsby-source-git/production
public
directory containing the static site fileyarn serve