axion-release-plugin
axion-release-plugin copied to clipboard
JGit sees non-existing changes
My workspace is clean:
$ LANG=POSIX git status
On branch <my-branch-name>
nothing to commit, working tree clean
Still, when I execute the release command, the plugin / JGit tells me that there are many uncommitted changes:
$ ./gradlew release
> Task :verifyRelease FAILED
Looking for uncommitted changes.. FAILED
Staged changes:
Unstaged changes:
modified: path/to/File.kt
...
This is on Cygwin / Bash, using Axion Plugin 1.10.3 with Git 2.21.0. How can I further track this issue down?
Could you create minimal project, just git repo and build.gradle with axion-release and see how it behaves? I'm trying to find out if its env or repo problem.
@adamdubiel The problem persists, minimalist build.gradle:
buildscript {
repositories {
maven { url 'https://company/artifactory/jcenter-remote/' }
maven { url 'https://company/artifactory/maven-remote/' }
}
dependencies {
classpath "pl.allegro.tech.build:axion-release-plugin:1.10.3"
}
}
apply plugin: 'pl.allegro.tech.build.axion-release'
Then, on ./gradlew release:
./gradlew release
Starting a Gradle Daemon (subsequent builds will be faster)
> Task :verifyRelease FAILED
Looking for uncommitted changes.. FAILED
Staged changes:
Unstaged changes:
modified: gradlew
modified: gradle/wrapper/gradle-wrapper.jar
modified: build.gradle
modified: gradle/wrapper/gradle-wrapper.properties
modified: gradlew.bat
modified: gradle.properties
added: .gradle/5.6.4/executionHistory/executionHistory.lock
added: .gradle/buildOutputCleanup/buildOutputCleanup.lock
added: .gradle/buildOutputCleanup/cache.properties
added: .gradle/5.6.4/fileHashes/fileHashes.lock
added: .gradle/5.6.4/executionHistory/executionHistory.bin
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':verifyRelease'.
while the workspace is clean. Sidenote: .gradle/ is untracked and not ignored, still, JGit tracks it as added.
@realdadfish hey, is this issue still occurs with newest axion release?
Haven't looked for this issue in quite some time, sorry, cannot say if this is still an issue or not ATM.
This is still an issue with 1.13.6 / Gradle 7.2:
$ git status
On branch my/private-branch
nothing to commit, working tree clean
$ gradle release
> Task :verifyRelease FAILED
Looking for uncommitted changes.. FAILED
Staged changes:
Unstaged changes:
removed: path/to/some.RoomDatabase/1.json
JGit is unfortunately not very well maintained, I have at least one other problem regarding Git Worktrees that I have to work-around.