From baa00093557d4e7e41d67ac8acfd4daccb154afd Mon Sep 17 00:00:00 2001 From: Samuel Holland Date: Mon, 22 Jan 2018 10:57:29 -0600 Subject: Support relative paths in --reference Put the correctly-expanded relative paths in objects/info/alternates. From gitrepository-layout(5), this path should be "relative to the object database, not to the repository". Change-Id: I7b2027ae23cf7d367b80f5a187603c4cbacdb2de --- subcmds/init.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'subcmds/init.py') diff --git a/subcmds/init.py b/subcmds/init.py index eeddca06..9466b9a2 100644 --- a/subcmds/init.py +++ b/subcmds/init.py @@ -401,7 +401,7 @@ to update the working directory files. git_require(MIN_GIT_VERSION, fail=True) if opt.reference: - opt.reference = os.path.abspath(os.path.expanduser(opt.reference)) + opt.reference = os.path.expanduser(opt.reference) # Check this here, else manifest will be tagged "not new" and init won't be # possible anymore without removing the .repo/manifests directory. -- cgit v1.2.3-54-g00ecf