sane-tag-media: remove unused "confirm" function

This commit is contained in:
2024-08-03 07:19:53 +00:00
parent 4761690b6d
commit 0dba9987c5

View File

@@ -915,7 +915,6 @@ class Tagger:
self.show_tagdif(file_.path_, old_tags, new_tags)
if self.confirm():
if self.guard_dry_run("writing tags"):
file_.write_tags(new_tags)
@@ -932,7 +931,6 @@ class Tagger:
self.show_pathdif(file_.path_, new_path)
if self.confirm():
if self.guard_dry_run(f"moving file"):
assert not os.path.exists(new_path), f"{file_.path_} -> {new_path} would clobber destination!"
# os.renames creates the necessary parents, and then prunes leaf directories
@@ -952,10 +950,6 @@ class Tagger:
logger.debug(f"skipping unchanged {path_}")
logger.debug(f" {tags}")
def confirm(self) -> bool:
# TODO: actually prompt
return True
def guard_dry_run(self, msg: str) -> bool:
if self.dry_run:
print(f"dry run: not {msg}")