diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 030ac55..515045f 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -56,4 +56,5 @@ jobs:
run: mvn -B clean install -Dno-format
- name: Build with Maven (Native)
- run: mvn -B install -Dnative -Dquarkus.native.container-build -Dnative.surefire.skip
\ No newline at end of file
+ run: mvn -B install -Dnative -Dquarkus.native.container-build -Dnative.surefire.skip
+ if: ${{ !startsWith(matrix.os, 'windows') }}
\ No newline at end of file
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/ProjectResourcesScanner.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/ProjectResourcesScanner.java
index 64ca1f5..2d6bd93 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/ProjectResourcesScanner.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/ProjectResourcesScanner.java
@@ -1,6 +1,7 @@
package io.quarkiverse.web.bundler.deployment;
-import java.io.File;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.toUnixPath;
+
import java.io.IOException;
import java.io.UncheckedIOException;
import java.nio.charset.Charset;
@@ -88,7 +89,7 @@ private void scanProject(Scanner scanner,
// a wrong directory bundleName on case-insensitive file systems
try {
final Path dirPath = rootDir.resolve(scanner.dir());
- if (Files.isDirectory(dirPath) && dirPath.toString().endsWith(scanner.dir())) {
+ if (Files.isDirectory(dirPath) && toUnixPath(dirPath.toString()).endsWith(scanner.dir())) {
scan(rootDir, dirPath, scanner.pathMatcher(), scanner.charset, webAssetConsumer, true);
break;
}
@@ -118,14 +119,14 @@ private void scan(
&& filePath.getRoot() != null) {
filePath = filePath.getRoot().relativize(filePath);
}
- final Path relativePath = directory.relativize(filePath);
+ final Path relativePath = toScan.relativize(filePath);
final PathMatcher assetsPathMatcher = relativePath.getFileSystem()
.getPathMatcher(pathMatcher);
final boolean isAsset = assetsPathMatcher.matches(relativePath);
if (isAsset) {
String assetPath = root.relativize(filePath).normalize().toString();
- if (File.separatorChar != '/') {
- assetPath = assetPath.replace(File.separatorChar, '/');
+ if (assetPath.contains("\\")) {
+ assetPath = toUnixPath(assetPath);
}
if (!assetPath.isEmpty()) {
webAssetConsumer.accept(toWebAsset(assetPath,
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebAssetsScannerProcessor.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebAssetsScannerProcessor.java
index 9bed5de..7d50848 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebAssetsScannerProcessor.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebAssetsScannerProcessor.java
@@ -1,6 +1,6 @@
package io.quarkiverse.web.bundler.deployment;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.addTrailingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.addTrailingSlash;
import java.io.IOException;
import java.nio.file.Files;
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerConfig.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerConfig.java
index 173009e..9edaa55 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerConfig.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerConfig.java
@@ -1,7 +1,7 @@
package io.quarkiverse.web.bundler.deployment;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.addTrailingSlash;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.removeLeadingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.addTrailingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.removeLeadingSlash;
import static java.util.function.Predicate.not;
import java.nio.charset.Charset;
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerProcessor.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerProcessor.java
index e6a28db..fc5f8e0 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerProcessor.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/WebBundlerProcessor.java
@@ -2,8 +2,8 @@
import static io.quarkiverse.web.bundler.deployment.ProjectResourcesScanner.readTemplateContent;
import static io.quarkiverse.web.bundler.deployment.items.BundleWebAsset.BundleType.MANUAL;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.prefixWithSlash;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.surroundWithSlashes;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.prefixWithSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.surroundWithSlashes;
import static io.quarkiverse.web.bundler.runtime.qute.WebBundlerQuteContextRecorder.WEB_BUNDLER_ID_PREFIX;
import static io.quarkus.deployment.annotations.ExecutionTime.STATIC_INIT;
import static java.util.Map.entry;
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/staticresources/GeneratedStaticResourcesProcessor.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/staticresources/GeneratedStaticResourcesProcessor.java
index 3553bae..e9646f1 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/staticresources/GeneratedStaticResourcesProcessor.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/staticresources/GeneratedStaticResourcesProcessor.java
@@ -13,6 +13,8 @@
import java.util.List;
import java.util.Set;
+import org.jboss.logging.Logger;
+
import io.quarkus.bootstrap.workspace.ArtifactSources;
import io.quarkus.bootstrap.workspace.SourceDir;
import io.quarkus.deployment.annotations.BuildProducer;
@@ -26,6 +28,7 @@
import io.quarkus.vertx.http.deployment.spi.AdditionalStaticResourceBuildItem;
public class GeneratedStaticResourcesProcessor {
+ private static final Logger LOGGER = Logger.getLogger(GeneratedStaticResourcesProcessor.class);
@BuildStep
public void processStaticFiles(
@@ -106,6 +109,11 @@ public static File getBuildDirectory(CurateOutcomeBuildItem curateOutcomeBuildIt
// pick the first resources output dir
Path resourcesOutputDir = srcDirs.iterator().next().getOutputDir();
buildDir = resourcesOutputDir.toFile();
+ if (srcDirs.size() > 1) {
+ LOGGER.warnf("Multiple resources directories found, using the first one in the list: %s",
+ resourcesOutputDir);
+ }
+
}
}
if (buildDir == null) {
diff --git a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPaths.java b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/PathUtils.java
similarity index 83%
rename from deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPaths.java
rename to deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/PathUtils.java
index 33ada57..af0c521 100644
--- a/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPaths.java
+++ b/deployment/src/main/java/io/quarkiverse/web/bundler/deployment/util/PathUtils.java
@@ -1,6 +1,10 @@
package io.quarkiverse.web.bundler.deployment.util;
-public final class ConfiguredPaths {
+public final class PathUtils {
+
+ public static String toUnixPath(String path) {
+ return path.replaceAll("\\\\", "/");
+ }
public static String prefixWithSlash(String path) {
return path.startsWith("/") ? path : "/" + path;
diff --git a/deployment/src/test/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPathsTest.java b/deployment/src/test/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPathsTest.java
index 190d539..0cc24f9 100644
--- a/deployment/src/test/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPathsTest.java
+++ b/deployment/src/test/java/io/quarkiverse/web/bundler/deployment/util/ConfiguredPathsTest.java
@@ -1,9 +1,9 @@
package io.quarkiverse.web.bundler.deployment.util;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.addTrailingSlash;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.prefixWithSlash;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.removeLeadingSlash;
-import static io.quarkiverse.web.bundler.deployment.util.ConfiguredPaths.removeTrailingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.addTrailingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.prefixWithSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.removeLeadingSlash;
+import static io.quarkiverse.web.bundler.deployment.util.PathUtils.removeTrailingSlash;
import static org.junit.jupiter.api.Assertions.assertEquals;
import org.junit.jupiter.api.Test;
diff --git a/pom.xml b/pom.xml
index 927a89b..918fbbe 100644
--- a/pom.xml
+++ b/pom.xml
@@ -30,7 +30,7 @@
UTF-8
3.1.3.Final
- 1.0.4
+ 1.0.5
4.1.1
2.4.8