Skip to content

Commit 0c66cb0

Browse files
committed
Zero-out the global .gitconfig to fix issue which is only happening on Java 11?
1 parent 04cc972 commit 0c66cb0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib-extra/src/main/java/com/diffplug/spotless/extra/GitAttributesLineEndings.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2016-2023 DiffPlug
2+
* Copyright 2016-2025 DiffPlug
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -193,6 +193,7 @@ static class RuntimeInit {
193193
/////////////////////////////////
194194
// USER AND SYSTEM-WIDE VALUES //
195195
/////////////////////////////////
196+
FS.DETECTED.setGitSystemConfig(new File("no-global-git-config-for-spotless"));
196197
systemConfig = SystemReader.getInstance().openSystemConfig(null, FS.DETECTED);
197198
Errors.log().run(systemConfig::load);
198199
userConfig = SystemReader.getInstance().openUserConfig(systemConfig, FS.DETECTED);

0 commit comments

Comments
 (0)