From 9daabee2578245e5f39914138422446e3a339975 Mon Sep 17 00:00:00 2001 From: Yi-Ting Shih Date: Thu, 10 Apr 2025 23:35:34 +0800 Subject: [PATCH] Fix: pipestatus order --- functions/fish_prompt.fish | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/functions/fish_prompt.fish b/functions/fish_prompt.fish index 9f2d072..23a68a6 100644 --- a/functions/fish_prompt.fish +++ b/functions/fish_prompt.fish @@ -19,8 +19,11 @@ function fish_prompt --description 'Informative prompt' set -l git_root_basename (basename "$git_root") set cwd (string replace --regex "^$git_root" "($git_root_basename)" "$cwd") end - printf '[%s] %s%s@%s %s%s %s%s%s%s%s \n> ' (date "+%H:%M:%S") (set_color brblue) \ - $USER (prompt_hostname) (set_color $fish_color_cwd) $cwd $pipestatus_string \ - (set_color yellow) (string trim -l (fish_git_prompt)) (set_color normal) + printf '[%s] %s%s@%s %s%s %s%s%s %s%s\n> ' (date "+%H:%M:%S") \ + (set_color brblue) $USER (prompt_hostname) \ + (set_color $fish_color_cwd) $cwd \ + (set_color yellow) (string trim -l (fish_git_prompt)) \ + $pipestatus_string \ + (set_color normal) end end