Hack and / - Mutt Tweaks for System Administrators
Once I had colorized all my e-mail, it was great—I would browse through output and more critical e-mail would jump to my attention. As the number of messages started to grow though, I noticed I would spend a lot of time reading the less-important messages before I found the important ones. My solution was to use the limit feature in mutt. When you are in the index view in mutt (where mutt shows you only the From and the Subject lines), you can tell mutt to limit (the l key by default) the headers you currently can see based on a pattern.
For instance, if I wanted to see only all the headers that said Bob, I could type l and then Bob <Enter>. Then, to see all the headers again, I could type l and then all <Enter> to show all messages. You also can have mutt search within the body of messages, so I created a mutt macro that I bound to the F3 key, so that when I see the full list of headers and press F3, it limits the view only to new messages that contained error or fail in them. I could read those messages first and then change the limit back to all and tab through the rest. Here is the extra line in my .muttrc to create the macro:
macro index <F3> "l~N ~b \"([\^nN][\^oO].error|[Ff][Aa][Ii][Ll])\"<enter>"
I constantly am surprised with how far you can extend mutt. It is definitely one of those programs that gives your time back in gained productivity as you learn more about its configuration options. If you use your e-mail to remember things, or dig through a large stack of server e-mail every day (or even if you don't), mutt is an invaluable e-mail companion that always has new tricks.
Kyle Rankin is a Senior Systems Administrator in the San Francisco Bay Area and the author of a number of books, including Knoppix Hacks and Ubuntu Hacks for O'Reilly Media. He is currently the president of the North Bay Linux Users' Group.
Kyle Rankin is a director of engineering operations in the San Francisco Bay Area, the author of a number of books including DevOps Troubleshooting and The Official Ubuntu Server Book, and is a columnist for Linux Journal.
|Hacking a Safe with Bash||Jul 28, 2015|
|KDE Reveals Plasma Mobile||Jul 28, 2015|
|Huge Package Overhaul for Debian and Ubuntu||Jul 23, 2015|
|diff -u: What's New in Kernel Development||Jul 22, 2015|
|Shashlik - a Tasty New Android Simulator||Jul 21, 2015|
|Embed Linux in Monitoring and Control Systems||Jul 20, 2015|
- KDE Reveals Plasma Mobile
- Hacking a Safe with Bash
- Huge Package Overhaul for Debian and Ubuntu
- diff -u: What's New in Kernel Development
- Shashlik - a Tasty New Android Simulator
- The Controversy Behind Canonical's Intellectual Property Policy
- Home Automation with Raspberry Pi
- Embed Linux in Monitoring and Control Systems
- One Port to Rule Them All!
- General Relativity in Python