changeset 50988 | cf47b83d8ad0 |
parent 50936 | 6408777c8fa4 |
child 51863 | f4733654f144 |
--- a/mercurial/transaction.py Wed Jan 25 15:33:39 2023 +0100 +++ b/mercurial/transaction.py Wed Sep 13 12:25:51 2023 +0200 @@ -59,6 +59,11 @@ ] +def has_abandoned_transaction(repo): + """Return True if the repo has an abandoned transaction""" + return os.path.exists(repo.sjoin(b"journal")) + + def cleanup_undo_files(report, vfsmap, undo_prefix=b'undo'): """remove "undo" files used by the rollback logic