fish: Prettier jj right prompt
This commit is contained in:
parent
74c622efab
commit
504cfd30ef
1 changed files with 35 additions and 24 deletions
|
@ -101,30 +101,41 @@
|
||||||
end
|
end
|
||||||
|
|
||||||
# Generate prompt
|
# Generate prompt
|
||||||
jj log --ignore-working-copy --no-graph --color always -r @ -T '
|
jj log --ignore-working-copy --no-graph --color never -r @ -T '
|
||||||
separate(
|
surround(
|
||||||
" ",
|
" \e[2;3m",
|
||||||
change_id.shortest(),
|
"\e[0m",
|
||||||
coalesce(
|
separate(
|
||||||
surround(
|
" ",
|
||||||
"\"",
|
bookmarks.join(", "),
|
||||||
"\"",
|
coalesce(
|
||||||
if(
|
surround(
|
||||||
description.first_line().substr(0, 24).starts_with(description.first_line()),
|
"\"",
|
||||||
description.first_line().substr(0, 24),
|
"\"",
|
||||||
description.first_line().substr(0, 23) ++ "…"
|
if(
|
||||||
)
|
description.first_line().substr(0, 24).starts_with(description.first_line()),
|
||||||
),
|
description.first_line().substr(0, 24),
|
||||||
"(no description set)"
|
description.first_line().substr(0, 23) ++ "…"
|
||||||
),
|
)
|
||||||
bookmarks.join(", "),
|
),
|
||||||
commit_id.shortest(),
|
"…"
|
||||||
if(conflict, "(conflict)"),
|
),
|
||||||
if(empty, "(empty)"),
|
surround(
|
||||||
if(divergent, "(divergent)"),
|
"\e[0;1;35m",
|
||||||
if(hidden, "(hidden)"),
|
"\e[0;2;3m",
|
||||||
)
|
change_id.shortest(),
|
||||||
'
|
),
|
||||||
|
surround(
|
||||||
|
"\e[0;34m",
|
||||||
|
"\e[0;2;3m",
|
||||||
|
commit_id.shortest(),
|
||||||
|
),
|
||||||
|
if(conflict, "(conflict)"),
|
||||||
|
if(empty, "…)"),
|
||||||
|
if(divergent, "(divergent)"),
|
||||||
|
if(hidden, "(hidden)"),
|
||||||
|
)
|
||||||
|
)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
fish_prompt.body = ''
|
fish_prompt.body = ''
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue