getWorkingDir() public method

Returns the work-tree directory. This may be null if repository is bare.
public getWorkingDir ( ) : string
return string path to repository or null if repository is bare
Beispiel #1
0
 public static function registerDeletion(Repository $repository)
 {
     register_shutdown_function(function () use($repository) {
         if ($repository->getWorkingDir()) {
             $dir = $repository->getWorkingDir();
         } else {
             $dir = $repository->getGitDir();
         }
         AbstractTest::deleteDir($dir);
     });
 }