2014-10-26 19:57:44 -07:00
|
|
|
# Install dependencies.
|
2014-08-28 19:55:45 -07:00
|
|
|
install:
|
|
|
|
npm install
|
2014-10-21 20:16:42 -07:00
|
|
|
|
2014-10-26 19:57:44 -07:00
|
|
|
# Watch the app sources and build with source maps.
|
2014-10-26 21:10:41 -06:00
|
|
|
watch:
|
|
|
|
./node_modules/.bin/watchify -e ./src/app.coffee -o public/js/app.bundle.js -d -v
|
2014-08-28 19:55:45 -07:00
|
|
|
|
2014-10-26 19:57:44 -07:00
|
|
|
# Serve locally.
|
2014-08-28 19:55:45 -07:00
|
|
|
serve:
|
|
|
|
cd public; python -m SimpleHTTPServer 8000
|
|
|
|
|
2014-10-26 21:10:41 -06:00
|
|
|
# Make a minified package.
|
|
|
|
build:
|
2014-10-26 19:57:44 -07:00
|
|
|
grunt init
|
2014-10-26 21:10:41 -06:00
|
|
|
./node_modules/.bin/browserify -e ./src/app.coffee -o public/js/app.bundle.js
|
|
|
|
grunt
|
2014-10-26 19:57:44 -07:00
|
|
|
grunt minify
|
2014-10-26 21:10:41 -06:00
|
|
|
|
2014-10-27 06:57:57 -06:00
|
|
|
# Publish to GitHub Pages.
|
2014-10-26 21:10:41 -06:00
|
|
|
publish:
|
2014-10-26 21:35:41 -06:00
|
|
|
grunt gh-pages
|
2014-10-26 21:10:41 -06:00
|
|
|
|
|
|
|
# Run mocha test.
|
|
|
|
test:
|
|
|
|
./node_modules/.bin/mocha --compilers coffee:coffee-script/register --reporter spec --ui exports --timeout 20000 --slow 15000 --bail
|
|
|
|
|
|
|
|
.PHONY: test
|