File tree Expand file tree Collapse file tree 1 file changed +33
-15
lines changed Expand file tree Collapse file tree 1 file changed +33
-15
lines changed Original file line number Diff line number Diff line change 9
9
install :
10
10
- npm install
11
11
12
- script :
13
- - npm run build
12
+ stages :
13
+ - lint
14
+ - name : gh-pages
15
+ if : branch = master
16
+ - name : release
17
+ if : branch = master
14
18
15
- after_script :
16
- - cd ./example-dist
17
- - git init
18
- - git remote add origin "https://${GH_TOKEN}@${GH_REF}"
19
- - git checkout -b gh-pages
20
- - git config user.name "leezng"
21
- - git config user.email "leezng@163.com"
22
- - git add .
23
- - git commit -m "update example page"
24
- - git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" gh-pages:gh-pages
19
+ jobs :
20
+ include :
21
+ - stage : lint
22
+ script : npm run lint
23
+ - stage : gh-pages
24
+ script : npm run build
25
+ after_script :
26
+ - cd ./example-dist
27
+ - git init
28
+ - git remote add origin "https://${GH_TOKEN}@${GH_REF}"
29
+ - git checkout -b gh-pages
30
+ - git config user.name "leezng"
31
+ - git config user.email "leezng@163.com"
32
+ - git add .
33
+ - git commit -m "update example page"
34
+ - git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" gh-pages:gh-pages
35
+ - stage : release
36
+ script : echo "Deploying to GitHub releases ..."
37
+ deploy :
38
+ provider : releases
39
+ api_key : ${GH_TOKEN}
40
+ skip_cleanup : true
41
+ on :
42
+ tags : true
25
43
26
- branches :
27
- only :
28
- - dev
44
+ # branches:
45
+ # only:
46
+ # - dev
29
47
30
48
env :
31
49
global :
You can’t perform that action at this time.
0 commit comments