Skip to content

Commit 6619a76

Browse files
committed
Fix windows.
1 parent 7bf6b1b commit 6619a76

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin-gradle/src/main/java/com/diffplug/gradle/spotless/FormatExtension.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ private static void relativizeIfSubdir(List<String> relativePaths, File root, Fi
340340
return null;
341341
} else {
342342
String relativized = destPath.substring(rootPath.length());
343-
return relativized.startsWith("/") ? relativized.substring(1) : relativized;
343+
return relativized.startsWith("/") || relativized.startsWith("\\") ? relativized.substring(1) : relativized;
344344
}
345345
}
346346

0 commit comments

Comments
 (0)