[MNG-6255] Maven script cannot parse jvm.config with CRLF

Both \r and \n should also be replaced with a space to deal with CRLF line 
endings properly


Project: http://git-wip-us.apache.org/repos/asf/maven/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven/commit/b918b0b1
Tree: http://git-wip-us.apache.org/repos/asf/maven/tree/b918b0b1
Diff: http://git-wip-us.apache.org/repos/asf/maven/diff/b918b0b1

Branch: refs/heads/MNG-6255
Commit: b918b0b128b242bc1d8812132ddb9c73f0bb14f3
Parents: 085ee9f
Author: Andrew Donald Kennedy <andrew.internatio...@gmail.com>
Authored: Mon Jul 10 16:58:33 2017 +0100
Committer: Hervé Boutemy <hbout...@apache.org>
Committed: Thu Feb 8 23:52:25 2018 +0100

----------------------------------------------------------------------
 apache-maven/src/bin/mvn | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven/blob/b918b0b1/apache-maven/src/bin/mvn
----------------------------------------------------------------------
diff --git a/apache-maven/src/bin/mvn b/apache-maven/src/bin/mvn
index e3a5848..65be711 100755
--- a/apache-maven/src/bin/mvn
+++ b/apache-maven/src/bin/mvn
@@ -167,7 +167,7 @@ find_file_argument_basedir() {
 # concatenates all lines of a file
 concat_lines() {
   if [ -f "$1" ]; then
-    echo "`tr -s '\n' ' ' < "$1"`"
+    echo "`tr -s '\r\n' '  ' < "$1"`"
   fi
 }
 

Reply via email to