From a7b58bae363a32cf34bf46fd505610009d0d9d92 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:14:21 -0700 Subject: [PATCH 01/10] initial addition of isync --- isync/.config/isyncrc | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 isync/.config/isyncrc diff --git a/isync/.config/isyncrc b/isync/.config/isyncrc new file mode 100644 index 0000000..45f286e --- /dev/null +++ b/isync/.config/isyncrc @@ -0,0 +1,23 @@ +IMAPStore andrew@amd.im-remote +Host mail.amd.im +Port 993 +User andrew@amd.im +PassCmd "pass email/amd.im/andrew" +TLSType IMAPS +CertificateFile /etc/ssl/certs/ca-certificates.crt + +MaildirStore andrew@amd.im-local +Subfolders Verbatim +Path ~/.local/share/email/andrew@amd.im/ +INBOX ~/.local/share/email/andrew@amd.im/INBOX +Flatten . + +Channel andrew@amd.im +Far :andrew@amd.im-remote: +Near :andrew@amd.im-local: +Pattern * +SyncState * +Create Both +Expunge Both +MaxMessages 0 + From 25bd4c1e7e1b3f3321f61859d809fc10a32dde94 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:14:41 -0700 Subject: [PATCH 02/10] switching to my actual email address --- neomutt/.config/neomutt/neomuttrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neomutt/.config/neomutt/neomuttrc b/neomutt/.config/neomutt/neomuttrc index ffd3764..c871553 100644 --- a/neomutt/.config/neomutt/neomuttrc +++ b/neomutt/.config/neomutt/neomuttrc @@ -4,8 +4,8 @@ set realname = "Andrew Davidson" ### Connectivity -set imap_user = "andrew@bigfootstoybox.com" -set imap_pass = "`pass show email/bigfootstoybox.com/andrew`" +set imap_user = "andrew@amd.im" +set imap_pass = "`pass show email/amd.im/andrew`" set folder = "imaps://mail.amd.im" set smtp_url = "smtps://$imap_user:$imap_pass@mail.amd.im:465" set ssl_starttls = no From f56382217faed2b881883d1d970ae1707c7f8500 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:15:05 -0700 Subject: [PATCH 03/10] fixing busted mt function, moving tmux command inside function --- bash/.bashrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bash/.bashrc b/bash/.bashrc index 0d7f1de..fdd66d6 100644 --- a/bash/.bashrc +++ b/bash/.bashrc @@ -260,7 +260,7 @@ function tm { # run mosh and tmux to a specific host function mt { - mosh $1 -- tm + mosh $1 -- tmux new-session -A -s main -x $(tput cols) -y $(tput lines) } From 60d8156015c7eaaeede718cc133e00455806cf23 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:15:55 -0700 Subject: [PATCH 04/10] fixing cache folders --- neomutt/.config/neomutt/neomuttrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neomutt/.config/neomutt/neomuttrc b/neomutt/.config/neomutt/neomuttrc index c871553..ec4e7ec 100644 --- a/neomutt/.config/neomutt/neomuttrc +++ b/neomutt/.config/neomutt/neomuttrc @@ -22,8 +22,8 @@ set trash = "=Trash" ### Local Folders -set header_cache = "~/.cache/mutt/headers" -set message_cachedir = "~/.cache/mutt/messages" +set header_cache = "~/.cache/neomutt/headers" +set message_cachedir = "~/.cache/neomutt/messages" ### Local Settings From 42557739b5f0146122dcf89b35060031c71940c3 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:16:03 -0700 Subject: [PATCH 05/10] whitespace --- git/.gitconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/git/.gitconfig b/git/.gitconfig index aa7c4d7..d5f8dbe 100644 --- a/git/.gitconfig +++ b/git/.gitconfig @@ -57,5 +57,6 @@ [init] defaultBranch = main + [gpg] format = ssh From 6021c6949935d4c8598a82e28f86b6f0e7f21d95 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 17:58:21 -0700 Subject: [PATCH 06/10] merging email setup, more to merge soon --- {isync => email}/.config/isyncrc | 2 +- email/.config/neomutt/mailcap | 2 ++ {neomutt => email}/.config/neomutt/neomuttrc | 29 ++++++++++++------- {neomutt => email}/.config/neomutt/nord.theme | 0 email/.notmuch-config | 18 ++++++++++++ 5 files changed, 40 insertions(+), 11 deletions(-) rename {isync => email}/.config/isyncrc (94%) create mode 100644 email/.config/neomutt/mailcap rename {neomutt => email}/.config/neomutt/neomuttrc (79%) rename {neomutt => email}/.config/neomutt/nord.theme (100%) create mode 100644 email/.notmuch-config diff --git a/isync/.config/isyncrc b/email/.config/isyncrc similarity index 94% rename from isync/.config/isyncrc rename to email/.config/isyncrc index 45f286e..55ca62b 100644 --- a/isync/.config/isyncrc +++ b/email/.config/isyncrc @@ -15,7 +15,7 @@ Flatten . Channel andrew@amd.im Far :andrew@amd.im-remote: Near :andrew@amd.im-local: -Pattern * +Pattern * !dovecot/sieve SyncState * Create Both Expunge Both diff --git a/email/.config/neomutt/mailcap b/email/.config/neomutt/mailcap new file mode 100644 index 0000000..2da15a0 --- /dev/null +++ b/email/.config/neomutt/mailcap @@ -0,0 +1,2 @@ +text/html; $BROWSER %s +text/html; w3m -I %{charset} -T text/html -dump; copiousoutput; diff --git a/neomutt/.config/neomutt/neomuttrc b/email/.config/neomutt/neomuttrc similarity index 79% rename from neomutt/.config/neomutt/neomuttrc rename to email/.config/neomutt/neomuttrc index ec4e7ec..85869bd 100644 --- a/neomutt/.config/neomutt/neomuttrc +++ b/email/.config/neomutt/neomuttrc @@ -3,16 +3,18 @@ set from = "andrew@amd.im" set realname = "Andrew Davidson" -### Connectivity -set imap_user = "andrew@amd.im" -set imap_pass = "`pass show email/amd.im/andrew`" -set folder = "imaps://mail.amd.im" -set smtp_url = "smtps://$imap_user:$imap_pass@mail.amd.im:465" -set ssl_starttls = no -set ssl_force_tls = yes -set imap_check_subscribed # automatically check subscribed folders -mailboxes +INBOX +#### Connectivity +#set imap_user = "andrew@amd.im" +#set imap_pass = "`pass show email/amd.im/andrew`" +#set folder = "imaps://mail.amd.im" +#set smtp_url = "smtps://$imap_user:$imap_pass@mail.amd.im:465" +#set ssl_starttls = no +#set ssl_force_tls = yes +#set imap_check_subscribed # automatically check subscribed folders +#mailboxes +INBOX +set mbox_type = Maildir +set folder = "~/.local/share/email/andrew@amd.im" ### Mailbox Locations set spoolfile = "+INBOX" @@ -24,6 +26,7 @@ set trash = "=Trash" ### Local Folders set header_cache = "~/.cache/neomutt/headers" set message_cachedir = "~/.cache/neomutt/messages" +macro index $ "mbsync andrew@amd.im" "sync email" ### Local Settings @@ -48,6 +51,12 @@ set reverse_alias # if an alias is set for a contact, use that set pager_index_lines = 10 # Shows 10 lines of index when pager is active +### Multipart handling +set mailcap_path = "~/.config/neomutt/mailcap" +auto_view text/html +alternative_order text/plain text/enriched text/html + + ### Message threading set sort_re # changes method by which threads are sorted set sort = reverse-threads # sort by threads @@ -57,7 +66,7 @@ set sort_aux = last-date-received # secondarily sory by most recent message re ### Sidebar set sidebar_visible # show the sidebar set sidebar_short_path # simplify paths in sidebar -unset sidebar_folder_indent # indent mailboxes in sidebar +unset sidebar_folder_indent # indent mailboxes in sidebar set sidebar_format = "%B %* [%?N?%N/?%S]" # what should the sidebar display set sidebar_sort_method = path set mail_check_stats # check mailbox statistics for sidebar view diff --git a/neomutt/.config/neomutt/nord.theme b/email/.config/neomutt/nord.theme similarity index 100% rename from neomutt/.config/neomutt/nord.theme rename to email/.config/neomutt/nord.theme diff --git a/email/.notmuch-config b/email/.notmuch-config new file mode 100644 index 0000000..e4c6ec8 --- /dev/null +++ b/email/.notmuch-config @@ -0,0 +1,18 @@ +[database] +path=/home/amd/.local/share/email/andrew@amd.im/ + + +[user] +name=Andrew Davidson +primary_email=andrew@amd.im +other_email=andrew@amdavidson.com amdavids@calpoly.edu amdavidson@gmail.com + +[new] +tags=unread;inbox; +ignore= + +[search] +exclude_tags=deleted;spam; + +[maildir] +synchronize_flags=true From d266bb3942c3c9fc46ba617eb432c72e96426b3a Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 18:23:40 -0700 Subject: [PATCH 07/10] fixing notmuch search shortcuts --- email/.config/neomutt/neomuttrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/email/.config/neomutt/neomuttrc b/email/.config/neomutt/neomuttrc index 85869bd..c421052 100644 --- a/email/.config/neomutt/neomuttrc +++ b/email/.config/neomutt/neomuttrc @@ -26,8 +26,8 @@ set trash = "=Trash" ### Local Folders set header_cache = "~/.cache/neomutt/headers" set message_cachedir = "~/.cache/neomutt/messages" -macro index $ "mbsync andrew@amd.im" "sync email" - +macro index $ "mbsync andrew@amd.imnotmuch new" "sync email" +macro index \\\\ "" "Search mail" ### Local Settings set mail_check = 60 # check for mail every XX seconds From 9d088c10005fa3e0c51a2403ab41200e08cf9f94 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 19:36:43 -0700 Subject: [PATCH 08/10] cleaning up old dotfiles --- .../.local/share/konsole/Dracula.colorscheme | 94 ------------------- offlineimap/.offlineimap.py | 5 - offlineimap/.offlineimaprc_fastmail | 37 -------- offlineimap/bin/fastmail.sh | 24 ----- scripts/bin/pw.sh | 5 - 5 files changed, 165 deletions(-) delete mode 100644 konsole/.local/share/konsole/Dracula.colorscheme delete mode 100644 offlineimap/.offlineimap.py delete mode 100644 offlineimap/.offlineimaprc_fastmail delete mode 100755 offlineimap/bin/fastmail.sh delete mode 100755 scripts/bin/pw.sh diff --git a/konsole/.local/share/konsole/Dracula.colorscheme b/konsole/.local/share/konsole/Dracula.colorscheme deleted file mode 100644 index 2859831..0000000 --- a/konsole/.local/share/konsole/Dracula.colorscheme +++ /dev/null @@ -1,94 +0,0 @@ -[Background] -Color=40,42,54 - -[BackgroundFaint] -Color=40,42,54 - -[BackgroundIntense] -Color=40,42,54 - -[Color0] -Color=189,147,249 - -[Color0Faint] -Color=189,147,249 - -[Color0Intense] -Color=189,147,249 - -[Color1] -Color=255,85,85 - -[Color1Faint] -Color=255,85,85 - -[Color1Intense] -Color=255,85,85 - -[Color2] -Color=80,250,123 - -[Color2Faint] -Color=80,250,123 - -[Color2Intense] -Color=80,250,123 - -[Color3] -Color=255,121,198 - -[Color3Faint] -Color=255,121,198 - -[Color3Intense] -Color=255,121,198 - -[Color4] -Color=139,233,253 - -[Color4Faint] -Color=139,233,253 - -[Color4Intense] -Color=139,233,253 - -[Color5] -Color=241,250,140 - -[Color5Faint] -Color=241,250,140 - -[Color5Intense] -Color=241,250,140 - -[Color6] -Color=98,114,164 - -[Color6Faint] -Color=98,114,164 - -[Color6Intense] -Color=98,114,164 - -[Color7] -Color=68,71,90 - -[Color7Faint] -Color=68,71,90 - -[Color7Intense] -Color=68,71,90 - -[Foreground] -Color=248,248,242 - -[ForegroundFaint] -Color=248,248,242 - -[ForegroundIntense] -Color=248,248,242 - -[General] -Description=Dracula -Opacity=1 -Wallpaper= diff --git a/offlineimap/.offlineimap.py b/offlineimap/.offlineimap.py deleted file mode 100644 index fffb7b7..0000000 --- a/offlineimap/.offlineimap.py +++ /dev/null @@ -1,5 +0,0 @@ -#! /usr/bin/env python2 -from subprocess import check_output - -def get_pass(): - return check_output("~/bin/pw.sh IMAP_PASSWORD", shell=True).strip("\n") diff --git a/offlineimap/.offlineimaprc_fastmail b/offlineimap/.offlineimaprc_fastmail deleted file mode 100644 index 174c656..0000000 --- a/offlineimap/.offlineimaprc_fastmail +++ /dev/null @@ -1,37 +0,0 @@ -[general] -accounts = Personal -ui = basic -#ui = blinkenlights -maxsynaccounts = 1 -pythonfile = ~/.offlineimap.py - -[mbnames] -enabled = yes -filename = ~/.mutt/mailboxes -header = "mailboxes " -peritem = "+%(foldername)s" -sep = " " -footer = "\n" - -[Account Personal] -localrepository = Local -remoterepository = Remote -postsynchook = notmuch new -# autorefresh = 1 -# quick = 10 - -[Repository Local] - -type = Maildir -localfolders = ~/.maildir -sep = . -restoreatime = no - -[Repository Remote] -type = IMAP -remotehost = imap.fastmail.com -remoteuser = andrew@amdavidson.com -remotepasseval = get_pass() -maxconnections = 5 -keepalive = 60 -# holdconnectionopen = yes diff --git a/offlineimap/bin/fastmail.sh b/offlineimap/bin/fastmail.sh deleted file mode 100755 index a4e1c12..0000000 --- a/offlineimap/bin/fastmail.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash - -if [[ "$OSTYPE" == "linux-gnu" ]]; then - echo "OS is linux" - DISTRO=$(. /etc/os-release; echo $NAME) - if [[ "$DISTRO" == "Fedora" ]]; then - echo "Distro is Fedora" - /usr/bin/offlineimap -k Repository_Remote:sslcacertfile=/etc/ssl/certs/ca-bundle.crt -c $HOME/.offlineimaprc_fastmail - elif [[ "$DISTRO" == "Ubuntu" ]]; then - echo "Distro is Ubuntu" - /usr/bin/offlineimap -k Repository_Remote:sslcacertfile=/etc/ssl/certs/ca-certificates.crt -c $HOME/.offlineimaprc_fastmail - elif [[ "$DISTRO" == "Debian GNU/Linux" ]]; then - echo "Distro is Debian" - /usr/bin/offlineimap -k Repository_Remote:sslcacertfile=/etc/ssl/certs/ca-certificates.crt -c $HOME/.offlineimaprc_fastmail - else - echo "Distro is unknown" - /usr/bin/offlineimap -k Repository_Remote:sslcacertfile=/etc/ssl/certs/ca-certificates.crt -c $HOME/.offlineimaprc_fastmail - fi -elif [[ "$OSTYPE" == "darwin"* ]]; then - echo "OS is darwin" - /usr/local/bin/offlineimap -k Repository_Remote:sslcacertfile=/usr/local/etc/openssl/cert.pem -c $HOME/.offlineimaprc_fastmail -else - echo "Offlineimap not configured to access Fastmail on $OSTYPE" -fi diff --git a/scripts/bin/pw.sh b/scripts/bin/pw.sh deleted file mode 100755 index 4ae2284..0000000 --- a/scripts/bin/pw.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -source ~/.env - -echo ${!1} From 2c05b0336a38eb7e97892fd518db5702f2d3c510 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 19:37:18 -0700 Subject: [PATCH 09/10] more cleanup --- khard/.config/khard/khard.conf | 32 -------------------------------- khard/.config/vdirsyncer/config | 20 -------------------- 2 files changed, 52 deletions(-) delete mode 100644 khard/.config/khard/khard.conf delete mode 100644 khard/.config/vdirsyncer/config diff --git a/khard/.config/khard/khard.conf b/khard/.config/khard/khard.conf deleted file mode 100644 index b486b8b..0000000 --- a/khard/.config/khard/khard.conf +++ /dev/null @@ -1,32 +0,0 @@ -[addressbooks] -[[Default]] -path = ~/.contacts/Default - -[general] -debug = no -default_action = list -editor = vim -merge_editor = vimdiff - -[contact table] -# display names by first or last name: first_name / last_name -display = first_name -# group by address book: yes / no -group_by_addressbook = no -# reverse table ordering: yes / no -reverse = no -# append nicknames to name column: yes / no -show_nicknames = no -# show uid table column: yes / no -show_uids = no -# sort by first or last name: first_name / last_name -sort = last_name -# localize dates: yes / no -localize_dates = yes - -[vcard] -# Look into source vcf files to speed up search queries: yes / no -search_in_source_files = no -# skip unparsable vcard files: yes / no -skip_unparsable = no - diff --git a/khard/.config/vdirsyncer/config b/khard/.config/vdirsyncer/config deleted file mode 100644 index 786bec6..0000000 --- a/khard/.config/vdirsyncer/config +++ /dev/null @@ -1,20 +0,0 @@ -[general] -status_path = "~/.vdirsyncer/status/" - -[pair my_contacts] -a = "my_contacts_local" -b = "my_contacts_remote" -collections = ["from a", "from b"] - -[storage my_contacts_local] -type = "filesystem" -path = "~/.contacts/" -fileext = ".vcf" - -[storage my_contacts_remote] -type = "carddav" - -url = "https://carddav.fastmail.com" -username.fetch = ["command", "~/bin/pw.sh", "CARDDAV_USERNAME"] -password.fetch = ["command", "~/bin/pw.sh", "CARDDAV_PASSWORD"] - From 651d17c16ebbd067fe450e13fc93e447b01a7921 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Fri, 13 Sep 2024 19:46:46 -0700 Subject: [PATCH 10/10] adding sync_email script, adding folders to neomutt sidebar. --- email/.config/neomutt/neomuttrc | 4 ++++ email/bin/sync_email.sh | 4 ++++ 2 files changed, 8 insertions(+) create mode 100755 email/bin/sync_email.sh diff --git a/email/.config/neomutt/neomuttrc b/email/.config/neomutt/neomuttrc index c421052..80372e5 100644 --- a/email/.config/neomutt/neomuttrc +++ b/email/.config/neomutt/neomuttrc @@ -15,6 +15,10 @@ set realname = "Andrew Davidson" set mbox_type = Maildir set folder = "~/.local/share/email/andrew@amd.im" +mailboxes =INBOX =Archive =Sent =Trash =Spam +mailboxes =Automatic.DMARC +mailboxes =Lists.Money\ Stuff =Lists.NYT =Lists.SWICG =Lists.Evergreen\ MBA +mailboxes =NeedleandFoot ### Mailbox Locations set spoolfile = "+INBOX" diff --git a/email/bin/sync_email.sh b/email/bin/sync_email.sh new file mode 100755 index 0000000..74813c5 --- /dev/null +++ b/email/bin/sync_email.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +mbsync andrew@amd.im +notmuch new