-
Notifications
You must be signed in to change notification settings - Fork 3
/
build
executable file
·23 lines (22 loc) · 968 Bytes
/
build
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/env bash
rm -rf dist
mkdir -p dist
echo "build src/ldcv.ls -> dist/index.js ..."
./node_modules/.bin/lsc -cp --no-header src/ldcv.ls > dist/index.js
echo "build src/ldcv.styl -> dist/index.css ..."
./node_modules/.bin/stylus -p src/ldcv.styl > dist/index.css
echo "build src/ldcv.effects.styl -> dist/ldcv.effects.css ..."
./node_modules/.bin/stylus -p src/ldcv.effects.styl > dist/ldcv.effects.css
echo "minifying index.js ..."
./node_modules/.bin/uglifyjs dist/index.js -m -c > dist/index.min.js
echo "minifying index.css ..."
./node_modules/.bin/uglifycss dist/index.css > dist/index.min.css
echo "minifying ldcv.effects.css ..."
./node_modules/.bin/uglifycss dist/ldcv.effects.css > dist/ldcv.effects.min.css
echo "Copy pug mixin to dist/ ..."
cp src/ldcv.pug dist/index.pug
echo "Copy dist/ to web/ ..."
rm -rf web/static/assets/lib/ldcover/dev/
mkdir -p web/static/assets/lib/ldcover/dev/
cp -R dist/* web/static/assets/lib/ldcover/dev/
echo "done."