You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2022/03/12 01:17:30 UTC
[GitHub] [netbeans] mbien commented on a change in pull request #3767: Fix maven daemon detection on windows platform
mbien commented on a change in pull request #3767:
URL: https://github.com/apache/netbeans/pull/3767#discussion_r825220721
##########
File path: java/maven/src/org/netbeans/modules/maven/execute/cmd/ShellConstructor.java
##########
@@ -44,7 +44,9 @@ public ShellConstructor(@NonNull File mavenHome) {
public List<String> construct() {
// use mvnd if its the home of a daemon
- String ex = Files.exists(Paths.get(mavenHome.getPath(), "bin", "mvnd")) ? "mvnd" : "mvn"; //NOI18N
+ String mavenDaemonSuffixDetection = Utilities.isWindows() ? ".cmd" : "";
+ String ex = Files.exists(Paths.get(mavenHome.getPath(), "bin", "mvnd" + mavenDaemonSuffixDetection)) ? "mvnd" : "mvn"; //NOI18N
Review comment:
i think we should probe here for `mvnd.exe` instead of `.cmd` because `mvnd` is a binary. It is not super important but it would make it symmetrical.
Thanks for fixing this for windows btw. Feel free to force push.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists