File tree 4 files changed +89
-9
lines changed
4 files changed +89
-9
lines changed Original file line number Diff line number Diff line change 1
- name : Test
1
+ name : Main Build
2
2
on :
3
3
push :
4
4
branches :
5
- - master
6
- pull_request :
7
- branches :
8
- - master
5
+ - master
6
+ paths-ignore :
7
+ - ' docs/**'
8
+ - ' .circleci/**'
9
+ - ' .github/**'
9
10
jobs :
10
11
build :
11
12
runs-on : ' ubuntu-latest'
18
19
steps :
19
20
- uses : actions/checkout@v2
20
21
- name : Set up JDK
21
- uses :
joschi /setup-[email protected]
22
+ uses : actions /setup-java@v1
22
23
with :
23
24
java-version : ${{ matrix.java_version }}
24
25
27
28
key : ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
28
29
restore-keys : |
29
30
${{ runner.os }}-maven-
30
- - name : Build with Maven
31
- run : ./mvnw -V -B -ntp -ff install '-DskipTests=true' '-Dmaven.javadoc.skip=true'
32
31
- name : Run tests
33
32
run : ./mvnw -V -B -ntp -ff verify
33
+ - name : Release Snapshot
34
+ if : matrix.java_version == '11'
35
+ run : ./mvnw -V -B -ntp -ff deploy
Original file line number Diff line number Diff line change
1
+ name : Pull Request Checks
2
+ on :
3
+ - pull_request
4
+
5
+ jobs :
6
+ cleanup :
7
+ name : Cleanup any previous jobs
8
+ runs-on : ubuntu-latest
9
+ if : " !startsWith(github.ref, 'refs/tags/') && github.ref != 'refs/heads/master'"
10
+ steps :
11
+ -
uses :
rokroskar/[email protected]
12
+ env :
13
+ GITHUB_TOKEN : " ${{ secrets.GITHUB_TOKEN }}"
14
+ build :
15
+ runs-on : ubuntu-latest
16
+ strategy :
17
+ fail-fast : false
18
+ matrix :
19
+ java_version : ['8', '11', '15']
20
+ env :
21
+ JAVA_OPTS : " -XX:+TieredCompilation -XX:TieredStopAtLevel=1"
22
+ steps :
23
+ - uses : actions/checkout@v2
24
+ - name : Set up JDK
25
+ uses : actions/setup-java@v1
26
+ with :
27
+ java-version : ${{ matrix.java_version }}
28
+
29
+ with :
30
+ path : ~/.m2/repository
31
+ key : ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
32
+ restore-keys : |
33
+ ${{ runner.os }}-maven-
34
+ - name : Run tests
35
+ run : ./mvnw -V -B -ntp -ff verify
Original file line number Diff line number Diff line change
1
+ name : Triggered Release
2
+ on : [workflow_dispatch]
3
+
4
+ env :
5
+ OSS_USERNAME : ${{ secrets.OSS_USERNAME }}
6
+ OSS_PASSWORD : ${{ secrets.OSS_PASSWORD }}
7
+ GPG_PASSPHRASE : ${{ secrets.GPG_PASSPHRASE }}
8
+
9
+ jobs :
10
+ release :
11
+ runs-on : ubuntu-latest
12
+ if : github.ref == 'refs/heads/master'
13
+ steps :
14
+ - uses : actions/checkout@v2
15
+ - name : Set up JDK 11
16
+ uses : actions/setup-java@v1
17
+ with :
18
+ java-version : 11
19
+ # Value of the distributionManagement/repository/id field of the pom.xml
20
+ server-id : sonatype-nexus-staging
21
+ gpg-private-key : ${{ secrets.GPG_PRIVATE_KEY }}
22
+ server-username : OSS_USERNAME
23
+ server-password : OSS_PASSWORD
24
+ gpg-passphrase : GPG_PASSPHRASE
25
+
26
+ with :
27
+ path : ~/.m2/repository
28
+ key : ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
29
+ restore-keys : |
30
+ ${{ runner.os }}-maven-
31
+ - name : Setup Git
32
+ run : |
33
+ git config --global committer.email "[email protected] "
34
+ git config --global committer.name "GitHub Release"
35
+ git config --global author.email "${GITHUB_ACTOR}@users.noreply.github.com"
36
+ git config --global author.name "${GITHUB_ACTOR}"
37
+ - name : Release
38
+ run : ./mvnw -B clean release:prepare release:perform -Prelease -Dgpg.passphrase=${{secrets.GPG_PASSPHRASE}} -Drepository.url=https://${GITHUB_ACTOR}:${{ secrets.GITHUB_TOKEN }}@github.com/${GITHUB_REPOSITORY}.git
39
+ - name : ' if failure -> rollback'
40
+ if : ${{ failure() }}
41
+ run : |
42
+ ./mvnw -B release:rollback -Prelease -Dgpg.passphrase=${{secrets.GPG_PASSPHRASE}}
43
+ echo "You may need to manually delete the GitHub tag, if it was created."
Original file line number Diff line number Diff line change 2
2
3
3
Compare two OpenAPI specifications (3.x) and render the difference to HTML plaintext, or Markdown files.
4
4
5
- [ ![ Test ] ( https://github.com/OpenAPITools/openapi-diff/workflows/Test /badge.svg )] ( https://github.com/OpenAPITools/openapi-diff/actions?query=branch%3Amaster+workflow%3ATest+ )
5
+ [ ![ Build ] ( https://github.com/OpenAPITools/openapi-diff/workflows/Main%20Build /badge.svg )] ( https://github.com/OpenAPITools/openapi-diff/actions?query=branch%3Amaster+workflow%3A"Main+Build" )
6
6
[ ![ Maven Central] ( https://img.shields.io/maven-central/v/org.openapitools.openapidiff/openapi-diff-core )] ( https://search.maven.org/artifact/org.openapitools.openapidiff/openapi-diff-core )
7
7
[ ![ Join the Slack chat room] ( https://img.shields.io/badge/Slack-Join%20the%20chat%20room-orange )] ( https://join.slack.com/t/openapi-generator/shared_invite/enQtNzAyNDMyOTU0OTE1LTY5ZDBiNDI5NzI5ZjQ1Y2E5OWVjMjZkYzY1ZGM2MWQ4YWFjMzcyNDY5MGI4NjQxNDBiMTlmZTc5NjY2ZTQ5MGM )
8
8
You can’t perform that action at this time.
0 commit comments