1
0
Prechádzať zdrojové kódy

Do not print newline for prompt if not in a git repo

DricomDragon 5 rokov pred
rodič
commit
3fb5f75637

+ 3 - 1
Install/Templates/fish/functions/fish_prompt.fish

@@ -22,7 +22,9 @@ function fish_prompt --description 'Write out the prompt'
 
 	# Newline on tiny screens
 	if test $COLUMNS -lt 50
-		echo
+		if git rev-parse --is-inside-work-tree &> /dev/null
+			echo
+		end
 	end
 
     __terlar_git_prompt