Re: [GSoC Patch v3 3/4] repo: add path.commondir with absolute and relative suffix formatting
- From
Lucas Seiki Oshiro <lucasseikioshiro@gmail.com>
- Date
- Jun 15, 2026, 01:54 UTC
- Message-ID
- <B0AAB2FE-5E7B-4C67-8A71-84C1A3ACBA44@gmail.com>
- In-Reply-To
- <20260612182847.562816-4-jayatheerthkulkarni2005@gmail.com>
> + test_expect_success "absolute: $label" ' > + ( > + cd "$absolute_root/sub" && > + ROOT="$(test-tool path-utils real_path "..")" && export ROOT &&
Be carful with the quotes here. Actually, there's no need to use quotes around `..`, and export can be used directly with the env var:
export ROOT="$(test-tool path-utils real_path ..)" &&
Show 5 quoted lines
> > + test_expect_success "relative: $label" ' > + ( > + cd "$relative_root/sub" && > + ROOT="$(test-tool path-utils real_path "..")" && export ROOT &&
Same here.
> +test_repo_info_path 'commondir with GIT_COMMON_DIR and GIT_DIR' 'commondir' \ > + 'commondir-envs' 'custom-common' '../custom-common' \ > + 'GIT_COMMON_DIR="$ROOT/custom-common" && export GIT_COMMON_DIR && > + GIT_DIR="../.git" && export GIT_DIR &&
export GIT_COMMON_DIR="$ROOT/custom-common" && export GIT_DIR="../.git" &&