Changes between Version 2 and Version 3 of MuttGuide/Macros


Ignore:
Timestamp:
Oct 27, 2013 6:06:59 PM (4 years ago)
Author:
MichaelRay
Comment:

removed : which doesn't do what I think the original author intended. still looks funny but is mostly readable

Legend:

Unmodified
Added
Removed
Modified
  • MuttGuide/Macros

    v2 v3  
    1919'''Usage: macro menu key sequence [ description ]'''
    2020* What are menus?
    21 : Every different "part" of mutt is called a menu.
     21 Every different "part" of mutt is called a menu.
    2222
    23 : see the functions link above for a complete list. See also /Actions. '''Note that not all functions are available in every menu.'''
     23 see the functions link above for a complete list. See also /Actions. '''Note that not all functions are available in every menu.'''
    2424
    2525* Key
    26 : The key(s) to hit to execute the macro.
     26 The key(s) to hit to execute the macro.
    2727
    2828* Sequence - the actual macro
    29 : Sequence is just a concatenation of functions and commands. Just use the function names in <> brackets.
    30 : You simply write down what you would type in interactively.
    31 : Though you can use the bound keys too, that is '''not recommended'''! Function names are way more portable and readable.
    32 : For example:
    33 :{{{
     29
     30 Sequence is just a concatenation of functions and commands.
     31 Just use the function names in <> brackets.
     32 You simply write down what you would type in interactively.
     33 Though you can use the bound keys too, that is '''not recommended'''! Function names are way more portable and readable.
     34 For example:
     35
    3436macro index,pager <f1> "<shell-escape>less /usr/local/doc/mutt/manual.txt<enter>" "Show Mutt documentation"
    35 }}}
    36 : Nothing special yet. Note that you can define a macro for more than one menu (comma no space). \
     37
     38 Nothing special yet. Note that you can define a macro for more than one menu (comma no space). \
    3739You need to quote sequence if it contains spaces.
    38 :{{{
     40
    3941macro index,pager <f1> "<enter-command>unset wait_key<enter><shell-escape>less /usr/local/doc/mutt/manual.txt<enter><enter-command>set wait_key<enter>" "Show Mutt documentation"
    40 }}}
    41 : So here is an example of a more complex macro. It first unsets $wait_key, then runs less and sets $wait_key again.
    42 : You can see how to use commands.
    43 :{{{
     42
     43 So here is an example of a more complex macro. It first unsets $wait_key, then runs less and sets $wait_key again.
     44 You can see how to use commands.
     45
    4446macro index <tag-prefix-cond><save-message>=foo<enter> "Save tagged messages (if any) to =foo"
    45 }}}
    46 : No space in sequence, no quotes needed. This is an example where you might want a \
     47
     48 No space in sequence, no quotes needed. This is an example where you might want a \
    4749[ask user for input here] function. Unfortunately that does not exist.
    4850