Fixing syncing (gitdir discovery / cd) for bare repositories
Signed-off-by: Simon Hausmann <simon@lst.de>
This commit is contained in:
		@ -1200,7 +1200,9 @@ if cmd.needsGit:
 | 
				
			|||||||
        if not isValidGitDir(gitdir):
 | 
					        if not isValidGitDir(gitdir):
 | 
				
			||||||
            gitdir = mypopen("git rev-parse --git-dir").read()[:-1]
 | 
					            gitdir = mypopen("git rev-parse --git-dir").read()[:-1]
 | 
				
			||||||
            if os.path.exists(gitdir):
 | 
					            if os.path.exists(gitdir):
 | 
				
			||||||
                os.chdir(mypopen("git rev-parse --show-cdup").read()[:-1]);
 | 
					                cdup = mypopen("git rev-parse --show-cdup").read()[:-1];
 | 
				
			||||||
 | 
					                if len(cdup) > 0:
 | 
				
			||||||
 | 
					                    os.chdir(cdup);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if not isValidGitDir(gitdir):
 | 
					    if not isValidGitDir(gitdir):
 | 
				
			||||||
        if isValidGitDir(gitdir + "/.git"):
 | 
					        if isValidGitDir(gitdir + "/.git"):
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user