Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions precommit/src/main/shell/plugins.d/maven.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@

declare -a MAVEN_ARGS

if [[ -z "${MAVEN_HOME:-}" ]]; then
MAVEN=mvn
else
if [[ -e "${BASEDIR}/mvnw" ]]; then
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to add support for windows here

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aw-was-here, sorry I don't know what I can do here, I glanced gradle.sh, which seems to have no Windows-specific logic for gradlew detection

MAVEN=${BASEDIR}/mvnw
elif [[ -n "${MAVEN_HOME:-}" ]]; then
MAVEN=${MAVEN_HOME}/bin/mvn
else
MAVEN=mvn
fi

MAVEN_CUSTOM_REPOS=false
Expand Down Expand Up @@ -78,7 +80,7 @@ function maven_ws_replace
function maven_usage
{
maven_ws_replace
yetus_add_option "--mvn-cmd=<file>" "The 'mvn' command to use (default \${MAVEN_HOME}/bin/mvn, or 'mvn')"
yetus_add_option "--mvn-cmd=<file>" "The 'mvn' command to use (default \${BASEDIR}/mvnw, \${MAVEN_HOME}/bin/mvn, or 'mvn')"
yetus_add_option "--mvn-custom-repos" "Use per-project maven repos"
yetus_add_option "--mvn-custom-repos-dir=<dir>" "Location of repos, default is '${MAVEN_CUSTOM_REPOS_DIR}'"
yetus_add_option "--mvn-deps-order=<bool>" "Disable maven's auto-dependency module ordering (Default: '${MAVEN_DEPENDENCY_ORDER}')"
Expand Down
Loading