mirror of https://github.com/apache/maven.git
[MNG-5852] mvn shell script invokes /bin/sh but requires Bash functions
'local' is not POSIX, but supported by most shells. However, it's not supported by Solaris's /bin/sh, so use a subshell instead. This closes #50.
This commit is contained in:
parent
1d9708a954
commit
1351020227
|
@ -190,8 +190,7 @@ fi
|
|||
# traverses directory structure from process work directory to filesystem root
|
||||
# first directory with .mvn subdirectory is considered project base directory
|
||||
find_maven_basedir() {
|
||||
local basedir
|
||||
local wdir
|
||||
(
|
||||
basedir="`pwd`"
|
||||
wdir="`pwd`"
|
||||
while [ "$wdir" != '/' ] ; do
|
||||
|
@ -202,6 +201,7 @@ find_maven_basedir() {
|
|||
wdir="`cd "$wdir/.."; pwd`"
|
||||
done
|
||||
echo "${basedir}"
|
||||
)
|
||||
}
|
||||
|
||||
# concatenates all lines of a file
|
||||
|
|
Loading…
Reference in New Issue