Fix fork repo and macaron API broken

This commit is contained in:
Unknwon
2014-10-24 18:43:17 -04:00
parent baae94b9cf
commit f1d8746264
8 changed files with 171 additions and 178 deletions

View File

@ -1424,7 +1424,7 @@ func ForkRepository(u *User, oldRepo *Repository) (*Repository, error) {
repoPath := RepoPath(u.Name, repo.Name)
_, stderr, err := process.ExecTimeout(10*time.Minute,
fmt.Sprintf("ForkRepository(git clone): %s/%s", u.Name, repo.Name),
"git", "clone", oldRepoPath, repoPath)
"git", "clone", "--bare", oldRepoPath, repoPath)
if err != nil {
return nil, errors.New("ForkRepository(git clone): " + stderr)
}