You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

README.md 5.6 KiB

6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
6 vuotta sitten
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. # Luke's mutt Wizard for automatic Neomutt and OfflineIMAP configuration!
  2. ![mutt wizard preview](etc/mw.png)
  3. Mutt is one of the most rewarding programs one can use, but can be a pain in
  4. the ass to configure. Since my job is making power-user tools available for the
  5. masses I want to create a tool that automates most of mutt configuration so
  6. that users can simply give their email address and get a /comfy/ setup. At
  7. that, I don't just want a mutt wizard, but an offlineIMAP wizard, so users can
  8. easily access their mail offline as well, and a wizard that makes it easy to
  9. store passwords securely using gpg.
  10. The mutt-wizard is all of this in a simple ncurses menu. It's really just a
  11. little bash script, but one that can save countless people thousands of
  12. combined manhours of frustratingly trying to get all the moving pieces working
  13. together.
  14. ## User interface
  15. The system takes an email and autodetect its server settings, generating a
  16. muttrc and offlineimaprc profile automatically. If it can't do so, it simply
  17. prompts you for these (which you can easily look up) and will put them all in
  18. the right places. You get:
  19. + Automatic configuration of mutt and offlineimap.
  20. + Automatic encryption and safe storage of passwords which are used by mutt and
  21. offlineimap when necessary.
  22. + Multiple account management in mutt: jump from account to account with the
  23. `i` prefix in mutt: `i1`: first email account, `i5`: fifth, etc.
  24. + Easy movement to mail folders in mutt: `gi`: go to inbox, `gs` to sent mail,
  25. `ga` to archive, `gS` to spam, `gd` to drafts, etc.
  26. + Some default controls and colors. This system is going to be integrated into
  27. my [public auto-rice script](https://larbs.xyz) so I want it to look pretty
  28. and be usable out the box.
  29. + An optional autosync script that will smartly run offlineimap when connected
  30. to the internet at what interval you want and will notify you with a ding
  31. when new mail arrives.
  32. ### Will it work on my email? (95% yes)
  33. Yes! At this point, the only problems are the unexpected ones. Please try it,
  34. and if you do run into problems, email me at
  35. [luke@lukesmith.xyz](mailto:luke@lukesmith.xyz)! I've tried the system
  36. personally on Gmail, Teknik.io, cock.li and Yandex, while others have tried
  37. other providers.
  38. One email provider which I think will *not* work (and will never work) is
  39. Proton Mail, but that's only because they require encryption through their web
  40. client IIRC.
  41. Note also that Gmail and some providers require you to enable sign-ins from
  42. third-party (or as they call it "less secure") applications to be able to load
  43. mail with mutt and offlineimap. Be sure to enable that!
  44. ## Installation and Dependencies
  45. `dialog`, `neomutt`, `offlineimap` and `msmtp` should be installed. You also need to
  46. have a GPG public/private key pair for the wizard to automatically store your
  47. passwords. The whole repo should be cloned to `~/.config/mutt/`. (If you have a
  48. previous mutt folder, you'll want to back it up or delete it first.)
  49. ```
  50. git clone https://github.com/LukeSmithxyz/mutt-wizard.git ~/.config/mutt
  51. ```
  52. You will want to delete or rename your current `~/.offlineimaprc` and
  53. `~/.msmtprc` as well, as although you can later modify these files produced by
  54. the script, you must have no file there the first time you add your first
  55. account or the wizard will assume some settings are already set which aren't.
  56. Just run `mutt-wizard.sh` and choose to add an account. After you do so, you
  57. may run `offlineimap` to begin the mailsync, and you will be able to run
  58. neomutt and see your mail. If mutt doesn't immediately work properly run the
  59. `Redetect mailboxes` option, then open mutt. This may be necessary for some
  60. accounts.
  61. ### Non-essential dependencies
  62. The automatically deployed configs will look for certain programs for certain
  63. extra abilities. Consider installing the following for the extra functionality.
  64. + `urlscan` -- Detecting and following links with `ctrl-u`
  65. + `mupdf` -- for viewing attached pdfs (`v` to view attachments, then select
  66. .pdf)
  67. + `notmuch` -- for mail searching and indexing set to `ctrl-f`. Be sure to run
  68. `notmuch setup`. Remember your mail is in `~/.mail/` when you configure
  69. notmuch.
  70. + `w3m` and/or `w3mimg` -- for viewing images. Like .pdfs, view in the attachments menu.
  71. + A cron manager if you want the autosync feature.
  72. + `iproute2mac` for Mac users who want the autosync feature.
  73. + `mpv` if you want the autosync feature to notify you with a ding on new mail.
  74. ## The autosync
  75. If you activate the autosync at a significantly infrequent interval, by
  76. default, your system might prompt you for your GPG password every time. To
  77. prevent this, you can change the time a GPG unlock lasts by adding a time in
  78. seconds as below into `~/.gnupg/gpg-agent.conf`:
  79. ```
  80. default-cache-ttl <number-of-seconds>
  81. max-cache-ttl <number-of-seconds>
  82. ```
  83. You can also use [pam-gnupg](https://github.com/cruegge/pam-gnupg) if you want
  84. to just log into your keyring immediately on log in. This is what I do, but
  85. it's less secure if you leave you computer logged on.
  86. ## You can help!
  87. If you use mutt with a particular host or domain, put your server information
  88. in `domains.csv`! This will make everyone else who uses your email provider's
  89. life much easier!
  90. Or you can help monetarily via [Patreon](https://patreon.com/lukesmith) or
  91. [Paypal](https://paypal.me/LukeMSmith)!
  92. ## Notes
  93. Mail is stored in `~/.mail`. mutt configs and caches for each account are in
  94. `~/.config/mutt/accounts/`. Encypted passwords are in
  95. `~/.config/mutt/credentials`. A "personal" muttrc, with the macros for
  96. switching accounts and the default config is in
  97. `~/.config/mutt/personal.muttrc`.
  98. ## Todo
  99. * Expand the list of server information in `domains.csv`, possibly porting the
  100. Thunderbird autoconfigure settings.