Re: [PATCH 2/3] cvsimport: use show-ref to support packed refs

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

 



On Wed, Nov 28, 2007 at 05:43:13PM -0500, Jeff King wrote:

> > 	sub get_headref {
> >         	my ($it) = (@_);
> >                 my $r = `git-rev-parse --verify "refs/$it"`;
> > 		return undef unless $? == 0;
> > 		chomp $r;
> > 		return $r;
> > 	}
> 
> I have no comment on which is the best command to use (you would know
> much better than I), but adding "refs/" is wrong.

BTW, one bad thing about the new get_headref compared to the original is
that it does not distinguish very well between "ref does not exist" and
"an error occurred." Is there a lookup command that makes such a
distinction possible?

-Peff
-
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]

  Powered by Linux