I do not know how correct the question is, but you need to do so that when the build is going to somehow pull up information about the commit from which this build is being done, so that it can be tracked if a bug appears then in which version ...

How can you do this?

  • What version control system? There is no universal way, for obvious reasons. - D-side
  • and what is the build system? In general, you get a hash from VCS and put it in the .properties file when building it. You can even bat file. - Nofate
  • @ D-side working with gitlab - Aleksey Timoshchenko
  • @Nofate gradle build gradle - Aleksey Timoshchenko
  • You can simply run git rev-parse HEAD and write the value to the right place. - Nofate

0