From 19856737b62f17a35bc8fc3f6240bca7980b42de Mon Sep 17 00:00:00 2001 From: Sebastian Schuberth Date: Wed, 27 Apr 2011 18:38:04 +0200 Subject: [PATCH] submodule: Use cat instead of echo to avoid DOS line-endings In msysGit, echo used in scripts outputs DOS line-endings while built-ins use Unix line-endings in their output. This causes t7508-status to fail due to mixed line endings in the output of git status (which calls git-submodule). Signed-off-by: Sebastian Schuberth --- git-submodule.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/git-submodule.sh b/git-submodule.sh index c1d3a5e2fa..c1e89edd85 100755 --- a/git-submodule.sh +++ b/git-submodule.sh @@ -750,12 +750,16 @@ cmd_summary() { done | if test -n "$for_status"; then if [ -n "$files" ]; then - gettext "# Submodules changed but not updated:"; echo + status_msg="$(gettext "# Submodules changed but not updated:")" else - gettext "# Submodule changes to be committed:"; echo + status_msg="$(gettext "# Submodule changes to be committed:")" fi - echo "#" - sed -e 's|^|# |' -e 's|^# $|#|' + status_sed=$(sed -e 's|^|# |' -e 's|^# $|#|') + cat <