You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Austin Stephens (Jira)" <ji...@apache.org> on 2020/09/18 20:45:00 UTC
[jira] [Created] (NETBEANS-4818) New Module system build-impl.xml
doesn't work on windows
Austin Stephens created NETBEANS-4818:
-----------------------------------------
Summary: New Module system build-impl.xml doesn't work on windows
Key: NETBEANS-4818
URL: https://issues.apache.org/jira/browse/NETBEANS-4818
Project: NetBeans
Issue Type: Bug
Components: java - Compiler
Affects Versions: 12.2
Reporter: Austin Stephens
To fix the issue of Nashorn being removed, someone is having ant compile scripts. They apparently did this without using a debugger since they are comparing strings with "==" and "!=", which is why it doesn't work on Windows. I have fixed it but am too lazy to check it in. Here is the new fixed method as it appears in build-impl.xml:
{noformat}
private String toRegexp2(String spec, String filepattern, String separator) {
List<String> prefixes = new ArrayList<>();
List<String> suffixes = new ArrayList<>();
pathVariants(spec).forEach(item -> {
suffixes.add(item);
});
String tail = "";
String separatorString = separator;
if ("\\".equals(separatorString)) {
separatorString = "\\\\";
}
if (filepattern != null && !filepattern.equals(tail)) {
tail = separatorString + filepattern;
}
return "([^" + separatorString +"]+)\\Q" + separator + "\\E(" + suffixes.stream().collect(Collectors.joining("|")) + ")" + tail;
}{noformat}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists