We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents c01f4f0 + 3dc0b1a commit 3e122bcCopy full SHA for 3e122bc
1 file changed
src/ComposerPlugin.php
@@ -233,6 +233,12 @@ private function detectGitDir(): void
233
$this->gitDirectory = $possibleGitDir;
234
return;
235
}
236
+
237
+ // if we checked the root directory already, break to prevent endless loop
238
+ if ($path === dirname($path)) {
239
+ break;
240
+ }
241
242
$path = \dirname($path);
243
244
throw new RuntimeException($this->pluginErrorMessage('git directory not found'));
0 commit comments