gradle-android-git-version icon indicating copy to clipboard operation
gradle-android-git-version copied to clipboard

External process issue with gradle configuration cache enabled

Open anr2me opened this issue 1 year ago • 2 comments

With org.gradle.configuration-cache=true in gradle.properties file. Using androidGitVersion.name() or androidGitVersion.code() in build.gradle file will triggers this issue:

2 problems were found storing the configuration cache.
- Build file 'android/build.gradle': line 64: external process started 'git --version'
  See https://docs.gradle.org/8.4/userguide/configuration_cache.html#config_cache:requirements:external_processes
- Build file 'android/build.gradle': line 64: external process started 'git config --system --edit'
  See https://docs.gradle.org/8.4/userguide/configuration_cache.html#config_cache:requirements:external_processes

According to the linked docs, in order to solve external process started 'git --version' issue can use:

def gitVersion = providers.exec {
    commandLine("git", "--version")
}.standardOutput.asText.get()

But how can we do this when using com.gladed.androidgitversion plugin?

anr2me avatar Jun 09 '24 21:06 anr2me

I'm having the same problem

jpilgrim-eng avatar Jul 05 '24 18:07 jpilgrim-eng

This is occurring for me as well.

omniuni avatar Jul 15 '24 06:07 omniuni