Skip to content

Commit b478b47

Browse files
committed
1 parent 8670143 commit b478b47

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

README.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ removed lines in a file that is managed by a version control system (VCS)._
88
---
99

1010
- Supports **git**, **mercurial**, **darcs**, **bazaar**, **subversion**,
11-
**cvs**, **rcs**, **fossil**, **accurev**, **perforce**, **tfs**, **yadm**.
11+
**cvs**, **rcs**, **fossil**, **accurev**, **perforce**, **tfs**, **yadm**,
12+
**jj**.
1213
- **Asynchronous** execution of VCS tools for Vim 8.0.902+ and Neovim.
1314
- **Preserves signs** from other plugins.
1415
- Handles **nested repositories** controlled by different VCS.
@@ -46,6 +47,7 @@ endif
4647
```
4748

4849
## Configuration for async update
50+
4951
```vim
5052
" default updatetime 4000ms is not good for async update
5153
set updatetime=100

autoload/sy/repo.vim

+8-1
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,11 @@ function! s:check_diff_svn(exitval, diff) abort
179179
return a:exitval ? [0, []] : [1, a:diff]
180180
endfunction
181181

182+
" s:check_diff_jj {{{1
183+
function! s:check_diff_jj(exitval, diff) abort
184+
return a:exitval ? [0, []] : [1, a:diff]
185+
endfunction
186+
182187
" s:check_diff_bzr {{{1
183188
function! s:check_diff_bzr(exitval, diff) abort
184189
return (a:exitval =~ '[012]') ? [1, a:diff] : [0, []]
@@ -629,7 +634,8 @@ let s:default_vcs_cmds = {
629634
\ 'rcs': 'rcsdiff -U0 %f 2>%n',
630635
\ 'accurev': 'accurev diff %f -- -U0',
631636
\ 'perforce': 'p4 info '. sy#util#shell_redirect('%n') . (has('win32') ? ' &&' : ' && env P4DIFF= P4COLORS=') .' p4 diff -du0 %f',
632-
\ 'tfs': 'tf diff -version:W -noprompt -format:Unified %f'
637+
\ 'tfs': 'tf diff -version:W -noprompt -format:Unified %f',
638+
\ 'jj': 'jj diff --color=never --git --context=0 -r @ -- %f',
633639
\ }
634640

635641
let s:default_vcs_cmds_diffmode = {
@@ -645,6 +651,7 @@ let s:default_vcs_cmds_diffmode = {
645651
\ 'accurev': 'accurev cat %f',
646652
\ 'perforce': 'p4 print %f',
647653
\ 'tfs': 'tf view -version:W -noprompt %f',
654+
\ 'jj': 'jj file show -r @- -- %f',
648655
\ }
649656

650657
if exists('g:signify_vcs_cmds')

doc/signify.txt

+4-1
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ The key can be any from this list:
163163
accurev
164164
perforce
165165
tfs
166+
jj
166167

167168
Modifiers:~
168169

@@ -201,7 +202,8 @@ Default:
201202
\ 'rcs': 'rcsdiff -U0 %f 2>%n',
202203
\ 'accurev': 'accurev diff %f -- -U0',
203204
\ 'perforce': 'p4 info '. sy#util#shell_redirect('%n') . (has('win32') ? ' &&' : ' && env P4DIFF= P4COLORS=') .' p4 diff -du0 %f',
204-
\ 'tfs': 'tf diff -version:W -noprompt -format:Unified %f'
205+
\ 'tfs': 'tf diff -version:W -noprompt -format:Unified %f',
206+
\ 'jj': 'jj diff --color=never --context=0 -r @ -- %f',
205207
\ }
206208
<
207209
------------------------------------------------------------------------------
@@ -219,6 +221,7 @@ Default:
219221
\ 'accurev': 'accurev cat %f',
220222
\ 'perforce': 'p4 print %f',
221223
\ 'tfs': 'tf view -version:W -noprompt %f',
224+
\ 'jj': 'jj file show -r @- -- %f',
222225
\ }
223226
<
224227
The command to use for updating signs in a `modified` buffer, thus when the

0 commit comments

Comments
 (0)