]> granicus.if.org Git - neomutt/commitdiff
Add `named-mailboxes` command
authorAustin Ray <austin@austinray.io>
Thu, 11 Oct 2018 22:54:36 +0000 (18:54 -0400)
committerRichard Russon <rich@flatcap.org>
Sat, 13 Oct 2018 22:54:48 +0000 (23:54 +0100)
No additional work is necessary since this command reuses the same code
as `mailboxes` and `virtual-mailboxes`. This was surprisingly simple.

doc/manual.xml.head
init.h

index 6c6ef5651ff69a19982356fb2a2ba54f9abfa0bc..5eef4a82079999325738ab37c9a526fa96c69976 100644 (file)
@@ -5256,6 +5256,21 @@ unignore posted-to:
         <arg choice="opt" rep="repeat">
           <replaceable class="parameter">mailbox</replaceable>
         </arg>
+        <command>named-mailboxes</command>
+        <arg choice="plain">
+          <replaceable class="parameter">description</replaceable>
+          <arg choice="plain">
+            <replaceable class="parameter">mailbox</replaceable>
+          </arg>
+        </arg>
+        <group choice="req" rep="repeat">
+          <arg choice="plain">
+            <replaceable class="parameter">description</replaceable>
+            <arg choice="plain">
+              <replaceable class="parameter">mailbox</replaceable>
+            </arg>
+          </arg>
+        </group>
         <command>unmailboxes</command>
         <group choice="req">
           <arg choice="plain">
@@ -5288,8 +5303,10 @@ unignore posted-to:
       </para>
       <para>
         The <quote>unmailboxes</quote> command is used to remove a token from
-        the list of folders which receive mail. Use
-        <quote>unmailboxes&#160;*</quote> to remove all tokens.
+        the list of folders which receive mail. <quote>unmailboxes</quote> can
+        be used on the mailbox path, <quote>$folder</quote>-abbreviated path,
+        or description. Use <quote>unmailboxes&#160;*</quote> to remove all
+        tokens.
       </para>
       <note>
         <para>
@@ -17794,6 +17811,20 @@ neomutt mailto:some@one.org?subject=test&amp;cc=other@one.org
             <arg choice="opt" rep="repeat">
               <replaceable class="parameter">mailbox</replaceable>
             </arg>
+            <command>
+              <link linkend="mailboxes">named-mailboxes</link>
+            </command>
+            <arg choice="plain">
+              <replaceable class="parameter">description</replaceable>
+            </arg>
+            <arg choice="plain">
+              <replaceable class="parameter">mailbox</replaceable>
+            </arg>
+            <group choice="opt" rep="repeat">
+              <arg choice="plain">
+                <replaceable class="parameter">description mailbox</replaceable>
+              </arg>
+            </group>
             <command>
               <link linkend="mailboxes">unmailboxes</link>
             </command>
diff --git a/init.h b/init.h
index 40edd4bf07225226a2c2a9ef5c0e6b2d89a9330d..39fe61b4ae35076d88935b047ab1f82e3faf7a2b 100644 (file)
--- a/init.h
+++ b/init.h
@@ -4685,6 +4685,7 @@ const struct Command Commands[] = {
   { "mime_lookup",         parse_stailq,           UL &MimeLookupList },
   { "mono",                mutt_parse_mono,        0 },
   { "my_hdr",              parse_my_hdr,           0 },
+  { "named-mailboxes",     mutt_parse_mailboxes,   MUTT_NAMED },
   { "nospam",              parse_spam_list,        MUTT_NOSPAM },
 #ifdef USE_COMPRESSED
   { "open-hook",           mutt_parse_hook,        MUTT_OPEN_HOOK },