diff options
author | Unknwon <u@gogs.io> | 2015-08-08 00:41:09 +0800 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2015-08-08 00:41:09 +0800 |
commit | 45adb9b7a38cca896bf8fb3f27ccb29fc244b395 (patch) | |
tree | 734f87b898084e7de820f5c8c791ab4093f2189a /models/repo.go | |
parent | 492d2dc112178f1917cd49a71d5a8ac3d7c2e384 (diff) | |
download | gitea-45adb9b7a38cca896bf8fb3f27ccb29fc244b395.tar.gz gitea-45adb9b7a38cca896bf8fb3f27ccb29fc244b395.zip |
fix #1331
Diffstat (limited to 'models/repo.go')
-rw-r--r-- | models/repo.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/models/repo.go b/models/repo.go index c61bef2f7e..73807a2f65 100644 --- a/models/repo.go +++ b/models/repo.go @@ -456,6 +456,7 @@ func initRepository(e Engine, repoPath string, u *User, repo *Repository, initRe // Clone to temprory path and do the init commit. tmpDir := filepath.Join(os.TempDir(), com.ToStr(time.Now().Nanosecond())) os.MkdirAll(tmpDir, os.ModePerm) + defer os.RemoveAll(tmpDir) _, stderr, err = process.Exec( fmt.Sprintf("initRepository(git clone): %s", repoPath), |