- commit
- c12ec4abecad7605a4e9eb70cf17e7092f960b5c
- parent
- f07948f771350767fbe0df0fafac25b856814363
- Author
- Tobias Bengfort <tobias.bengfort@posteo.de>
- Date
- 2023-11-03 14:14
rm old files on render
Diffstat
M | gitolite/stagit.py | 4 | +++- |
1 files changed, 3 insertions, 1 deletions
diff --git a/gitolite/stagit.py b/gitolite/stagit.py
@@ -118,7 +118,9 @@ def render_index(): 118 118 def render_repo(repo): 119 119 print('Generating HTML for %s…' % repo) 120 120 target_dir = os.path.join(WWW_DIR, repo)121 -1 os.makedirs(target_dir, exist_ok=True)-1 121 if os.path.isdir(target_dir): -1 122 shutil.rmtree(target_dir) -1 123 os.makedirs(target_dir) 122 124 subprocess.check_call(['stagit', get_repo_dir(repo)], cwd=target_dir) 123 125 124 126