Skip to content

Commit f0112a9

Browse files
committed
Fix empty git branch and remote value issues
1 parent e65cbe5 commit f0112a9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

release/release.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,14 +233,14 @@ def releaseChecksTask = tasks.register( "releaseChecks" ) {
233233
String gitBranchLocal
234234
String gitRemoteLocal
235235

236-
if (project.hasProperty('gitBranch')) {
236+
if (project.hasProperty('gitBranch') && !project.property('gitBranch').isEmpty()) {
237237
gitBranchLocal = project.property('gitBranch')
238238
}
239239
else {
240240
gitBranchLocal = executeGitCommand( 'branch', '--show-current' ).trim()
241241
}
242242

243-
if (project.hasProperty('gitRemote')) {
243+
if (project.hasProperty('gitRemote') && !project.hasProperty('gitRemote').isEmpty()) {
244244
gitRemoteLocal = project.property('gitRemote')
245245
}
246246
else {

0 commit comments

Comments
 (0)