EnglishFrenchSpanish

OnWorks favicon

mailexec - Online in the Cloud

Run mailexec in OnWorks free hosting provider over Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

This is the command mailexec that can be run in the OnWorks free hosting provider using one of our multiple free online workstations such as Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

PROGRAM:

NAME


mailexec - run program on messages in mbox file or maildir

SYNOPSIS


mailexec [-nvFR] mailbox program [arg ...]

DESCRIPTION


mailexec runs a program over every message in mailbox, which must be an mbox-format mail
file or maildir directory. For each message encountered, mailexec executes program with
the specified arguments, supplying the message as standard input. mailexec synthesizes a
"From " line and a "Return-Path:" header field for each message if the message does not
already contain one. (This behavior can be modified by the -F and -R flags, described
below.)

When parsing mbox format files, mailexec unescapes "From " lines. If a line begins with
one or more ">" characters followed by "From ", mailexec deletes one of the ">"
characters. If you do not want this unescaping behavior, see the formail(1) utility,
which has a -s flag that performs a similar function to mailexec.

OPTIONS
-n When processing a maildir, causes mailexec to look exclusively at "new" messages that
have not yet been moved to the cur directory.

-v Turns on verbose mode. If mailbox is a maildir, mailexec prints out the name of each
file it processes inside the maildir. If mailbox is an mbox format file, mailexec
prints the message-id of each message it processes (as long as messages have a
message-id header).

-F Suppresses printing of the initial "From " line at the beginning of each message.

-R Suppresses printing of initial "Return-Path:" lines.

EXAMPLES


To get the same behavior as the Unix from(1) command on a mail directory dir, you can run
either of the following two commands:

mailexec -n dir head -1
mailexec -n dir sed -ne 1p

To convert an mbox-format file mbox into a maildir directory dir, you can run:

mailexec mbox deliver dir/

Conversely, to convert maildir dir into an mbox-format file mbox, run:

mailexec dir deliver mbox

To train the spamassassin filter on a mail folder called spam containing unwanted
messages, run:

mailexec spam sa-learn --spam

Note that this works whether spam is an mbox format file or a maildir directory.

If you have an old mbox file or maildir directory box and wish to "import" the old mail
into your web mail account, say [email protected], you can run:

mailexec -F box sendmail [email protected]

Note again that this works whether box is an mbox format file or a maildir directory.

Use mailexec online using onworks.net services


Free Servers & Workstations

Download Windows & Linux apps

  • 1
    PostInstallerF
    PostInstallerF
    PostInstallerF will install all the
    software that Fedora Linux and others
    doesn't include by default, after
    running Fedora for the first time. Its
    easy for...
    Download PostInstallerF
  • 2
    strace
    strace
    The strace project has been moved to
    https://strace.io. strace is a
    diagnostic, debugging and instructional
    userspace tracer for Linux. It is used
    to monitor a...
    Download strace
  • 3
    gMKVExtractGUI
    gMKVExtractGUI
    A GUI for mkvextract utility (part of
    MKVToolNix) which incorporates most (if
    not all) functionality of mkvextract and
    mkvinfo utilities. Written in C#NET 4.0,...
    Download gMKVExtractGUI
  • 4
    JasperReports Library
    JasperReports Library
    JasperReports Library is the
    world's most popular open source
    business intelligence and reporting
    engine. It is entirely written in Java
    and it is able to ...
    Download JasperReports Library
  • 5
    Frappe Books
    Frappe Books
    Frappe Books is a free and open source
    desktop book-keeping software that's
    simple and well-designed to be used by
    small businesses and freelancers. It'...
    Download Frappe Books
  • 6
    Numerical Python
    Numerical Python
    NEWS: NumPy 1.11.2 is the last release
    that will be made on sourceforge. Wheels
    for Windows, Mac, and Linux as well as
    archived source distributions can be fou...
    Download Numerical Python
  • More »

Linux commands

Ad