gradle-GitVersioner icon indicating copy to clipboard operation
gradle-GitVersioner copied to clipboard

Version Code is never got updated

Open LeiWangAndroid opened this issue 8 years ago • 2 comments

Hi, @passsy , I am applying the the git-versioner.gradle into my project, and I have problem to get versionCode updated, no matter how many commits has been updated, but they are still 277.

I checked my git version, it is git version 2.10.1, and the git path is located at: /usr/local/bin/git

Has anyone meet the same issue?

LeiWangAndroid avatar Apr 05 '17 09:04 LeiWangAndroid

Hard to tell what's wrong. can you copy the file to your project and use this one to debug the problem with some println?

passsy avatar Apr 05 '17 10:04 passsy

I just got an idea. when you commit something you're most likely not on the defaultBranch. The version only increases for commits on the default branch. Commits on other branches are represented as 1083-dm4 where 1083 is the version of the defaultBranch and 4 the commits on the feature branch (which should increase in your case).

passsy avatar Apr 14 '17 13:04 passsy