mirror of https://gitlab.com/curben/blog
build: clean up artifact prior to build
somehow cache in netlify
This commit is contained in:
parent
0866cd3890
commit
b330435a1f
2
build.sh
2
build.sh
|
@ -13,11 +13,13 @@ hexo generate
|
||||||
|
|
||||||
if [ "$NODE_ENV" = "production" ] && [ -d "public/" ]; then
|
if [ "$NODE_ENV" = "production" ] && [ -d "public/" ]; then
|
||||||
# deploy site assets
|
# deploy site assets
|
||||||
|
rm -rf "site/"
|
||||||
git clone --depth 1 --branch site https://gitlab.com/curben/blog.git site
|
git clone --depth 1 --branch site https://gitlab.com/curben/blog.git site
|
||||||
cp -r site/* "public/"
|
cp -r site/* "public/"
|
||||||
rm -f "public/README.md"
|
rm -f "public/README.md"
|
||||||
|
|
||||||
# deploy microblog
|
# deploy microblog
|
||||||
|
rm -rf "microblog/"
|
||||||
git clone --depth 1 --branch microblog https://gitlab.com/curben/blog.git microblog
|
git clone --depth 1 --branch microblog https://gitlab.com/curben/blog.git microblog
|
||||||
cd "microblog/"
|
cd "microblog/"
|
||||||
export PATH="$PATH:../node_modules/.bin"
|
export PATH="$PATH:../node_modules/.bin"
|
||||||
|
|
Loading…
Reference in New Issue