spider/boundle.sh
2019-05-28 16:53:34 +08:00

19 lines
479 B
Bash
Executable File

#!/bin/bash
source /etc/profile
npm install --prefer-offline --loglevel info --unsafe-perm=true --allow-root >> boundle.log
[ "$(which gulp)" = "" ] && {
npm install -g gulp
echo 1>&2 "Install gulp done" >> boundle.log
}
gulp >> boundle.log
echo 'finish gulp task' >> boundle.log
tar -zcvf movie_spider.tar.gz ./
echo 'finish compress all code' >> boundle.log
mkdir target && mv ./movie_spider.tar.gz ./target/movie_spider.tar.gz
echo 'all done' 2>&1 >> boundle.log