|
|
@ -129,6 +129,8 @@ func NewRepoContext() {
|
|
|
|
log.Fatal(4, "Fail to execute 'git config --global core.quotepath false': %s", stderr)
|
|
|
|
log.Fatal(4, "Fail to execute 'git config --global core.quotepath false': %s", stderr)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Clean up temporary data.
|
|
|
|
|
|
|
|
os.RemoveAll(filepath.Join(setting.AppDataPath, "tmp"))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Repository represents a git repository.
|
|
|
|
// Repository represents a git repository.
|
|
|
@ -1301,7 +1303,8 @@ func DeleteRepository(uid, repoID int64) error {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
wikiPath := repo.WikiPath()
|
|
|
|
wikiPaths := []string{repo.WikiPath(), repo.LocalWikiPath()}
|
|
|
|
|
|
|
|
for _, wikiPath := range wikiPaths {
|
|
|
|
if err = os.RemoveAll(wikiPath); err != nil {
|
|
|
|
if err = os.RemoveAll(wikiPath); err != nil {
|
|
|
|
desc := fmt.Sprintf("delete repository wiki [%s]: %v", wikiPath, err)
|
|
|
|
desc := fmt.Sprintf("delete repository wiki [%s]: %v", wikiPath, err)
|
|
|
|
log.Warn(desc)
|
|
|
|
log.Warn(desc)
|
|
|
@ -1309,6 +1312,7 @@ func DeleteRepository(uid, repoID int64) error {
|
|
|
|
log.Error(4, "CreateRepositoryNotice: %v", err)
|
|
|
|
log.Error(4, "CreateRepositoryNotice: %v", err)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Remove attachment files.
|
|
|
|
// Remove attachment files.
|
|
|
|
for i := range attachmentPaths {
|
|
|
|
for i := range attachmentPaths {
|
|
|
|