Peter Fisher
Deployment
- Clean the local build
gatsby clean
- Build the site locally
gatsby build
- Create a
.env
file in/bin/
with the following variables
SERVER=<SERVER_HOST_FROM_SSH_CONFIG>
SERVER_PATH="/absolute/path/to/website/on/remote/host"
RELEASE_PATH=/releases
CURRENT_PATH=/current
SLIDE_PATH=/slides
LOCAL_TALK_PATH=/local/path/to/slides.html
LOCAL_PATH=/local/path/to/build
- Change to bin folder
cd bin
- Export env variables
export $(grep -v '^#' .env | xargs -0)
- Run deployment script
./deploy.sh
gatsby clean && gatsby build && ./bin/deploy.sh
Commands
Run prettier
Runs prettier using the .prettierrc
config. It will output all the errors that need to be fixed.
npm run prettier
Fix prettier errors
Attempts to fix issues found by prettier using the .prettierrc
config.
npm run fix-prettier
Run ESLint
Runs ESLint using the .eslint.json
config. It will output all the errors that need to be fixed.
npm run lint
Run all test commands
Runs TypeScript checks, prettier and ESLint.
npm run test