Last active
January 20, 2019 14:59
-
-
Save bardic/94943e4122bafcc348da647773e2b776 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| npm_new_phaser() { | |
| if [ "$1" != "" ] | |
| then | |
| mkdir "$1" | |
| cd "$1" | |
| if ! type nvm > /dev/null; then | |
| echo "Insatll NVM. I'm not doing it for you since you need shell integration" | |
| echo "https://github.com/creationix/nvm" | |
| return 1 | |
| fi | |
| if ! type node > /dev/null; then | |
| echo "How the hell did you make it here? NVM should install a version of node." | |
| return 1 | |
| fi | |
| git clone https://github.com/lean/phaser-es6-webpack.git . | |
| rm -rf .git | |
| rm CODE_OF_CONDUCT.md | |
| rm LICENSE.md | |
| rm README.md | |
| touch README.md | |
| node -v > .nvmrc | |
| npm install | |
| echo "-----------------------" | |
| echo "You did it. Cognrats 🎉" | |
| echo "-----------------------" | |
| else | |
| echo "You did it wrong. Do it better" | |
| fi | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment