This is an automated email from the ASF dual-hosted git repository.
pauls pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/sling-scriptingbundle-maven-plugin.git
The following commit(s) were added to refs/heads/master by this push:
new c3654d8 SLING-9538: normalize the script path to unix
c3654d8 is described below
commit c3654d8b24c5e8ba196731903af021963748e8eb
Author: Karl Pauls <[email protected]>
AuthorDate: Mon Jun 22 15:04:14 2020 +0200
SLING-9538: normalize the script path to unix
---
.../sling/scriptingbundle/maven/plugin/PathOnlyScriptAnalyser.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
a/src/main/java/org/apache/sling/scriptingbundle/maven/plugin/PathOnlyScriptAnalyser.java
b/src/main/java/org/apache/sling/scriptingbundle/maven/plugin/PathOnlyScriptAnalyser.java
index cdb6099..ee2b7d5 100644
---
a/src/main/java/org/apache/sling/scriptingbundle/maven/plugin/PathOnlyScriptAnalyser.java
+++
b/src/main/java/org/apache/sling/scriptingbundle/maven/plugin/PathOnlyScriptAnalyser.java
@@ -68,7 +68,7 @@ public class PathOnlyScriptAnalyser {
String name = fileName.toString();
int dotLastIndex = name.lastIndexOf('.');
if (dotLastIndex > -1 && dotLastIndex != name.length()
- 1) {
- String scriptPath = "/" +
scriptsDirectory.relativize(file).toString();
+ String scriptPath = FilenameUtils.normalize("/" +
scriptsDirectory.relativize(file).toString(), true);
ProvidedScriptCapability providedScriptCapability =
ProvidedScriptCapability.builder(scriptEngineMappings).withPath(scriptPath).build();
Path requires =
parent.resolve(MetadataMojo.REQUIRES_FILE);