[mythtv-users] git & wiki

Jarod Wilson jarod at wilsonet.com
Wed Dec 8 19:20:01 UTC 2010


On Dec 8, 2010, at 11:32 AM, Udo van den Heuvel wrote:

> On 2010-12-08 17:13, Jarod Wilson wrote:
>> On Dec 8, 2010, at 10:10 AM, Udo van den Heuvel wrote:
>>> On 2010-12-08 15:07, Ian Kent wrote:
>>>> On Wed, 2010-12-08 at 21:57 +0800, Ian Kent wrote:
>>>>>> E.g.: I still need to find out how to get the git commit number we're at
>>>>>> to adjust the name of the mythtv rpms.
>>>>> 
>>>>> git show HEAD | head -1 | awk '{print $2}'
>>> 
>>> Hey, thanks!
>> 
>> No, ew, there are better ways. See below. :)
> (...)
>> 
>> git describe | cut -d- -f 3
> 
> Even better!
> But it doesn't always work:
> 
> [root at recorder mythweb.git]# pwd
> /usr/src/mythweb.git
> [root at recorder mythweb.git]# git describe | cut -d- -f 3
> fatal: No names found, cannot describe anything.
> [root at recorder mythweb.git]# git show HEAD | head -1 | awk '{print $2}'
> 52cb8fb98f1aa209cfd2befa92a9cdd0b7841070
> 
> How come?

Not sure how you managed that, I've never had it not work. Are
you running that in a local branch and/or with a detached HEAD?


-- 
Jarod Wilson
jarod at wilsonet.com





More information about the mythtv-users mailing list