jj/cli
Yuya Nishihara 89e0a7021a cli: git: store absolute remote path in config file
The "git" CLI chdir()s to the work tree root, so paths in config file are
usually resolved relative to the workspace root. OTOH, jj doesn't modify the
process environment, so libgit2 resolves remote paths relative to cwd, not to
the workspace root. To mitigate the problem, this patch makes "jj git remote"
sub commands to store resolved path in .git/config. It would be nice if we can
reconfigure in-memory git2 remote object to use absolute paths (or set up
in-memory named remote without writing a config file), but there's no usable
API afaik.

This behavior is different from "git remote add"/"set-url". I don't know the
rationale, but these commands don't resolve relative paths, whereas "git clone"
writes resolved path to .git/config. I think it's more consistent to make all
"jj git" sub commands resolve relative paths.
2025-01-12 01:45:03 +00:00
..
examples examples: use settings_for_new_workspace() when initializing workspace 2025-01-06 21:15:28 +09:00
src cli: git: store absolute remote path in config file 2025-01-12 01:45:03 +00:00
testing merge_tools: add "$marker_length" variable 2024-12-23 08:42:10 -06:00
tests cli: git: store absolute remote path in config file 2025-01-12 01:45:03 +00:00
build.rs build: fix cargo publish by symlinking cli/docs->docs 2024-11-05 17:37:14 -08:00
Cargo.toml cli: make git support optional 2025-01-08 22:02:21 +00:00
docs build: fix cargo publish by symlinking cli/docs->docs 2024-11-05 17:37:14 -08:00
LICENSE