forked from mirrors/jj
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() {
|
||||
// TODO: Make this hint separate from the error, so the caller can format
|
||||
// it differently.
|
||||
let git_dir_str = PathBuf::from(wc_path_str)
|
||||
.join(".git")
|
||||
.to_str()
|
||||
.unwrap()
|
||||
.to_owned();
|
||||
message += &format!(
|
||||
"
|
||||
message += "
|
||||
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>",
|
||||
git_dir_str
|
||||
);
|
||||
jj init --git-store=.";
|
||||
}
|
||||
return Err(CommandError::UserError(message));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue