Re: Show current SHA1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2009-07-11 10:39 (+0100), Allan Kelly wrote:

> The question then is: what is the command to report the current SHA1?
> Note I never branch in the HTML repo, it's entirely linear.

If the "current SHA1" means "the SHA1 of the most recent commit in the
current branch" then usually

    git show

is the simplest way. There are many ways to print _only_ the SHA1.
Examples:

    git log -1 --pretty=format:%H
    git rev-list -1 HEAD
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]