'\" t .ftr C B .TH "MU MOVE" "1" .SH "NAME" .PP mu-move - move a message file or change its flags .SH "SYNOPSIS" .PP \fBmu [common-options] move [options] [--flags=] []\fP .SH "DESCRIPTION" .PP \fBmu move\fP is the command for moving messages in a Maildir or changing their flags. .PP For any change, both the message file in the file system as well as its representation in the database are updated accordingly. .PP The source message file and target-maildir must reside under the root-maildir for mu's database (see \fBmu info store\fP). .SH "MOVE OPTIONS" .SS "--flags=" .PP specify the new message flags. See \fBFLAGS\fP for details. .SS "--change-name" .PP change the basename of the message file when moving; this can be useful when using some external tools such as \fBmbsync(1)\fP which otherwise get confused .SS "--update-dups" .PP update the flags of duplicate messages too, where "duplicate messages" are defined as all message that share the same message-id. Note that the Draft/Flagged/Trashed flags are deliberately \fInot\fP changed if you change those on the source message. .SS "--dry-run,-n" .PP print the target filename(s), but don't change anything. .PP Note that with the \fC\-\-change\-name\fP, the target name is not constant, so you cannot use a dry-run to predict the exact name when doing a `real' run. .SH "COMMON OPTIONS" .SS "-d, --debug" .PP makes mu generate extra debug information, useful for debugging the program itself. By default, debug information goes to the log file, ~/.cache/mu/mu.log. It can safely be deleted when mu is not running. When running with --debug option, the log file can grow rather quickly. See the note on logging below. .SS "-q, --quiet" .PP causes mu not to output informational messages and progress information to standard output, but only to the log file. Error messages will still be sent to standard error. Note that mu index is much faster with --quiet, so it is recommended you use this option when using mu from scripts etc. .SS "--log-stderr" .PP causes mu to not output log messages to standard error, in addition to sending them to the log file. .SS "--nocolor" .PP do not use ANSI colors. The environment variable \fCNO_COLOR\fP can be used as an alternative to \fC\-\-nocolor\fP. .SS "-V, --version" .PP prints mu version and copyright information. .SS "-h, --help" .PP lists the various command line options. .SH "FLAGS" .PP (Note: if you are not familiar with Maildirs, please refer to the \fBmaildir(5)\fP man-page, or see \fIhttp://cr.yp.to/proto/maildir.html\fP) .PP The message flags specify the Maildir-metadata for a message and are represented by uppercase letters at the end of the message file name for all `non-new' messages, i.e. messages that live in the \fCcur/\fP sub-directory of a Maildir. .TS center,box; l l . Flag Meaning _ D Draft message F Flagged message P Passed message (i.e., `forwarded') R Replied message S Seen message T Trashed; to be deleted later .TE .PP New messages (in the \fCnew/\fP sub-directory) do not have flags encoded in their file-name; but we \fBmu\fP uses `N' in the \fC\-\-flags\fP to represent that: .TS center,box; l l . Flag Meaning _ N New .TE .PP Thus, changing flags means changing the letters at the end of the message file-name, except when setting or removing the `N' (new) flag. Setting or un-setting the New flag causes the message is to be moved from \fCcur/\fP to \fCnew/\fP or vice-versa, respectively. When marking a message as New, it looses the other flags. .SH "ABSOLUTE AND RELATIVE FLAGS" .PP You can specify the flags with the \fC\-\-flags\fP parameter, and do either with either \fBabsolute\fP or \fBrelative\fP flags. .PP Absolute flags just specify the new flags by their letters; e.g. to specify a \fITrashed\fP, \fISeen\fP, \fIReplied\fP message, you'd use \fC\-\-flags STR\fP. #+end_example .PP Relative flags are relative to the current flags for some message, and each of the flags is prefixed with either \fC+\fP ("add this flag") or \fC\-\fP ("remove this flag"). .PP So to add the \fISeen\fP flag and remove the \fIDraft\fP flag from whatever the message already has, \fC\-\-flags +S\-D\fP. .PP You cannot combine relative and relative flags. .SH "EXAMPLES" .SS "change some flags" .RS .nf $ mu move /home/user/Maildir/inbox/cur/1695559560.a73985881f4611ac2.hostname!2,S --flags +F /home/user/Maildir/inbox/cur/1695559560.a73985881f4611ac2.hostname!2,FS .fi .RE .SS "move to a different maildir" .RS .nf $ mu move /home/user/Maildir/project1/cur/1695559560.a73985881f4611ac2.hostname!2,S /project2 /home/user/Maildir/project2/cur/1695559560.a73985881f4611ac2.hostname!2,S .fi .RE .SH "REPORTING BUGS" .PP Please report bugs at \fIhttps://github.com/djcb/mu/issues\fP. .SH "AUTHOR" .PP Dirk-Jan C. Binnema .SH "COPYRIGHT" .PP This manpage is part of \fCmu\fP 1.12.4. .PP Copyright © 2008-2024 Dirk-Jan C. Binnema. License GPLv3+: GNU GPL version 3 or later \fIhttps://gnu.org/licenses/gpl.html\fP. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. .SH "SEE ALSO" .PP \fBmaildir(5)\fP