Commit 4ba92227 authored by 叶飞's avatar 叶飞

feat: gitlab ci

parent 72d1c402
Pipeline #18349 failed with stages
in 11 seconds
...@@ -2,7 +2,7 @@ variables: ...@@ -2,7 +2,7 @@ variables:
DEPLOY_PATH: 'F:/WisdomComponents' DEPLOY_PATH: 'F:/WisdomComponents'
stages: stages:
- install - init
- build - build
- release - release
...@@ -11,26 +11,25 @@ before_script: ...@@ -11,26 +11,25 @@ before_script:
- echo 查看运行环境 - echo 查看运行环境
- whoami - whoami
- node -v - node -v
- dir
install: init:
stage: install stage: init
script: script:
- cd /d "${DEPLOY_PATH}/src/wisdom-components"
- dir
- git pull
- echo 开始安装依赖... - echo 开始安装依赖...
- nrm ls - nrm ls
- npm install - npm install
- lerna bootstrap - lerna bootstrap
- echo 安装完成 - echo 安装完成
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- node_modules/
build: build:
stage: build stage: build
script: script:
- cd /d "${DEPLOY_PATH}/src/wisdom-components"
- echo 开始打包... - echo 开始打包...
- npm run build - npm run deploy
- echo 打包完成 - echo 打包完成
cache: cache:
key: ${CI_COMMIT_REF_SLUG} key: ${CI_COMMIT_REF_SLUG}
...@@ -40,6 +39,7 @@ build: ...@@ -40,6 +39,7 @@ build:
release: release:
stage: release stage: release
script: script:
- cd /d "${DEPLOY_PATH}/src/wisdom-components"
- echo 开始拷贝发布包... - echo 开始拷贝发布包...
- robocopy dist ${DEPLOY_PATH} - robocopy dist "${DEPLOY_PATH}/dist"
- echo 发布完成 - echo 发布完成
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
"release": "node ./scripts/release.js", "release": "node ./scripts/release.js",
"size": "npm run build && size-limit", "size": "npm run build && size-limit",
"start": "dumi dev", "start": "dumi dev",
"site": "dumi build",
"tsc:duplicate": "tsc -p ./tests/tsconfig.duplicate.json", "tsc:duplicate": "tsc -p ./tests/tsconfig.duplicate.json",
"sync:tnpm": "node -e 'require(\"./scripts/syncTNPM\")()'", "sync:tnpm": "node -e 'require(\"./scripts/syncTNPM\")()'",
"test": "umi-test", "test": "umi-test",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment