Added starter setup script

This commit is contained in:
Jamon Holmgren 2018-08-15 21:09:05 -07:00
parent f9b9d3c092
commit e34f75626b
1 changed files with 26 additions and 0 deletions

26
bin/setup Executable file
View File

@ -0,0 +1,26 @@
#! /bin/bash
# Node installed?
if ! [ -x "$(command -v node)" ]; then
echo 'Error: node is not installed.' >&2
if ! [ -x "$(command -v brew)" ]; then
echo 'Go here to install: https://nodejs.org/en/download/'
fi
if [ -x "$(command -v brew)" ]; then
echo 'You have Homebrew installed, so run "brew install node".'
fi
exit 1
fi
# React Native installed?
if ! [ -x "$(command -v react-native)" ]; then
echo 'Error: React Native is not installed.' >&2
echo 'Go here: https://facebook.github.io/react-native/docs/getting-started.html' >&2
echo 'Use the "Building Projects With Native Code" option.'
exit 1
fi
# TODO: Automate setup on new machines