mblaze
Set of small Unix utilities for reading, searching, threading and composing mail stored in Maildir folders.
mblaze is a collection of commands such as mlist, mscan, mshow, mthread, mpick and mcom that are combined in shell pipes. It works directly on Maildir folders with no database or cache, and can import and export mbox files; its design is inspired by MH but written from scratch. It has no networking of its own: a sync tool such as mbsync fetches mail and a sendmail-compatible program such as msmtp sends it. It suits users who want to script mail handling with standard Unix tools.
- Type
- Email client
- Interface
- Command-line tools and prompts
- Systems
- Runs on Linux, macOS and BSD, on Windows through WSL. Not available for Android.
- Language
- C
- License
- CC0 1.0 and MIT
- Latest version
1.4- Background
- Inspired by MH; written from scratch
- Maintained
- Yes
- Website
- github.com
- Source
- github.com/leahneukirchen/mblaze
- Documentation
- github.com
Install
| System | Support | Install |
|---|---|---|
| Linux | Native | apt sudo apt install mblazexbps sudo xbps-install mblazeAUR yay -S mblaze |
| macOS | Native | Nix nix profile install nixpkgs#mblazeNo Homebrew formula; available through Nix or by building from source with GNU make. |
| Windows | Through WSL | WSL sudo apt install mblazeNo native build; upstream lists Cygwin as tested, and the Debian package works in WSL. |
| BSD | Native | FreeBSD pkg pkg install mblazeOpenBSD pkg_add mblaze |
| Android | Not supported | No Termux package. |
Protocols and features
| Protocol | mblaze |
|---|---|
| IMAP | Through a separate tool |
| POP3 | Through a separate tool |
| SMTP | Through a separate tool |
| JMAP | No |
| Maildir | Yes |
| mbox | No |
| notmuch | No |
| Feature | mblaze |
|---|---|
| OpenPGP | via contrib scripts |
| S/MIME | No |
| OAuth2 sign-in | No |
| Threads | Yes |
| Search | mpick and magrep filter messages by headers, flags and content |
| HTML mail | via a filter command in ~/.mblaze/filter used by mshow |
| Mouse | No |
| Multiple accounts | via separate Maildirs and profile settings |
| Offline use | full; works only on local Maildir |
| Calendar | No |
| Contacts | No |
| Vim-style keys | No |
| Configuration | ~/.mblaze/profile (header-style key: value lines) |
Pros and cons
Pros
- Each command does one job, so mail handling is easy to combine in pipes and scripts.
- Works directly on Maildir with no index or database to maintain.
- Small C programs with no external library dependencies.
Cons
- No built-in IMAP, POP3 or SMTP; needs mbsync and msmtp or similar tools.
- Command-line only, with no full-screen interface.
- OpenPGP and S/MIME handling relies on unsupported contrib scripts.
Use mblaze with Forward Email
A working setup for a Forward Email mailbox. Replace you@example.com with your alias and the password command with your own. The same settings work with any provider once the server names change.
# 1) ~/.mbsyncrc: sync to ~/Mail/forwardemail (isync 1.5+ syntax)
IMAPAccount forwardemail
Host imap.forwardemail.net
Port 993
User you@example.com
PassCmd "pass show email/forwardemail"
TLSType IMAPS
IMAPStore forwardemail-remote
Account forwardemail
MaildirStore forwardemail-local
SubFolders Verbatim
Path ~/Mail/forwardemail/
Inbox ~/Mail/forwardemail/INBOX
Channel forwardemail
Far :forwardemail-remote:
Near :forwardemail-local:
Patterns *
Create Both
SyncState *
# 2) ~/.config/msmtp/config (chmod 600)
account forwardemail
host smtp.forwardemail.net
port 465
tls on
tls_starttls off
auth on
user you@example.com
passwordeval "pass show email/forwardemail"
from you@example.com
account default : forwardemail
# 3) ~/.mblaze/profile
Local-Mailbox: Your Name <you@example.com>
Maildir: ~/Mail/forwardemail
Outbox: ~/Mail/forwardemail/Sent Mail
Sendmail: msmtp
# Usage: mbsync forwardemail; mlist ~/Mail/forwardemail/INBOX | mthread | mscan| Protocol | Server | Port | Security |
|---|---|---|---|
| IMAP | imap.forwardemail.net | 993 | SSL/TLS |
| POP3 | pop3.forwardemail.net | 995 | SSL/TLS |
| SMTP | smtp.forwardemail.net | 465 | SSL/TLS |
| SMTP | smtp.forwardemail.net | 587 | STARTTLS |
Username: your full alias address, such as you@example.com. Password: the one shown by Generate Password next to the alias in your Forward Email account. Folders: INBOX, Drafts, Sent Mail, Trash, Spam and Archive.
Prefer no config at all? Forward Email's terminal app signs in with your account and has mail, calendar and contacts in one program.
Compare mblaze
Questions
Does mblaze work on Windows?
Not natively. It runs in Windows Subsystem for Linux (WSL). No native build; upstream lists Cygwin as tested, and the Debian package works in WSL.
Does mblaze support IMAP?
Through a separate tool. mblaze reads local mail, so a sync program such as isync copies it from the IMAP server.
How do I use mblaze with Forward Email?
Use the config in the Forward Email section on this page, saved as ~/.mbsyncrc, ~/.config/msmtp/config and ~/.mblaze/profile, and replace the address and password with your own.
Sources
- github.com/leahneukirchen/mblaze
- github.com/leahneukirchen/mblaze/blob/master/README
- github.com/leahneukirchen/mblaze/blob/master/COPYING
- github.com/leahneukirchen/mblaze/blob/master/INSTALL.md
- github.com/leahneukirchen/mblaze/blob/master/man/mblaze-profile.5
- github.com/leahneukirchen/mblaze/tree/master/contrib
- leahneukirchen.org/releases/
- packages.debian.org/trixie/mblaze
- github.com/void-linux/void-packages/blob/master/srcpkgs/mblaze/template
- aur.archlinux.org/packages/mblaze
- github.com/NixOS/nixpkgs/blob/master/pkgs/by-name/mb/mblaze/package.nix
- github.com/freebsd/freebsd-ports/blob/main/mail/mblaze/Makefile
- github.com/openbsd/ports/blob/master/mail/mblaze/Makefile
- formulae.brew.sh/api/formula.json
- sourceforge.net/p/isync/isync/ci/master/tree/src/mbsync.1.in
- git.marlam.de/gitweb/?p=msmtp.git;a=blob;f=doc/msmtp.texi