I'm using maven to build and run my project on Intellij IDEA.
For tracking purposes I would like to be able to get/fetch the build number associated on VCS/Localhistory directly into my java code. Rather than get the number, if I was able to create my own and set the build number on local history it should be ok.
Like you see on that picture, I would like to get 6826bed7 or 40cfe86c like this :
public static void main(...) {
// Stuff like this
String buildNumber = IntellijInternalApi.getThisBuildNumber();
// this should print 6826bed7 in my example
System.out.println(builNumber);
}
Any idea or solution ?