mirror of
https://github.com/jj-vcs/jj.git
synced 2025-12-23 06:01:01 +00:00
cli: unblock "jj git init --colocate" in existing Git repo directory
I'm not sure what's the conclusion in #2747, but I don't think there is a disagreement on allowing --colocate to import existing Git repo.
This commit is contained in:
parent
356037379a
commit
8d0414549b
9 changed files with 90 additions and 60 deletions
|
|
@ -66,12 +66,11 @@ changes.
|
|||
|
||||
## Working in a Git co-located repository
|
||||
|
||||
After doing `jj init --git-repo=.`, Git will be in
|
||||
a [detached HEAD state][detached], which is unusual, as Git mainly works with
|
||||
branches. In a co-located repository, every `jj` command will automatically
|
||||
synchronize Jujutsu's view of the repo with Git's view. For example,
|
||||
`jj commit` updates the HEAD of the Git repository, enabling an incremental
|
||||
migration.
|
||||
After doing `jj git init --colocate`, Git will be in a [detached HEAD
|
||||
state][detached], which is unusual, as Git mainly works with branches. In a
|
||||
co-located repository, every `jj` command will automatically synchronize
|
||||
Jujutsu's view of the repo with Git's view. For example, `jj commit` updates the
|
||||
HEAD of the Git repository, enabling an incremental migration.
|
||||
|
||||
```shell
|
||||
$ nvim docs/tutorial.md
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue