From e4f19b6e983a46cae418f94b84ad06c985c06679 Mon Sep 17 00:00:00 2001 From: Pratham Patel Date: Wed, 3 Apr 2024 08:09:40 +0530 Subject: [PATCH] aerc: init config --- .config/aerc/aerc.conf | 94 +++++++++++++++++++++++ .config/aerc/binds.conf | 162 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 256 insertions(+) create mode 100644 .config/aerc/aerc.conf create mode 100644 .config/aerc/binds.conf diff --git a/.config/aerc/aerc.conf b/.config/aerc/aerc.conf new file mode 100644 index 0000000..62871e7 --- /dev/null +++ b/.config/aerc/aerc.conf @@ -0,0 +1,94 @@ +[general] +# counter-intuitive value but false "~/.config/aerc/accounts.conf should be 600" +unsafe-accounts-conf=false + + +[ui] +auto-mark-read=true +completion-popovers=true +fuzzy-complete=true +mouse-enabled=false +new-message-bell=true +sidebar-width=30 +timestamp-format=2006-01-02 15:04:05 +threading-enabled=true + + +# Moves to next message when the current message is deleted +next-message-on-delete=true + + +[statusline] +status-columns=left<*,center:=,right>* + +# aerc-templates(7) +column-left=[{{.Account}}] {{.StatusInfo}}: {{compactDir .Folder}} +column-center={{.PendingKeys}} +column-right={{.TrayInfo}} + + +[viewer] +parse-http-links=false + +# If an email offers several versions (multipart), you can configure which +# mimetype to prefer. For example, this can be used to prefer plaintext over +# html emails. +alternatives=text/plain,text/html + + +[compose] +empty-subject-warning=true + + +[filters] +# +# Filters allow you to pipe an email body through a shell command to render +# certain emails differently, e.g. highlighting them with ANSI escape codes. +# +# The commands are invoked with sh -c. The following folders are prepended to +# the system $PATH to allow referencing filters from their name only: +# +# ${XDG_CONFIG_HOME:-~/.config}/aerc/filters +# ~/.local/libexec/aerc/filters +# ${XDG_DATA_HOME:-~/.local/share}/aerc/filters +# $PREFIX/libexec/aerc/filters +# $PREFIX/share/aerc/filters +# /usr/libexec/aerc/filters +# /usr/share/aerc/filters +# +# If you want to run a program in your default $PATH which has the same name +# as a builtin filter (e.g. /usr/bin/colorize), use its absolute path. +# +# The following variables are defined in the filter command environment: +# +# AERC_MIME_TYPE the part MIME type/subtype +# AERC_FORMAT the part content type format= parameter +# AERC_FILENAME the attachment filename (if any) +# AERC_SUBJECT the message Subject header value +# AERC_FROM the message From header value +# +# The first filter which matches the email's mimetype will be used, so order +# them from most to least specific. +# +# You can also match on non-mimetypes, by prefixing with the header to match +# against (non-case-sensitive) and a comma, e.g. subject,text will match a +# subject which contains "text". Use header,~regex to match against a regex. +# +text/plain=colorize +text/calendar=calendar +message/delivery-status=colorize +message/rfc822=colorize +text/html=pandoc -f html -t plain | colorize +text/*=bat -fP --file-name="$AERC_FILENAME" +application/x-sh=bat -fP -l sh +image/*=catimg -w $(tput cols) - + +# This special filter is only used to post-process email headers when +# [viewer].show-headers=true +# By default, headers are piped directly into the pager. +# +.headers=colorize + + +[hooks] +mail-received=notify-send "[$AERC_ACCOUNT/$AERC_FOLDER]:" "$AERC_SUBJECT" diff --git a/.config/aerc/binds.conf b/.config/aerc/binds.conf new file mode 100644 index 0000000..bad0494 --- /dev/null +++ b/.config/aerc/binds.conf @@ -0,0 +1,162 @@ +# Binds are of the form = +# To use '=' in a key sequence, substitute it with "Eq": "" +# If you wish to bind #, you can wrap the key sequence in quotes: "#" = quit + = :prev-tab + = :prev-tab + = :next-tab + = :next-tab + = :term +? = :help keys + = :prompt 'Quit?' quit + = :prompt 'Quit?' quit + +[messages] +q = :prompt 'Quit?' quit + +j = :next + = :next + = :next 50% + = :next 100% + = :next 100% + +k = :prev + = :prev + = :prev 50% + = :prev 100% + = :prev 100% +g = :select 0 +G = :select -1 + +J = :next-folder + = :next-folder +K = :prev-folder + = :prev-folder +H = :collapse-folder + = :collapse-folder +L = :expand-folder + = :expand-folder + +v = :mark -v +V = :mark -v + +T = :toggle-threads +zc = :fold +zo = :unfold + +o = :view +d = :prompt 'Really delete this message?' move\ Trash +D = :move Trash +a = :archive flat +A = :unmark -a:mark -T:archive flat + +C = :compose +m = :compose + +rr = :reply -a +rq = :reply -aq +Rr = :reply +Rq = :reply -q + +c = :cf +$ = :term +! = :term +| = :pipe + +/ = :search +\ = :filter +n = :next-result +N = :prev-result + = :clear + +s = :split +S = :vsplit + +[messages:folder=Drafts] + = :recall -f + +[view] +/ = :toggle-key-passthrough/ +q = :close +O = :open +o = :open +S = :save +| = :pipe +D = :move Trash +A = :archive flat + + = :open-link + +f = :forward +rr = :reply -a +rq = :reply -aq +Rr = :reply +Rq = :reply -q + +H = :toggle-headers + = :prev-part + = :prev-part + = :next-part + = :next-part +J = :next + = :next +K = :prev + = :prev + +[view::passthrough] +$noinherit = true +$ex = + = :toggle-key-passthrough + +[compose] +# Keybindings used when the embedded terminal is not selected in the compose +# view +$noinherit = true +$ex = + = :prev-field + = :prev-field + = :next-field + = :next-field + = :switch-account -p + = :switch-account -p + = :switch-account -n + = :switch-account -n + = :next-field + = :prev-field + = :prev-tab + = :prev-tab + = :next-tab + = :next-tab + +[compose::editor] +# Keybindings used when the embedded terminal is selected in the compose view +$noinherit = true +$ex = + = :prev-field + = :prev-field + = :next-field + = :next-field + = :prev-tab + = :prev-tab + = :next-tab + = :next-tab + +[compose::review] +# Keybindings used when reviewing a message to be sent +y = :send +n = :abort +v = :preview +p = :postpone +q = :choose -o d discard abort -o p postpone postpone +e = :edit +a = :attach +d = :detach +s = :move Drafts + +[terminal] +$noinherit = true +$ex = + + = :prev-tab + = :next-tab + = :prev-tab + = :next-tab