From 0f4e1958194b0a90329001cc1b0602908cf6d875 Mon Sep 17 00:00:00 2001 From: Johannes Altmanninger Date: Sun, 12 Jan 2025 11:14:26 +0100 Subject: [PATCH] fish_jj_prompt: remove change ID This is not really helpful because it's somewhat transient; also we can usually use the @ alias. --- share/functions/fish_jj_prompt.fish | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/share/functions/fish_jj_prompt.fish b/share/functions/fish_jj_prompt.fish index 288f4f753..b65f103ed 100644 --- a/share/functions/fish_jj_prompt.fish +++ b/share/functions/fish_jj_prompt.fish @@ -4,16 +4,18 @@ function fish_jj_prompt if not command -sq jj return 1 end - jj log 2>/dev/null --no-graph --ignore-working-copy --color=always --revisions @ \ - --template ' - concat( - " ", + set -l info "$( + jj log 2>/dev/null --no-graph --ignore-working-copy --color=always --revisions @ \ + --template ' separate(" ", - format_short_change_id_with_hidden_and_divergent_info(self), bookmarks, tags, if(conflict, label("conflict", "×")), if(empty, label("empty", "(empty)")) - ), - )' + ) + ' + )" + if test -n $info + printf ' %s' $info + end end