Skip to content

Commit

Permalink
defaults to 30 backups.
Browse files Browse the repository at this point in the history
  • Loading branch information
birkin committed Dec 19, 2024
1 parent 487b630 commit 6fdf2ed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions self_updater.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,9 @@ def get_uv_path(project_path: Path) -> Path:
return uv_path


def remove_old_backups(backup_dir: Path, keep_recent: int = 7) -> None:
def remove_old_backups(backup_dir: Path, keep_recent: int = 30) -> None:
"""
Removes all files in the backup directory other than the most-recent 7 files.
Removes all files in the backup directory other than the most-recent files.
"""
log.debug('starting remove_old_backups()')
backups: list[Path] = sorted([f for f in backup_dir.iterdir() if f.is_file() and f.suffix == '.txt'], reverse=True)
Expand Down

0 comments on commit 6fdf2ed

Please sign in to comment.