-
-
Notifications
You must be signed in to change notification settings - Fork 203
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(jujutsu): add jujustu support (#930)
* feat: jujustu support If the .git directory can't be opened (usually because the `.git` directory is missing) it attempts to find the git repository in the location used by Jujutsu (i.e. `.jj/repo/store/git`). If the Jujutsu git directory doesn't exist, then the origin error is propogated. CODE test: add unit tests for opening jujutsu repo Update git-cliff-core/src/repo.rs Co-authored-by: Orhun Parmaksız <[email protected]> Update git-cliff-core/src/repo.rs Co-authored-by: Orhun Parmaksız <[email protected]> Update git-cliff-core/src/repo.rs Co-authored-by: Orhun Parmaksız <[email protected]> Update git-cliff-core/src/repo.rs Co-authored-by: Orhun Parmaksız <[email protected]> * docs: Add page to website for jujutsu --------- Co-authored-by: Orhun Parmaksız <[email protected]>
- Loading branch information
Showing
2 changed files
with
102 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
--- | ||
sidebar_position: 12 | ||
--- | ||
|
||
# Jujutsu | ||
|
||
You can use with a repository that has been cloned using [jujutsu](https://martinvonz.github.io/jj/latest/). | ||
|
||
## Colocated | ||
|
||
If the repository was cloned by `jujutsu` using the `--colocate` option, then all you need to do is make sure that | ||
you have checked out your mainline branch using git. | ||
If you don't, then you will likely see an error about an unborn branch. | ||
|
||
## Non-colocated | ||
|
||
If the repository was cloned by `jujutsu` but *not* using the `--colocate` option, | ||
then the Git repository, normally the `.git` directory, is located in `.jj/repo/store/git` | ||
|
||
Create a file in the root of your repository that tells Git, and `git-cliff` where the Git repository is | ||
and update the `HEAD` to point to your main remote branch: | ||
|
||
e.g.: | ||
|
||
```bash | ||
jj git clone https://github.com/orhun/menyoki | ||
cd menyoki | ||
echo "gitdir: .jj/repo/store/git" > .git | ||
echo "ref: refs/remotes/origin/master" > .jj/repo/store/git/HEAD | ||
``` | ||
|
||
N.B.: Replace `master` in the last command with the name of your main remote branch. e.g. `main`, `trunk`, etc. | ||
|