Skip to content

Commit 4ca12e1

Browse files
committed
Merge branch 'ek/completion-use-read-r-to-read-literally'
The completion script used to use bare "read" without the "-r" option to read the contents of various state files, which risked getting confused with backslashes in them. This has been corrected. * ek/completion-use-read-r-to-read-literally: completion: suppress unwanted unescaping of `read`
2 parents 48d89b5 + 1971520 commit 4ca12e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/completion/git-prompt.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ __git_ps1_colorize_gitstring ()
298298
# variable, in that order.
299299
__git_eread ()
300300
{
301-
test -r "$1" && IFS=$'\r\n' read "$2" <"$1"
301+
test -r "$1" && IFS=$'\r\n' read -r "$2" <"$1"
302302
}
303303

304304
# see if a cherry-pick or revert is in progress, if the user has committed a

0 commit comments

Comments
 (0)