mvnw
Expected an indentation at 8 instead of at 6. Open
Open
if [ ! -x "$JAVACMD" ] || [ ! -x "$JAVACCMD" ]; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# Trims trailing and leading whitespace, carriage returns, tabs, and linefeeds.
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
[ -z "${JAVA_HOME-}" ] || JAVA_HOME="$(cygpath --unix "$JAVA_HOME")"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
JAVACMD="$JAVA_HOME/bin/java"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'set' +e
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
str="${1:-}" h=0
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
case "${key-}" in
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
JAVACCMD="$JAVA_HOME/jre/sh/javac"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'unset' -f command 2>/dev/null
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
clean() { rm -rf -- "$TMP_DOWNLOAD_DIR"; }
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose "Found wget ... using wget"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
wget ${__MVNW_QUIET_WGET:+"$__MVNW_QUIET_WGET"} "$distributionUrl" -O "$TMP_DOWNLOAD_DIR/$distributionUrlName" || die "wget: Failed to fetch $distributionUrl"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose "Falling back to use Java to download"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
targetZip="$TMP_DOWNLOAD_DIR/$distributionUrlName"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
javaSource="$TMP_DOWNLOAD_DIR/Downloader.java"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
exit 1
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# Needed for removing poorly interpreted newline sequences when running in more
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
printf "%s" "${1}" | tr -d '[:space:]'
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
distributionUrl) distributionUrl=$(trim "${value-}") ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
unset MVNW_VERBOSE MVNW_USERNAME MVNW_PASSWORD MVNW_REPOURL || :
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'command' -v javac
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
printf %s\\n "$1" >&2
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
distributionSha256Sum) distributionSha256Sum=$(trim "${value-}") ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
:Darwin*x86_64) distributionPlatform=darwin-amd64 ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
distributionUrl="${distributionUrl%-bin.*}-$distributionPlatform.zip"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
curl ${__MVNW_QUIET_CURL:+"$__MVNW_QUIET_CURL"} -f -L -o "$TMP_DOWNLOAD_DIR/$distributionUrlName" "$distributionUrl" || die "curl: Failed to fetch $distributionUrl"
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
return new java.net.PasswordAuthentication( System.getenv( "MVNW_USERNAME" ), System.getenv( "MVNW_PASSWORD" ).toCharArray() );
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'unset' -f command 2>/dev/null
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
echo "The java/javac command does not exist in PATH nor is JAVA_HOME set, so mvnw cannot run." >&2
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
printf %x\\n $h
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# exotic environments such as mingw bash on Windows.
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
protected java.net.PasswordAuthentication getPasswordAuthentication()
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# MWRAPPER-139:
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
while [ -n "$str" ]; do
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
:Darwin*arm64) distributionPlatform=darwin-aarch64 ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
MVN_CMD=mvnd.sh _MVNW_REPO_PATTERN=/maven/mvnd/
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
*AMD64:CYGWIN* | *AMD64:MINGW*) distributionPlatform=windows-amd64 ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
exec "$MAVEN_HOME/bin/$MVN_CMD" "$@" || die "cannot exec $MAVEN_HOME/bin/$MVN_CMD"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# For Cygwin and MinGW, ensure paths are in Unix format before anything is touched
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
# IBM's JDK on AIX uses strange locations for the executables
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
JAVACMD="$JAVA_HOME/jre/sh/java"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
cat >"$javaSource" <<-END
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
native_path() { cygpath --path --windows "$1"; }
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'command' -v java
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
case "${PROCESSOR_ARCHITECTURE-}${PROCESSOR_ARCHITEW6432-}:$(uname -a)" in
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
:Linux*x86_64*) distributionPlatform=linux-amd64 ;;
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose "found existing MAVEN_HOME at $MAVEN_HOME"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
if [ -n "${JAVA_HOME-}" ]; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
return 1
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
trap clean HUP INT TERM EXIT
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
public class Downloader extends java.net.Authenticator
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
java.nio.file.Files.copy( java.net.URI.create( args[0] ).toURL().openStream(), java.nio.file.Paths.get( args[1] ).toAbsolutePath().normalize() );
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose "Found curl ... using curl"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
'set' +e
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
die "cannot create temp dir"
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
setDefault( new Downloader() );
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
JAVACCMD="$JAVA_HOME/bin/javac"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
exec_maven "$@"
- Create a ticketCreate a ticket
- Exclude checks
Unexpected tabs found. Open
Open
public static void main( String[] args ) throws Exception
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose " - Running Downloader.java ..."
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
distributionSha256Result=false
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
"$(native_path "$JAVACMD")" -cp "$(native_path "$TMP_DOWNLOAD_DIR")" Downloader "$distributionUrl" "$(native_path "$targetZip")"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
"$(native_path "$JAVACCMD")" "$(native_path "$javaSource")" || die "Failed to compile Downloader.java"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
elif command -v sha256sum >/dev/null; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
unzip ${__MVNW_QUIET_UNZIP:+"$__MVNW_QUIET_UNZIP"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -d "$TMP_DOWNLOAD_DIR" || die "failed to unzip"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
if [ "$MVN_CMD" = mvnd.sh ]; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
if [ $distributionSha256Result = false ]; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
distributionSha256Result=true
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 8 instead of at 6. Open
Open
distributionSha256Result=true
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
elif command -v shasum >/dev/null; then
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
tar xzf${__MVNW_QUIET_TAR:+"$__MVNW_QUIET_TAR"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -C "$TMP_DOWNLOAD_DIR" || die "failed to untar"
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
# For Cygwin/MinGW, switch paths to Windows format before running javac and java
- Create a ticketCreate a ticket
- Exclude checks
Expected an indentation at 4 instead of at 2. Open
Open
verbose " - Compiling Downloader.java ..."
- Create a ticketCreate a ticket
- Exclude checks