File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change 9
9
defaults :
10
10
run :
11
11
working-directory : app
12
+
12
13
steps :
13
14
- uses : actions/checkout@v2
15
+
14
16
- name : Setup Node
15
17
uses : actions/setup-node@v1
16
18
with :
17
19
node-version : 12
20
+
18
21
- name : Install dependencies
19
22
run : npm ci
23
+
20
24
- name : Build App
21
25
run : npm run build --if-present
22
26
env :
23
27
CI : true
24
28
29
+ - name : Publish Artifact
30
+ uses : actions/upload-artifact@v1
31
+ with :
32
+ name : app-dist
33
+ path : dist
34
+
25
35
release :
26
36
if : startsWith(github.ref, 'refs/tags/v')
27
37
needs :
28
38
- build
39
+
29
40
name : Release
30
41
runs-on : ubuntu-latest
31
42
defaults :
32
43
run :
33
44
working-directory : app
45
+
34
46
steps :
47
+ - name : Download Artifact
48
+ uses : actions/download-artifact@v1
49
+ with :
50
+ name : app-dist
51
+ path : dist
52
+
35
53
- name : Get version number
36
54
uses : olegtarasov/get-tag@v2
55
+
37
56
- name : Add distribution files
38
57
run : git add dist
58
+
39
59
- name : Commit files
40
60
run : |
41
61
git config --local user.email "action@github.com"
42
62
git config --local user.name "GitHub Action"
43
63
git commit -m "Release new version $GIT_TAG_NAME"
64
+
44
65
- name : Push changes
45
66
uses : ad-m/github-push-action@master
46
67
with :
You can’t perform that action at this time.
0 commit comments