mirror of
https://github.com/martinvonz/jj.git
synced 2025-01-31 08:21:58 +00:00
89e0a7021a
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. |
||
---|---|---|
.. | ||
examples | ||
src | ||
testing | ||
tests | ||
build.rs | ||
Cargo.toml | ||
docs | ||
LICENSE |