瀏覽代碼

新增jenkins构建脚本

WANG 5 年之前
父節點
當前提交
0174cbb55e
共有 2 個文件被更改,包括 23 次插入0 次删除
  1. 17 0
      jenkins-prod.sh
  2. 6 0
      jenkins-test.sh

+ 17 - 0
jenkins-prod.sh

@@ -0,0 +1,17 @@
+#!/bin/bash
+pwd
+
+yarn
+npm run build
+
+rm -rf ~/project/examcloud/static/student-client/dist/*
+cp -r  dist ~/project/examcloud/static/student-client/
+
+rm -rf ~/packages/static/student-client/*
+mkdir -p ~/packages/static/student-client
+cp -r dist ~/packages/static/student-client/
+
+cd ~/packages/static/
+rm -rf student-client.tar.gz
+tar -zcvf student-client.tar.gz student-client/
+

+ 6 - 0
jenkins-test.sh

@@ -0,0 +1,6 @@
+pwd
+yarn
+npm run build
+
+rm -rf ~/project/examcloud/static/student-client/dist/*
+cp -r  dist ~/project/examcloud/static/student-client/