- A recent version of Node.js
npm install -g create-react-app
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -o pipefail # If you pipe one command into another, fail the whole lot if any fail | |
set -e # fail if there are any errors in the script | |
set -u # fail if you use an uninitialized variable | |
# Warn about the dire consequences of this action | |
read -r -p "THIS WILL WIPE OUT ANY UNCOMMITTED CHANGES - control-c to stop" yn | |
HEAD=$(git rev-parse HEAD) # Save where you're up to | |
git reset --hard "$HEAD" # Avoid using uncommitted changes to build the site |