From 712f0080dd5e2d928fddcd525f3ce31b44d5589a Mon Sep 17 00:00:00 2001 From: Tomas Babej Date: Wed, 15 Sep 2021 21:33:40 -0400 Subject: [PATCH] Context: Introduce 'default' verbosity token The purpose of this token is to control the display of information messages about taskwarrior choosing a default action of some sort. --- src/Context.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/Context.cpp b/src/Context.cpp index 2c47ba549..bc1885948 100644 --- a/src/Context.cpp +++ b/src/Context.cpp @@ -87,7 +87,7 @@ std::string configurationDefaults = "\n" "# Miscellaneous\n" "# verbose= # Comma-separated list. May contain any subset of:\n" - "# affected,blank,context,edit,filter,footnote,header,label,new-id,new-uuid,override,project,recur,special,sync" + "# affected,blank,context,default,edit,filter,footnote,header,label,new-id,new-uuid,override,project,recur,special,sync\n" "verbose=affected,blank,context,edit,header,footnote,label,new-id,project,special,sync,override,recur\n" "confirmation=1 # Confirmation on delete, big changes\n" "recurrence=1 # Enable recurrence\n" @@ -633,11 +633,13 @@ int Context::initialize (int argc, const char** argv) foundAssumed = true; } - if (foundDefault) - header ("[" + combined + "]"); + if (verbose ("default")) { + if (foundDefault) + header ("[" + combined + "]"); - if (foundAssumed) - header ("No command specified - assuming 'information'."); + if (foundAssumed) + header ("No command specified - assuming 'information'."); + } //////////////////////////////////////////////////////////////////////////// //