mailmd sync #
Copy new mail into the archive
Usage #
mailmd sync [account...]Examples #
mailmd sync
mailmd sync work
mailmd sync work --since 12m --exclude Newsletters
mailmd sync work --folder Junk --dry-run
mailmd sync --dry-run
mailmd sync --quietFlags #
--excludeLeave out this folder and its subfolders in this run. It isn't saved (repeat for more)--folderSync only this folder and its subfolders in this run, like INBOX or Junk. It isn't saved (repeat for more)--keep-rawAlso save each original message as an .eml file next to its Markdown file--max-message-bytesSave only the headers of a message larger than this many bytes--outFolder that holds the account folders, for this run instead of the saved --out--prefer-textUse the plain text part of a message instead of converting its HTML part--sinceFetch only mail received on or after this day, like 2025-01-31, or within an age like 30d, 12m or 2y
Output #
Shows text you can read in your terminal.
Use --json to get JSON for scripts and other programs.
Use --plain to get text without color or formatting.
Use --jq to filter the JSON output with a jq expression.
Use --template to format the output with a Go template.
Preview changes #
This command changes things. Add --dry-run to see what it would change; nothing changes then.
Related commands #
- status
- list folders
- connect