mirror of
https://github.com/zhigang1992/angular.js.git
synced 2026-01-12 22:45:52 +08:00
Replaced instances of 'Testacular' with 'Karma' to reflect name change of test runner. Replaced instances of 'http://vojtajina.github.com/testacular' with 'http://karma-runner.github.io/' to reflect dedicated page for Karma Test Runner. Added location of config file needed to start the Karma server. This is still labeled 'testacular.conf.js' and needs file name to be updated in the phone example repo.
33 lines
578 B
Bash
Executable File
33 lines
578 B
Bash
Executable File
#!/usr/bin/env bash
|
|
#
|
|
# Script to initialize angular repo
|
|
# - install required node packages
|
|
# - install Karma
|
|
# - install git hooks
|
|
|
|
|
|
node=`which node 2>&1`
|
|
if [ $? -ne 0 ]; then
|
|
echo "Please install NodeJS."
|
|
echo "http://nodejs.org/"
|
|
exit 1
|
|
fi
|
|
|
|
npm=`which npm 2>&1`
|
|
if [ $? -ne 0 ]; then
|
|
echo "Please install NPM."
|
|
fi
|
|
|
|
|
|
echo "Installing required npm packages..."
|
|
npm install
|
|
|
|
karma=`which karma 2>&1`
|
|
if [ $? -ne 0 ]; then
|
|
echo "Installing Karma..."
|
|
npm install -g karma
|
|
fi
|
|
|
|
echo "Installing git hooks..."
|
|
ln -sf ../../validate-commit-msg.js .git/hooks/commit-msg
|