<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Many different kinds of revision specifiers</title>
	<atom:link href="http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/feed/" rel="self" type="application/rss+xml" />
	<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/</link>
	<description>Just another GNOME Blogs weblog</description>
	<pubDate>Tue, 07 Oct 2008 22:20:04 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
		<item>
		<title>By: Jakub Narebski</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-297</link>
		<dc:creator>Jakub Narebski</dc:creator>
		<pubDate>Tue, 01 Apr 2008 11:11:58 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-297</guid>
		<description>By the way, all graphical history viewers (gitk and qgit, probably also gitnub, gitview and giggle) show branches (heads) and tags markers along revision list (revision graph). 

Also, git-show-branch uses "transient" counting backwards from branches notation; unfortunately it is one of less known commands, and its output is a bit cryptic. It would be nice if git-log had switch which would function as if git-name-rev was specified as filter; the --decorate option only adds refs (heads and branches) markers in a way similar to gitk, qgit and gitweb.

As to git-describe output: it looks (by default) like this: v1.5.5-rc2-1-ge95d75d, which means 1 commit since version tagged v1.5.5, with shortened sha1 being e95d75d (with 7 characters it should be unique in most repositories). The sha-1 is needed because with multiple branches there can be, and usually are, more than one commit (revision) can be 1 commit after given tag.

As to being user-friendly... git still shows its origin as a bucnh of low level "plumbing" tools for hackers to use to build they own SCM scripts; it has much, much improved since.</description>
		<content:encoded><![CDATA[<p>By the way, all graphical history viewers (gitk and qgit, probably also gitnub, gitview and giggle) show branches (heads) and tags markers along revision list (revision graph). </p>
<p>Also, git-show-branch uses &#8220;transient&#8221; counting backwards from branches notation; unfortunately it is one of less known commands, and its output is a bit cryptic. It would be nice if git-log had switch which would function as if git-name-rev was specified as filter; the &#8211;decorate option only adds refs (heads and branches) markers in a way similar to gitk, qgit and gitweb.</p>
<p>As to git-describe output: it looks (by default) like this: v1.5.5-rc2-1-ge95d75d, which means 1 commit since version tagged v1.5.5, with shortened sha1 being e95d75d (with 7 characters it should be unique in most repositories). The sha-1 is needed because with multiple branches there can be, and usually are, more than one commit (revision) can be 1 commit after given tag.</p>
<p>As to being user-friendly&#8230; git still shows its origin as a bucnh of low level &#8220;plumbing&#8221; tools for hackers to use to build they own SCM scripts; it has much, much improved since.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Elijah</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-296</link>
		<dc:creator>Elijah</dc:creator>
		<pubDate>Tue, 01 Apr 2008 02:54:49 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-296</guid>
		<description>Thomas: The leading one is just ugly legacy cruft, AFAICT.  I don't know exactly how it came about, but it is technically possible to get a leading 2 or 3 or whatever.  If you google on '"Assigning revisions" cederqvist' you'll find some links talking about how it's just convention and the -r option to cvs commit allows you to change the leading revision (though it apparently has some gotchas and I think I remember reading some people advising against it for various reasons).  Another good read on the matter is http://www.eyrie.org/~eagle/notes/cvs/revisions.html.

Havoc: I kind of like having cryptographic checksums around for unique identifiers (they seem cooler than bzr revid's, IMO); I just think an easily usable and manipulatable identifier is _also_ needed and that it should be just as prominent.  I think hg had the right idea here, though I'd rather have something more meaningful and structural than simple 0...n.

Gabriel: Thanks.  :-)

James: I modified the post to fix the mistake (changing a couple "revisions" to "revision numbers"); let me know if I still missed anything.  I did specify that revids were unique in the original text; was I not clear enough?  Thanks for pointing out the issues.

tonfa: hg stores branch names under revision control too?!?  Um, I guess that explains some comments I heard.  Interesting; thanks for the explanation.

Jakub:

Cool, thanks for the pointer about git-describe.  What does the shortened sha1 output by git-describe refer to?  Also, I like how you put your numbering schemes comment; I should probably quote that in my post somewhere.

Should I have said more about the commit descriptions in git?  I'm quite familiar with the transiency issues and git-name-rev (see http://www.gnome.org/~newren/eg/git-eg-differences.html#log).  In fact, I don't see the transience issue as a problem at all but a benefit (it makes it a lot easier to refer to "2 commits ago" than can be done in other systems where I first have to find out the current revision number) and it's really just an extension of the idea of hg and bzr to use easy-to-use revision numbers that are only valid locally.

My issue with git here isn't that git doesn't have facilities for users to obtain useful information, it's that it doesn't bother helping users obtain it and learn the system.  Personally, I don't think the --decorate option to git-log is all that useful (except maybe in special circumstances), and even the documentation for git-name-rev suggests a non-optimal use.  But even if --decorate was generally useful or the example command in the git-name-rev doc was the optimal one, the problem is that git passes up one of the best opportunities to give users easily manipulatable versions, teach them revision specifiers, and give them a small picture of the structure of the commits.  While I've railed on git for being user-hostile, I really have found that git is quite close to being a friendly system like the others; it really doesn't take that much to fix it up.  A few small changes here and there (plus filling in a huge documentation gap) really does transform it from user-hostile to user-friendly.</description>
		<content:encoded><![CDATA[<p>Thomas: The leading one is just ugly legacy cruft, AFAICT.  I don&#8217;t know exactly how it came about, but it is technically possible to get a leading 2 or 3 or whatever.  If you google on &#8216;&#8221;Assigning revisions&#8221; cederqvist&#8217; you&#8217;ll find some links talking about how it&#8217;s just convention and the -r option to cvs commit allows you to change the leading revision (though it apparently has some gotchas and I think I remember reading some people advising against it for various reasons).  Another good read on the matter is <a href="http://www.eyrie.org/~eagle/notes/cvs/revisions.html" rel="nofollow">http://www.eyrie.org/~eagle/notes/cvs/revisions.html</a>.</p>
<p>Havoc: I kind of like having cryptographic checksums around for unique identifiers (they seem cooler than bzr revid&#8217;s, IMO); I just think an easily usable and manipulatable identifier is _also_ needed and that it should be just as prominent.  I think hg had the right idea here, though I&#8217;d rather have something more meaningful and structural than simple 0&#8230;n.</p>
<p>Gabriel: Thanks.  <img src='http://blogs.gnome.org/newren/wp-content/mu-plugins/tango-smilies/tango/face-smile.png' alt=':-)' class='wp-smiley' width='16' height='16' /> </p>
<p>James: I modified the post to fix the mistake (changing a couple &#8220;revisions&#8221; to &#8220;revision numbers&#8221;); let me know if I still missed anything.  I did specify that revids were unique in the original text; was I not clear enough?  Thanks for pointing out the issues.</p>
<p>tonfa: hg stores branch names under revision control too?!?  Um, I guess that explains some comments I heard.  Interesting; thanks for the explanation.</p>
<p>Jakub:</p>
<p>Cool, thanks for the pointer about git-describe.  What does the shortened sha1 output by git-describe refer to?  Also, I like how you put your numbering schemes comment; I should probably quote that in my post somewhere.</p>
<p>Should I have said more about the commit descriptions in git?  I&#8217;m quite familiar with the transiency issues and git-name-rev (see <a href="http://www.gnome.org/~newren/eg/git-eg-differences.html#log" rel="nofollow">http://www.gnome.org/~newren/eg/git-eg-differences.html#log</a>).  In fact, I don&#8217;t see the transience issue as a problem at all but a benefit (it makes it a lot easier to refer to &#8220;2 commits ago&#8221; than can be done in other systems where I first have to find out the current revision number) and it&#8217;s really just an extension of the idea of hg and bzr to use easy-to-use revision numbers that are only valid locally.</p>
<p>My issue with git here isn&#8217;t that git doesn&#8217;t have facilities for users to obtain useful information, it&#8217;s that it doesn&#8217;t bother helping users obtain it and learn the system.  Personally, I don&#8217;t think the &#8211;decorate option to git-log is all that useful (except maybe in special circumstances), and even the documentation for git-name-rev suggests a non-optimal use.  But even if &#8211;decorate was generally useful or the example command in the git-name-rev doc was the optimal one, the problem is that git passes up one of the best opportunities to give users easily manipulatable versions, teach them revision specifiers, and give them a small picture of the structure of the commits.  While I&#8217;ve railed on git for being user-hostile, I really have found that git is quite close to being a friendly system like the others; it really doesn&#8217;t take that much to fix it up.  A few small changes here and there (plus filling in a huge documentation gap) really does transform it from user-hostile to user-friendly.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: bronson</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-295</link>
		<dc:creator>bronson</dc:creator>
		<pubDate>Mon, 31 Mar 2008 17:28:46 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-295</guid>
		<description>Havoc, I disagree.  Right now Git uses 4 bits/char = 40 chars.  Even if you could encode 6 bits/char (base64), you'd still have a 28 character identifier.  That's still too long to type by hand.

So, I don't see any reason to introduce all the additional complexity of some sort of custom textual encoding.  Either way, the sha1 is unreadable and you'll never type more than the first 5 chars of it.</description>
		<content:encoded><![CDATA[<p>Havoc, I disagree.  Right now Git uses 4 bits/char = 40 chars.  Even if you could encode 6 bits/char (base64), you&#8217;d still have a 28 character identifier.  That&#8217;s still too long to type by hand.</p>
<p>So, I don&#8217;t see any reason to introduce all the additional complexity of some sort of custom textual encoding.  Either way, the sha1 is unreadable and you&#8217;ll never type more than the first 5 chars of it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jakub Narebski</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-294</link>
		<dc:creator>Jakub Narebski</dc:creator>
		<pubDate>Mon, 31 Mar 2008 15:42:25 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-294</guid>
		<description>First, descriptions of commits counting from branch tips backwards (e.g. HEAD^, or HEAD~5, or master~10^2~12) are transient; only those using tags are constant, but not all revisions have such description. Second, you can get them in git-log output using git-name-rev as filter (see documentation), or --decorate option to git-log.

BTW. there is yet another way to refer to revision (besides shortened sha-1), namely this returned by git-describe, in the form of closest tag + forward counting + shotened sha-1.

Note also that all numbering schemes either need central numbering authority (which repository we take those numbers from), or have to be local for a repository.</description>
		<content:encoded><![CDATA[<p>First, descriptions of commits counting from branch tips backwards (e.g. HEAD^, or HEAD~5, or master~10^2~12) are transient; only those using tags are constant, but not all revisions have such description. Second, you can get them in git-log output using git-name-rev as filter (see documentation), or &#8211;decorate option to git-log.</p>
<p>BTW. there is yet another way to refer to revision (besides shortened sha-1), namely this returned by git-describe, in the form of closest tag + forward counting + shotened sha-1.</p>
<p>Note also that all numbering schemes either need central numbering authority (which repository we take those numbers from), or have to be local for a repository.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tonfa</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-293</link>
		<dc:creator>tonfa</dc:creator>
		<pubDate>Mon, 31 Mar 2008 15:20:58 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-293</guid>
		<description>Hg branches are just a nickname for a particular flow of history, when you create a new changeset, it will by default inherit the nickname of the parent.
You have to keep in mind that this nickname is immutable and will stay in the history forever.

Afaik git branches is just a pointer to a particular head, no history is kept. There have been some talks in the Mercurial community to add "bookmarks" that would behave similar to that.

I think that the special naming for parents is quite nice, hg provides it with an extension (parentspec) for power users who wants it.

Another note about hg, is the possibility to use any non-ambiguous prefix of the hash as an identifier. I don't know if other SCM uses this but '.' can be used to identify the version you checkouted (working copy version).</description>
		<content:encoded><![CDATA[<p>Hg branches are just a nickname for a particular flow of history, when you create a new changeset, it will by default inherit the nickname of the parent.<br />
You have to keep in mind that this nickname is immutable and will stay in the history forever.</p>
<p>Afaik git branches is just a pointer to a particular head, no history is kept. There have been some talks in the Mercurial community to add &#8220;bookmarks&#8221; that would behave similar to that.</p>
<p>I think that the special naming for parents is quite nice, hg provides it with an extension (parentspec) for power users who wants it.</p>
<p>Another note about hg, is the possibility to use any non-ambiguous prefix of the hash as an identifier. I don&#8217;t know if other SCM uses this but &#8216;.&#8217; can be used to identify the version you checkouted (working copy version).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: James Henstridge</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-292</link>
		<dc:creator>James Henstridge</dc:creator>
		<pubDate>Mon, 31 Mar 2008 15:05:09 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-292</guid>
		<description>For your description of Bazaar, you've got the terminology a bit wrong: a "revision number" is not a "revision".  Revisions in Bazaar branches are unique.  On the other hand, a particular revision number may map to different revisions in different branches.  A revision ID uniquely identifies a revision globally, similar to a git or hg commit checksum.</description>
		<content:encoded><![CDATA[<p>For your description of Bazaar, you&#8217;ve got the terminology a bit wrong: a &#8220;revision number&#8221; is not a &#8220;revision&#8221;.  Revisions in Bazaar branches are unique.  On the other hand, a particular revision number may map to different revisions in different branches.  A revision ID uniquely identifies a revision globally, similar to a git or hg commit checksum.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gabriel Gunderson</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-291</link>
		<dc:creator>Gabriel Gunderson</dc:creator>
		<pubDate>Mon, 31 Mar 2008 14:44:43 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-291</guid>
		<description>Love your work on this topic - keep it up!

BTW, I was going to send you a link to Chris Ball's "Bugs Everywhere," but I see you've all ready commented there :)  Interesting stuff.</description>
		<content:encoded><![CDATA[<p>Love your work on this topic - keep it up!</p>
<p>BTW, I was going to send you a link to Chris Ball&#8217;s &#8220;Bugs Everywhere,&#8221; but I see you&#8217;ve all ready commented there <img src='http://blogs.gnome.org/newren/wp-content/mu-plugins/tango-smilies/tango/face-smile.png' alt=':)' class='wp-smiley' width='16' height='16' />  Interesting stuff.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Havoc</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-290</link>
		<dc:creator>Havoc</dc:creator>
		<pubDate>Mon, 31 Mar 2008 13:56:03 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-290</guid>
		<description>The crypto ones would be less unwieldy if encoded as base-52 or something (use all upper and lowercase consonants and digits, no vowels so no words are spelled). Though, pretty hard to switch at this point.</description>
		<content:encoded><![CDATA[<p>The crypto ones would be less unwieldy if encoded as base-52 or something (use all upper and lowercase consonants and digits, no vowels so no words are spelled). Though, pretty hard to switch at this point.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Thomas Thurman</title>
		<link>http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-289</link>
		<dc:creator>Thomas Thurman</dc:creator>
		<pubDate>Mon, 31 Mar 2008 13:17:55 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.gnome.org/newren/2008/03/31/many-different-kinds-of-revision-specifiers/#comment-289</guid>
		<description>Something that I've never understood: What on earth is the first "1" in a CVS revision number for?</description>
		<content:encoded><![CDATA[<p>Something that I&#8217;ve never understood: What on earth is the first &#8220;1&#8243; in a CVS revision number for?</p>
]]></content:encoded>
	</item>
</channel>
</rss>
