changeset 48171:64b8676f11bb

rhg: fallback if tweakdefaults or statuscopies is enabled with status `rhg status` is experimental right now and does not support all functionalities. While the long term target is to implement them, for now we add a fallback to have all tests pass with `rhg status` enabled. Differential Revision: https://phab.mercurial-scm.org/D10906
author Pulkit Goyal <7895pulkit@gmail.com>
date Thu, 24 Jun 2021 14:23:11 +0530
parents 941fbaab5aff
children 08c8cd2527bc
files rust/rhg/src/commands/status.rs
diffstat 1 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/rust/rhg/src/commands/status.rs	Mon Jul 19 04:13:50 2021 +0530
+++ b/rust/rhg/src/commands/status.rs	Thu Jun 24 14:23:11 2021 +0530
@@ -133,6 +133,18 @@
         ));
     }
 
+    // TODO: lift these limitations
+    if invocation.config.get_bool(b"ui", b"tweakdefaults").ok() == Some(true) {
+        return Err(CommandError::unsupported(
+            "ui.tweakdefaults is not yet supported with rhg status",
+        ));
+    }
+    if invocation.config.get_bool(b"ui", b"statuscopies").ok() == Some(true) {
+        return Err(CommandError::unsupported(
+            "ui.statuscopies is not yet supported with rhg status",
+        ));
+    }
+
     let ui = invocation.ui;
     let args = invocation.subcommand_args;
     let display_states = if args.is_present("all") {