mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-08-03 00:45:22 +02:00
Refactor repository check and sync functions (#9854)
Move more general repository functions out of models/repo.go
This commit is contained in:
parent
27c6b8fc07
commit
d92781bf94
12 changed files with 313 additions and 210 deletions
|
@ -164,7 +164,7 @@ func checkInitRepository(repoPath string) (err error) {
|
|||
// Init git bare new repository.
|
||||
if err = git.InitRepository(repoPath, true); err != nil {
|
||||
return fmt.Errorf("git.InitRepository: %v", err)
|
||||
} else if err = models.CreateDelegateHooks(repoPath); err != nil {
|
||||
} else if err = createDelegateHooks(repoPath); err != nil {
|
||||
return fmt.Errorf("createDelegateHooks: %v", err)
|
||||
}
|
||||
return nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue