get_sha1: support relative path ":path" syntax
commit979f792951913d75f992f87022b75610303a614f
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>
Sun, 28 Nov 2010 03:37:32 +0000 (28 10:37 +0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 7 Dec 2010 22:25:46 +0000 (7 14:25 -0800)
tree9fb806af8cc96b58b89c19e2720bf71bf42cab3c
parentedc54fb5d4ce6774fc2ac76779bd57dc2d6ab189
get_sha1: support relative path ":path" syntax

Currently :path and ref:path can be used to refer to a specific object
in index or ref respectively. "path" component is absolute path. This
patch allows "path" to be written as "./path" or "../path", which is
relative to user's original cwd.

This does not work in commands for which startup_info is NULL
(i.e. non-builtin ones, it seems none of them needs this anyway).

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/revisions.txt
sha1_name.c
t/t1506-rev-parse-diagnosis.sh