diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2025-01-28 19:04:25 +0100 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2025-01-28 19:04:25 +0100 |
commit | f65bfc52695607f179fbf70331b4028b40616642 (patch) | |
tree | 09834c39ca0a803819efaa9f9f17983b53bab064 | |
parent | 4905fb474a2d768e78b34029d443de0bf12a11f9 (diff) |
fix git prompt for new repositories
-rw-r--r-- | .zshrc | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -41,7 +41,7 @@ prompt_segment() { } prompt_mod_git_info() { git rev-parse --is-inside-work-tree 1> /dev/null 2> /dev/null || return - prompt_segment "git $(git rev-parse --abbrev-ref HEAD)" + prompt_segment "git $(git rev-parse --abbrev-ref HEAD 2> /dev/null)" } # only display hostname in prompt if connected over SSH [ -n "$SSH_CLIENT" ] && PROMPT+="$(prompt_segment '%m')" |