File tree Expand file tree Collapse file tree 2 files changed +27
-19
lines changed Expand file tree Collapse file tree 2 files changed +27
-19
lines changed Original file line number Diff line number Diff line change
1
+ # This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
2
+ # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
3
+
4
+ name : Main
5
+
6
+ on :
7
+ push :
8
+ branches :
9
+ - main
10
+
11
+ jobs :
12
+
13
+ deploy-testing :
14
+ if : contains(github.event.head_commit.message, 'testing build')
15
+ runs-on : ubuntu-latest
16
+ needs : [platform]
17
+ steps :
18
+ - uses : actions/checkout@v2
19
+ - name : Deploy for Testing
20
+ uses : JamesIves/github-pages-deploy-action@v4
21
+ with :
22
+ branch : gh-pages
23
+ folder : site/updates
24
+ clean : false
Original file line number Diff line number Diff line change 1
1
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
2
2
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
3
3
4
- name : Pull-Request or Main
4
+ name : Pull-Request
5
5
6
6
on :
7
- push :
8
- branches :
9
- - main
10
7
pull_request :
11
8
branches :
12
9
- main
@@ -33,24 +30,11 @@ jobs:
33
30
- name : ' Build for platform: ${{ matrix.target-platform }}'
34
31
run : ' mvn -Dtarget.platform=${{ matrix.target-platform }} -Dsite.dir=testing clean verify'
35
32
- name : Assign build.version.properties to env variable
36
- if : github.event_name == 'pull_request' && matrix.target-platform == env.DEFAULT_TARGET_PLATFORM && !contains(github.head_ref, 'staging')
33
+ if : matrix.target-platform == env.DEFAULT_TARGET_PLATFORM
37
34
run : cat site/target/build.version.properties >> $GITHUB_ENV
38
35
- name : ' Deploy build ${{ env.build_version_full }} for PR${{ github.event.pull_request.number }}'
39
- if : github.event_name == 'pull_request' && matrix.target-platform == env.DEFAULT_TARGET_PLATFORM && !contains(github.head_ref, 'staging')
36
+ if : matrix.target-platform == env.DEFAULT_TARGET_PLATFORM
40
37
uses : actions/upload-artifact@v2
41
38
with :
42
39
name : EasyShell-${{ env.build_version_full }}
43
40
path : site/target/repository
44
-
45
- deploy-testing :
46
- if : github.event_name == 'pull_request' && contains(github.head_ref, 'staging')
47
- runs-on : ubuntu-latest
48
- needs : [platform]
49
- steps :
50
- - uses : actions/checkout@v2
51
- - name : Deploy for Testing
52
- uses : JamesIves/github-pages-deploy-action@v4
53
- with :
54
- branch : gh-pages
55
- folder : site/updates
56
- clean : false
You can’t perform that action at this time.
0 commit comments