Implement a basic, command driven mail queue management tool for Postfix. This needs to have the basic features similar to qmHandle ([url removed, login to view]), where emails can be easily deleted via the sender address or the subject. Specifically, it must do the following:
1. Display basic mail queue stats.
2. Delete emails based on subject search.
3. Delete emails based on sender address.
4. Display basic help from a command line about the syntax (eg "command --help")
Preference would be to have this implemented in Python, so that functions could be called from both the command line and existing Python scripts. Implementation in other scripted languages will also be considered.
Intended environments to run this on will be CentOS 6 based with standard packages. Please let me know if there's any additional information required.