# HG changeset patch # User Franz Glasner # Date 1556706439 -7200 # Node ID 3cf4c3d56eca64855a51d296c299ecf7cae7f792 # Parent d291983b419143d1fcb0548d4e106d5e8d10776e Check for a clean working directory only when no --dest is given when restoring timestamps diff -r d291983b4191 -r 3cf4c3d56eca extensions/timestamps.py --- a/extensions/timestamps.py Wed Mar 06 09:36:09 2019 +0100 +++ b/extensions/timestamps.py Wed May 01 12:27:19 2019 +0200 @@ -493,12 +493,12 @@ repo = ctx.repo() if not repo.local(): raise error.Abort(_("repository is not local")) - cmdutil.checkunfinished(repo) - cmdutil.bailifchanged(repo) tsconfmatch = _gen_matcher_from_tsconfig(ctx, tsconfig=tsconfig, ui=ui) if tsconfmatch is None: raise error.Abort(_("timestamps are not activated/configured")) if destdir is None: + cmdutil.checkunfinished(repo) + cmdutil.bailifchanged(repo) ts = _Timestamps.from_filename(ui, name=repo.wjoin(TIMESTAMPS_DATABASE)) else: ts = _Timestamps.from_ctx(ctx, ui)