Note: Also you can have a plain text file .git at the root of your working tree, containing gitdir: <path> to point at the real directory that has the repository. (source: https://git-scm.com/docs/gitrepository-layout )
I have a project, where this is the case and the GitRepositoryProvider does not work out of the box.
Simple fix:
In Provider/GitRepositoryProvider.php replace line 55
if (is_dir($path . DIRECTORY_SEPARATOR . '.git')) {
with
if (file_exists($path . DIRECTORY_SEPARATOR . '.git')) {
Note: Also you can have a plain text file .git at the root of your working tree, containing
gitdir: <path>
to point at the real directory that has the repository. (source: https://git-scm.com/docs/gitrepository-layout )I have a project, where this is the case and the GitRepositoryProvider does not work out of the box.
Simple fix: In
Provider/GitRepositoryProvider.php
replace line 55if (is_dir($path . DIRECTORY_SEPARATOR . '.git')) {
withif (file_exists($path . DIRECTORY_SEPARATOR . '.git')) {