Imported from Bitbucket
reorganize code
lots of things
list: print emails while reading them

heads

tip
browse log

clone

read-only
https://hg.sr.ht/~telesto/mb
read/write
ssh://hg@hg.sr.ht/~telesto/mb

#mailbox - an MH message system

Mailbox is a command line tool and is written in Go. Mailbox is a program in the spirit of nmh - many ideas of nmh found their way into mailbox. Compared to nmh, mailbox has less features, as it aims to be simpler to setup and to use than nmh.
As mailbox is setup/installed by editing and compiling the source code - it takes some programming skills and a go compiler to use mailbox.

#Nonfeatures

#No state

State is the root of all evil. Mailbox has no "current message", no "current folder" or the like.

#No support for .mh_sequence files

No State means: no permanent sequences. IMO it's not worth the effort, as I never use sequences (except marking messages as new, but i can arrange that by using the folder structure). Saying that, mailbox is problably not useful for people who receive a lot of emails.

#No MTA or MRA functionality

Mailbox is a MUA - it does one thing and does it well.

#Features

#Acts as a Filter

Many Mailbox commands can act as a filter by reading from/writing to stdin. Example:

mb raw inbox/4 | mb append draft  # copy msg no. 4 from folder "inbox" to "draft"

#Mime-Support

Reading Mime-Messages is fun again!

#Sequences

Mailbox supports a slightly modified subset of nmh sequences when adressing messages.
There are two fundamental types of sequence tokens (n, m are non zero numbers):

  • "n": msg id == n
  • "n-m": msg id >= n and msg id <= m

Sequence tokens can be or-combined with ",". Sequences can be prefixed with a folder name. If no folder name is given the default folder will be used.

Example: Sequence "inbox/1,6-8,11" will match messages 1,6,7,8,11 in the "inbox" folder.

#Installation

Mailbox is installed by editing and compiling the source code.

First install the package with

	go get bitbucket.org/telesto/mailbox/cmd/mb
	

Proceed with the instructions you find in $GOPATH/dev/src/bitbucket.org/telesto/mailbox/setup_template.go to setup mailbox.

#Command

#ls

List messages in a folder.

Example: List all messages in inbox folder:

	mb ls inbox

#Examples

  • view message 318 in default folder

      mb view 318
    
  • move some messages to the trash folder

      mb mv inbox/299,301-318 trash
    
  • remove all messages in "trash"

      mb rm trash/1-99999
    

#TODO

#Setting up your Email enviroment

fetchmail && "mb append"