From b090084ac96fb1379899b413bb9b8f3ea14867a0 Mon Sep 17 00:00:00 2001 From: liyang <1711467488@qq.com> Date: Fri, 22 Jun 2018 08:34:59 +0800 Subject: [PATCH] no message Former-commit-id: 462ce8864de9c3f1fa18a10a5205a06d119f2b32 [formerly 462ce8864de9c3f1fa18a10a5205a06d119f2b32 [formerly 462ce8864de9c3f1fa18a10a5205a06d119f2b32 [formerly 462ce8864de9c3f1fa18a10a5205a06d119f2b32 [formerly fd86fe1efd91ec3674e857d83b655e6090c95953 [formerly 7419813161ecc95ebb432245ed575dc77f5d93cf]]]]] Former-commit-id: 455e69a4cb28f3fa6ad6c6abfe9fbbbbc04b8233 Former-commit-id: b1ced5f74a652f00ae74a88c23d7620b8392f515 Former-commit-id: 12cb867fd61ca0912d105991894e401ba1a14ae0 [formerly d8825410495374394f4757d39c5cf7af78bdce20] Former-commit-id: 93558e214327c20c97a7c0223102587fae27bf77 Former-commit-id: 5aad0ff93276b5b2ae51b894f1a4961825085c25 Former-commit-id: d3a08cc5a38313347693fb46daf50f1613592038 Former-commit-id: 7f1a26a2004c23c686eea75201adcd4cb73c7eb4 Former-commit-id: 1f4e1ef961d4e5a4e4352b0bba7bd7479ebbaecd --- deploy.sh => deploy-doc.sh | 0 deploy-preview.sh | 25 +++++++++++++++++++++++++ 2 files changed, 25 insertions(+) rename deploy.sh => deploy-doc.sh (100%) create mode 100755 deploy-preview.sh diff --git a/deploy.sh b/deploy-doc.sh similarity index 100% rename from deploy.sh rename to deploy-doc.sh diff --git a/deploy-preview.sh b/deploy-preview.sh new file mode 100755 index 00000000..310ee2ce --- /dev/null +++ b/deploy-preview.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env sh + +# 确保脚本抛出遇到的错误 +set -e + +# 生成静态文件 +npm run build + +# 进入生成的文件夹 +cd dist + +# 如果是发布到自定义域名 +# echo 'www.example.com' > CNAME + +git init +git add -A +git commit -m 'deploy' + +# 如果发布到 https://.github.io +# git push -f git@github.com:/.github.io.git master + +# 如果发布到 https://.github.io/ +git push -f git@gitee.com:fairyever/d2-admin-preview.git master + +cd - \ No newline at end of file