mirror of
https://github.com/martinvonz/jj.git
synced 2025-01-18 10:07:28 +00:00
cli: when run in git repo, hint about setting up collocated jj workspace (#44)
Now that it's much easier to use a shared working copy between git and jj, let's update the hint about how to set up a jj repo backed by the git repo to use a shared working copy.
This commit is contained in:
parent
ccfaf0f601
commit
7f61deeb21
1 changed files with 2 additions and 10 deletions
|
@ -185,17 +185,9 @@ impl<'args> CommandHelper<'args> {
|
||||||
if git_dir.is_dir() {
|
if git_dir.is_dir() {
|
||||||
// TODO: Make this hint separate from the error, so the caller can format
|
// TODO: Make this hint separate from the error, so the caller can format
|
||||||
// it differently.
|
// it differently.
|
||||||
let git_dir_str = PathBuf::from(wc_path_str)
|
message += "
|
||||||
.join(".git")
|
|
||||||
.to_str()
|
|
||||||
.unwrap()
|
|
||||||
.to_owned();
|
|
||||||
message += &format!(
|
|
||||||
"
|
|
||||||
It looks like this is a git repo. You can create a jj repo backed by it by running this:
|
It looks like this is a git repo. You can create a jj repo backed by it by running this:
|
||||||
jj init --git-store={} <path to new jj repo>",
|
jj init --git-store=.";
|
||||||
git_dir_str
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
return Err(CommandError::UserError(message));
|
return Err(CommandError::UserError(message));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue