Skip to content

Commit a4a087d

Browse files
authored
Fix release build configuration
1 parent e9fe1db commit a4a087d

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,10 @@ name: CI
99

1010
on:
1111
push:
12-
branches:
13-
- master
14-
tags-ignore:
15-
- v* # release tags are automatically generated after a successful CI build, no need to run CI against them
12+
branches: ['master']
13+
tags: [v*]
1614
pull_request:
17-
branches:
18-
- master
15+
branches: ['**']
1916

2017
jobs:
2118

@@ -77,10 +74,10 @@ jobs:
7774
release:
7875
concurrency: release
7976
runs-on: ubuntu-latest
80-
needs: [build] # build job must pass before we can release
77+
needs: [verify, build] # build job must pass before we can release
8178

8279
if: github.event_name == 'push'
83-
&& github.ref == 'refs/heads/master'
80+
&& (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v'))
8481
&& github.repository == 'mockito/mockito-testng'
8582
&& !contains(toJSON(github.event.commits.*.message), '[skip release]')
8683

@@ -98,7 +95,7 @@ jobs:
9895
distribution: 'zulu'
9996

10097
- name: Build and publish to Sonatype/MavenCentral
101-
run: ./gradlew publishToSonatype closeAndReleaseStagingRepository githubRelease
98+
run: ./gradlew publishToSonatype closeAndReleaseStagingRepositories githubRelease
10299
env:
103100
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
104101
NEXUS_TOKEN_USER: ${{secrets.NEXUS_TOKEN_USER}}

version.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)