1
Fork 0

Added build dirs

This commit is contained in:
Jake Howard 2015-11-01 17:22:08 +00:00
parent d4988fe760
commit 84a884333f
6 changed files with 21 additions and 1 deletions

View File

@ -4,7 +4,7 @@
"description": "Make your computer keyboard sound like a mechanical keyboard",
"main": "build/main.js",
"scripts": {
"build-js"
"build-js": " bash scripts/build-js.sh",
"start": "node_modules/.bin/electron build/",
"test": "echo \"Error: no test specified\" && exit 1",
"lint": "eslint -c node_modules/eslint-config/.eslintrc 'src/'"

16
scripts/build-js.sh Normal file
View File

@ -0,0 +1,16 @@
#!/usr/bin/bash
set -e
cp node_modules/bootstrap/dist/js/bootstrap.js static/src/js/lib/
echo ">> Building Libraries..."
uglifyjs node_modules/jquery/dist/jquery.js --compress --screw-ie8 --define --stats --keep-fnames -o build/lib/jquery.js
uglifyjs node_modules/bootstrap/dist/js/bootstrap.js --compress --screw-ie8 --define --stats --keep-fnames -o build/lib/bootstrap.js
echo ">> Building Application JS..."
browserify -t reactify src/page.js -o build/page.js
uglifyjs build/js/app.js --compress --screw-ie8 --define --stats --keep-fnames -o src/js/app.js
echo ">> Building Main JS..."
uglifyjs build/main.js --compress --screw-ie8 --define --stats --keep-fnames -o src/main.js

1
src/index.html Normal file
View File

@ -0,0 +1 @@
index.html

1
src/js/app.js Normal file
View File

@ -0,0 +1 @@
app.js

1
src/less/style.less Normal file
View File

@ -0,0 +1 @@
style.less

1
src/main.js Normal file
View File

@ -0,0 +1 @@
main.js