Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: GIT source code variables question?

by rjbs (Pilgrim)
on Apr 14, 2008 at 14:47 UTC ( #680305=note: print w/replies, xml ) Need Help??


in reply to GIT source code variables question?

Basically, there is no automated way to do this. Git revisions are not guaranteed to increment, so you'd end up with the SHA1 identifier of the commit rather than a number. Further, unlike in Subversion, your git checkout is identical to the content in the repo. There is no munging of the content on checkout like there is with Subversion, which is what allows keyword expansion.

I suggest disabling the policy. I use Perl::Version's perl-reversion script to keep track of my actual released versions. It's not as exact as a git identifier, but it's good.
rjbs
  • Comment on Re: GIT source code variables question?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://680305]
help
Chatterbox?
[jedikaiti]: Pretty!
[erix]: ( TBH, I think it's a load of bull -- but maybe I'm mistaken )
[erix]: Hey that's Hungary - wave down ambrus and tell him to reboot his systems!
[choroba]: it might be a problem if you expect to reach the maximal possible value soon without squashing the ids
[erix]: that's really impossible with bigint
[erix]: and the site is still only 'hopefully' active :)
[erix]: but fair enough, he may think he solves a problem

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2017-06-23 15:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (550 votes). Check out past polls.