msort

utility for sorting records in complex ways

Install

All systems
curl cmd.cat/msort.sh
Debian Debian
apt-get install msort
Ubuntu
apt-get install msort
image/svg+xml Kali Linux
apt-get install msort
Fedora
dnf install msort
Windows (WSL2)
sudo apt-get update sudo apt-get install msort
Raspbian
apt-get install msort

msort

utility for sorting records in complex ways

msort is a program for sorting files in sophisticated ways. It was originally developed for alphabetizing dictionaries of "exotic" languages, for which it has been extensively used, but is useful for many other purposes. msort differs from typical sort utilities in providing greater flexibility in parsing the input into records and identifying key fields and greater control over the sort order. Its main distinctive features are: o Msort can be used as a command-line program or via a graphical user interface that is helpful not only to those who find a complicated command line difficult to deal with but also to those unfamiliar with the finer points of sorting. o Records need not be single lines of text but may be delimited in a number of ways. o Key fields may be selected by position in the record (counting from the beginning or the end), by character ranges (e.g. the key consists of the fourth through eighth characters), or by matching a regular expression to a tag. o For each key an arbitrary sort order may be specified. Msort also understands locales. o For each key an effectively unlimited number of multigraphs (sequences of characters to be treated as a single unit for purposes of sorting, "collating elements" in Unicode parlance) of effectively unlimited length may be defined. o In addition to the usual lexicographic and numerical comparisons, msort supports hybrid lexicographic-numeric comparison (for things like filenames and section headings, so that, e.g., 2a will precede 10b), random comparison, and ordering by angle, date, time, month name, domain name, email address, ISO8601 date-time, and string length. o Numbers may be in just about any known number system, e.g. Chinese or Devanagari. o For each key a distinct set of characters may be excluded from consideration when sorting in any combination of initial, final, and medial position in the key field. o For each key a distinct set of regular expression substitutions may be defined. These provide the means to make names like McCarthy sort before MacCawley, as if McCarthy were spelled MacCarthy as well as to handle the rare cases in which a single character is treated for purposes of sorting as a sequence, such as German "eszet" sign, which is traditionally sorted as if it were ss. o Lexicographic keys may be reversed, allowing the construction of reverse dictionaries. o Any or all keys may be optional. For optional keys, the user may specify how records missing the key field should compare to records in which the key field is present. o A choice of sorting algorithms with different properties is provided. msort understands UTF-8 Unicode. Unicode may be used anywhere that text is entered: in the text to be sorted, in sort order and exclusion definitions, as a field or record separator, or as a field tag. Full Unicode case-folding is available.

mblaze

UNIX utilities to deal with Maildir

The mblaze message system is a set of Unix utilities to deal with mail kept in Maildir folders. It is a classic command line MUA and has no features for receiving or transferring mail; you are expected to fetch your mail using fdm(1), getmail(1) offlineimap(1), procmail(1), or similar , and send it using dma(8), msmtp(1), sendmail(8), as provided by OpenSMTPD, Postfix, or similar. mblaze expects your mail to reside in Maildir folders. Its design is roughly inspired by MH, the RAND Message Handling System, but it is a complete implementation from scratch. mblaze operates directly on Maildir folders and doesn't use its own caches or databases. There is no setup needed for many uses. mblaze consists of these Unix tools that each do one job: * maddr(1) extract addresses from mail * magrep(1) find mails matching a pattern * mcom(1) compose and send mail * mdeliver(1) deliver messages or import mailboxes * mdirs(1) find Maildir folders * mexport(1) export Maildir folders as mailboxes * mflag(1) change flags (marks) of mail * mflow(1) reflow format=flowed plain text mails * mfwd(1) forward mail * mgenmid(1) generate Message-IDs * mhdr(1) extract mail headers * minc(1) incorporate new mail * mless(1) conveniently read mail in less(1) * mlist(1) list and filter mail messages * mmime(1) create MIME messages * mmkdir(1) create new Maildir * mpick(1) advanced mail filter * mrep(1) reply to mail * mscan(1) generate one-line summaries of mail * msed(1) manipulate mail headers * mseq(1) manipulate mail sequences * mshow(1) render mail and extract attachments * msort(1) sort mail * mthread(1) arrange mail into discussions