Set up kanata, mail, and remove references to name
- Remove reference to the name "Adriel" - Set up email reading - Set up kanata and retire slambda
This commit is contained in:
parent
1103b38c5d
commit
03b97cce9c
|
@ -5,7 +5,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.gitFull;
|
package = pkgs.gitFull;
|
||||||
|
|
||||||
userName = "Matei Adriel";
|
userName = "prescientmoon";
|
||||||
userEmail = "git@moonythm.dev";
|
userEmail = "git@moonythm.dev";
|
||||||
|
|
||||||
# {{{ Globally ignored files
|
# {{{ Globally ignored files
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
{
|
{
|
||||||
imports = [ ./smos ./intray.nix ];
|
imports = [ ./smos ./intray.nix ./mail.nix ];
|
||||||
}
|
}
|
||||||
|
|
354
home/features/cli/productivity/mail.nix
Normal file
354
home/features/cli/productivity/mail.nix
Normal file
|
@ -0,0 +1,354 @@
|
||||||
|
{ config, ... }: {
|
||||||
|
sops.secrets.moonythm_mail_pass.sopsFile = ./secrets.yaml;
|
||||||
|
|
||||||
|
programs.msmtp.enable = true;
|
||||||
|
programs.mbsync.enable = true;
|
||||||
|
services.mbsync.enable = true;
|
||||||
|
programs.notmuch = {
|
||||||
|
enable = true;
|
||||||
|
hooks = {
|
||||||
|
preNew = "mbsync --all";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.email.accounts = {
|
||||||
|
# {{{ Moonythm
|
||||||
|
moonythm = rec {
|
||||||
|
# {{{ Primary config
|
||||||
|
address = "colimit@moonythm.dev";
|
||||||
|
realName = "prescientmoon";
|
||||||
|
userName = address;
|
||||||
|
aliases = [ "hi@moonythm.dev" ];
|
||||||
|
|
||||||
|
folders = {
|
||||||
|
inbox = "Inbox";
|
||||||
|
sent = "Sent";
|
||||||
|
drafts = "Drafts";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
|
||||||
|
passwordCommand = "cat ${config.sops.secrets.moonythm_mail_pass.path}";
|
||||||
|
primary = true;
|
||||||
|
# }}}
|
||||||
|
# {{{ Imap / smtp configuration
|
||||||
|
imap = {
|
||||||
|
host = "imap.migadu.com";
|
||||||
|
port = 993;
|
||||||
|
};
|
||||||
|
|
||||||
|
smtp = {
|
||||||
|
host = "smtp.migadu.com";
|
||||||
|
port = 465;
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
# {{{ Auxilliary services
|
||||||
|
msmtp = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
mbsync = {
|
||||||
|
enable = true;
|
||||||
|
create = "both"; # sync folders both ways
|
||||||
|
expunge = "maildir"; # Delete messages when the local dir says so
|
||||||
|
};
|
||||||
|
|
||||||
|
notmuch = {
|
||||||
|
enable = true;
|
||||||
|
neomutt.enable = true;
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
# {{{ Email client
|
||||||
|
neomutt = {
|
||||||
|
enable = true;
|
||||||
|
sendMailCommand = "msmtpq --read-envelope-from --read-recipients";
|
||||||
|
extraMailboxes = [ "Archive" "Drafts" "Junk" "Sent" "Trash" ];
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
# {{{ Aerc
|
||||||
|
aerc = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
};
|
||||||
|
|
||||||
|
# {{{ Aerc
|
||||||
|
programs.aerc = {
|
||||||
|
enable = true;
|
||||||
|
extraConfig.general.unsafe-accounts-conf = true;
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
# {{{ Neomutt
|
||||||
|
programs.neomutt = {
|
||||||
|
# {{{ Primary config
|
||||||
|
enable = true;
|
||||||
|
vimKeys = true;
|
||||||
|
checkStatsInterval = 60; # How often to check for new mail
|
||||||
|
sidebar = {
|
||||||
|
enable = true;
|
||||||
|
width = 30;
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
binds = [
|
||||||
|
# {{{ Toggle sidebar
|
||||||
|
{
|
||||||
|
map = [ "index" "pager" ];
|
||||||
|
key = "B";
|
||||||
|
action = "sidebar-toggle-visible";
|
||||||
|
}
|
||||||
|
# }}}
|
||||||
|
# {{{ Highlight previous sidebar item
|
||||||
|
{
|
||||||
|
map = [ "index" "pager" ];
|
||||||
|
key = "\\CK";
|
||||||
|
action = "sidebar-prev";
|
||||||
|
}
|
||||||
|
# }}}
|
||||||
|
# {{{ Highlight next sidebar item
|
||||||
|
{
|
||||||
|
map = [ "index" "pager" ];
|
||||||
|
key = "\\CJ";
|
||||||
|
action = "sidebar-next";
|
||||||
|
}
|
||||||
|
# }}}
|
||||||
|
# {{{ Open highlighted sidebar item
|
||||||
|
{
|
||||||
|
map = [ "index" "pager" ];
|
||||||
|
key = "\\CO";
|
||||||
|
action = "sidebar-open";
|
||||||
|
}
|
||||||
|
# }}}
|
||||||
|
];
|
||||||
|
|
||||||
|
macros = [
|
||||||
|
# {{{ Sync emails
|
||||||
|
{
|
||||||
|
map = [ "index" ];
|
||||||
|
key = "S";
|
||||||
|
action = "<shell-escape>mbsync -a<enter><shell-escape>notmuch new<enter>";
|
||||||
|
}
|
||||||
|
# }}}
|
||||||
|
# # {{{ show only messages matching a notmuch pattern
|
||||||
|
# {
|
||||||
|
# map = [ "index" ];
|
||||||
|
# key = "\\Cf";
|
||||||
|
# action = ''"<enter-command>unset wait_key<enter><shell-escape>read -p 'Enter a search term to find with notmuch: ' x;''
|
||||||
|
# + ''echo \\$x >~/.cache/mutt_terms<enter><limit>~i \\"\\`notmuch search - -output=messages \\$(cat ~/.cache/mutt_terms) ''
|
||||||
|
# + ''| head -n 600 | perl -le '@a=<>;s/\^ id:// for@a;$, = \\"|\\";print@a' | perl -le '@a=<>; chomp@a; s/\\\\+/\\\\\\\\+/ for@a;print@a' \`\\"<enter>"'';
|
||||||
|
# }
|
||||||
|
# # }}}
|
||||||
|
];
|
||||||
|
|
||||||
|
extraConfig = ''
|
||||||
|
# Starting point: https://seniormars.com/posts/neomutt/#introduction-and-why
|
||||||
|
# {{{ Settings
|
||||||
|
set pager_index_lines = 10
|
||||||
|
set pager_context = 3 # show 3 lines of context
|
||||||
|
set pager_stop # stop at end of message
|
||||||
|
set menu_scroll # scroll menu
|
||||||
|
set tilde # use ~ to pad mutt
|
||||||
|
set move=no # don't move messages when marking as read
|
||||||
|
set sleep_time = 0 # don't sleep when idle
|
||||||
|
set wait_key = no # mutt won't ask "press key to continue"
|
||||||
|
set envelope_from # which from?
|
||||||
|
# set edit_headers # show headers when composing
|
||||||
|
set fast_reply # skip to compose when replying
|
||||||
|
set askcc # ask for CC:
|
||||||
|
set fcc_attach # save attachments with the body
|
||||||
|
set forward_format = "Fwd: %s" # format of subject when forwarding
|
||||||
|
set forward_decode # decode when forwarding
|
||||||
|
set forward_quote # include message in forwards
|
||||||
|
set mime_forward # forward attachments as part of body
|
||||||
|
set attribution = "On %d, %n wrote:" # format of quoting header
|
||||||
|
set reply_to # reply to Reply to: field
|
||||||
|
set reverse_name # reply as whomever it was to
|
||||||
|
set include # include message in replies
|
||||||
|
set text_flowed=yes # correct indentation for plain text
|
||||||
|
unset sig_dashes # no dashes before sig
|
||||||
|
unset markers
|
||||||
|
# }}}
|
||||||
|
# {{{ Sort by newest conversation first.
|
||||||
|
set charset = "utf-8"
|
||||||
|
set uncollapse_jump
|
||||||
|
set sort_re
|
||||||
|
set sort = reverse-threads
|
||||||
|
set sort_aux = last-date-received
|
||||||
|
# }}}
|
||||||
|
# {{{ How we reply and quote emails.
|
||||||
|
set reply_regexp = "^(([Rr][Ee]?(\[[0-9]+\])?: *)?(\[[^]]+\] *)?)*"
|
||||||
|
set quote_regexp = "^( {0,4}[>|:#%]| {0,4}[a-z0-9]+[>|]+)+"
|
||||||
|
set send_charset = "utf-8:iso-8859-1:us-ascii" # send in utf-8
|
||||||
|
# }}}
|
||||||
|
# {{{ Sidebar
|
||||||
|
set sidebar_visible # comment to disable sidebar by default
|
||||||
|
set sidebar_short_path
|
||||||
|
set sidebar_folder_indent
|
||||||
|
set sidebar_format = "%B %* [%?N?%N / ?%S]"
|
||||||
|
set mail_check_stats
|
||||||
|
# }}}
|
||||||
|
# {{{ Theme
|
||||||
|
# From: https://github.com/altercation/mutt-colors-solarized/blob/master/mutt-colors-solarized-dark-16.muttrc
|
||||||
|
# basic colors ---------------------------------------------------------
|
||||||
|
color normal brightyellow default
|
||||||
|
color error red default
|
||||||
|
color tilde black default
|
||||||
|
color message cyan default
|
||||||
|
color markers red white
|
||||||
|
color attachment white default
|
||||||
|
color search brightmagenta default
|
||||||
|
color status brightyellow black
|
||||||
|
color indicator brightblack yellow
|
||||||
|
color tree cyan default # arrow in threads
|
||||||
|
|
||||||
|
# basic monocolor screen
|
||||||
|
mono bold bold
|
||||||
|
mono underline underline
|
||||||
|
mono indicator reverse
|
||||||
|
mono error bold
|
||||||
|
|
||||||
|
# index ----------------------------------------------------------------
|
||||||
|
|
||||||
|
color index red default "~A" # all messages
|
||||||
|
color index blue default "~N" # new messages
|
||||||
|
color index brightred default "~E" # expired messages
|
||||||
|
color index blue default "~N" # new messages
|
||||||
|
color index blue default "~O" # old messages
|
||||||
|
color index brightmagenta default "~Q" # messages that have been replied to
|
||||||
|
color index brightgreen default "~R" # read messages
|
||||||
|
color index blue default "~U" # unread messages
|
||||||
|
color index blue default "~U~$" # unread, unreferenced messages
|
||||||
|
color index cyan default "~v" # messages part of a collapsed thread
|
||||||
|
color index magenta default "~P" # messages from me
|
||||||
|
color index cyan default "~p!~F" # messages to me
|
||||||
|
color index cyan default "~N~p!~F" # new messages to me
|
||||||
|
color index cyan default "~U~p!~F" # unread messages to me
|
||||||
|
color index brightgreen default "~R~p!~F" # messages to me
|
||||||
|
color index red default "~F" # flagged messages
|
||||||
|
color index red default "~F~p" # flagged messages to me
|
||||||
|
color index red default "~N~F" # new flagged messages
|
||||||
|
color index red default "~N~F~p" # new flagged messages to me
|
||||||
|
color index red default "~U~F~p" # new flagged messages to me
|
||||||
|
color index brightcyan default "~v~(!~N)" # collapsed thread with no unread
|
||||||
|
color index yellow default "~v~(~N)" # collapsed thread with some unread
|
||||||
|
color index green default "~N~v~(~N)" # collapsed thread with unread parent
|
||||||
|
color index red black "~v~(~F)!~N" # collapsed thread with flagged, no unread
|
||||||
|
color index yellow black "~v~(~F~N)" # collapsed thread with some unread & flagged
|
||||||
|
color index green black "~N~v~(~F~N)" # collapsed thread with unread parent & flagged
|
||||||
|
color index green black "~N~v~(~F)" # collapsed thread with unread parent, no unread inside, but some flagged
|
||||||
|
color index cyan black "~v~(~p)" # collapsed thread with unread parent, no unread inside, some to me directly
|
||||||
|
color index yellow red "~v~(~D)" # thread with deleted (doesn't differentiate between all or partial)
|
||||||
|
color index yellow default "~(~N)" # messages in threads with some unread
|
||||||
|
color index green default "~S" # superseded messages
|
||||||
|
color index black red "~D" # deleted messages
|
||||||
|
color index black red "~N~D" # deleted messages
|
||||||
|
color index red default "~T" # tagged messages
|
||||||
|
|
||||||
|
# message headers ------------------------------------------------------
|
||||||
|
|
||||||
|
color hdrdefault brightgreen default
|
||||||
|
color header brightyellow default "^(From)"
|
||||||
|
color header blue default "^(Subject)"
|
||||||
|
|
||||||
|
# body -----------------------------------------------------------------
|
||||||
|
|
||||||
|
color quoted blue default
|
||||||
|
color quoted1 cyan default
|
||||||
|
color quoted2 yellow default
|
||||||
|
color quoted3 red default
|
||||||
|
color quoted4 brightred default
|
||||||
|
|
||||||
|
color signature brightgreen default
|
||||||
|
color bold black default
|
||||||
|
color underline black default
|
||||||
|
color normal default default
|
||||||
|
color body brightcyan default "[;:][-o][)/(|]" # emoticons
|
||||||
|
color body brightcyan default "[;:][)(|]" # emoticons
|
||||||
|
color body brightcyan default "[*]?((N)?ACK|CU|LOL|SCNR|BRB|BTW|CWYL|\
|
||||||
|
|FWIW|vbg|GD&R|HTH|HTHBE|IMHO|IMNSHO|\
|
||||||
|
|IRL|RTFM|ROTFL|ROFL|YMMV)[*]?"
|
||||||
|
color body brightcyan default "[ ][*][^*]*[*][ ]?" # more emoticon?
|
||||||
|
color body brightcyan default "[ ]?[*][^*]*[*][ ]" # more emoticon?
|
||||||
|
|
||||||
|
## pgp
|
||||||
|
|
||||||
|
color body red default "(BAD signature)"
|
||||||
|
color body cyan default "(Good signature)"
|
||||||
|
color body brightblack default "^gpg: Good signature .*"
|
||||||
|
color body brightyellow default "^gpg: "
|
||||||
|
color body brightyellow red "^gpg: BAD signature from.*"
|
||||||
|
mono body bold "^gpg: Good signature"
|
||||||
|
mono body bold "^gpg: BAD signature from.*"
|
||||||
|
|
||||||
|
# yes, an insance URL regex
|
||||||
|
color body red default "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-f][0-9a-f])*@)?((([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?|[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)(:[0-9]+)?)|([a-z0-9_.!~*'()$,;:@&=+-]|%[0-9a-f][0-9a-f])+)(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?(#([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?|(www|ftp)\\.(([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?(:[0-9]+)?(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?(#([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?)[^].,:;!)? \t\r\n<>\"]"
|
||||||
|
# and a heavy handed email regex
|
||||||
|
color body magenta default "((@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]),)*@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]):)?[0-9a-z_.+%$-]+@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\])"
|
||||||
|
|
||||||
|
# Various smilies and the like
|
||||||
|
color body brightwhite default "<[Gg]>" # <g>
|
||||||
|
color body brightwhite default "<[Bb][Gg]>" # <bg>
|
||||||
|
color body yellow default " [;:]-*[})>{(<|]" # :-) etc...
|
||||||
|
# *bold*
|
||||||
|
color body blue default "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
|
||||||
|
mono body bold "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
|
||||||
|
# _underline_
|
||||||
|
color body blue default "(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
|
||||||
|
mono body underline "(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
|
||||||
|
# /italic/ (Sometimes gets directory names)
|
||||||
|
color body blue default "(^|[[:space:][:punct:]])/[^/]+/([[:space:][:punct:]]|$)"
|
||||||
|
mono body underline "(^|[[:space:][:punct:]])/[^/]+/([[:space:][:punct:]]|$)"
|
||||||
|
|
||||||
|
# Border lines.
|
||||||
|
color body blue default "( *[-+=#*~_]){6,}"
|
||||||
|
|
||||||
|
# From https://github.com/jessfraz/dockerfiles/blob/master/mutt/.mutt/mutt-patch-highlighting.muttrc
|
||||||
|
color body cyan default ^(Signed-off-by).*
|
||||||
|
color body cyan default ^(Docker-DCO-1.1-Signed-off-by).*
|
||||||
|
color body brightwhite default ^(Cc)
|
||||||
|
color body yellow default "^diff \-.*"
|
||||||
|
color body brightwhite default "^index [a-f0-9].*"
|
||||||
|
color body brightblue default "^---$"
|
||||||
|
color body white default "^\-\-\- .*"
|
||||||
|
color body white default "^[\+]{3} .*"
|
||||||
|
color body green default "^[\+][^\+]+.*"
|
||||||
|
color body red default "^\-[^\-]+.*"
|
||||||
|
color body brightblue default "^@@ .*"
|
||||||
|
color body green default "LGTM"
|
||||||
|
color body brightmagenta default "-- Commit Summary --"
|
||||||
|
color body brightmagenta default "-- File Changes --"
|
||||||
|
color body brightmagenta default "-- Patch Links --"
|
||||||
|
# }}}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
# {{{ Neomutt desktop entry
|
||||||
|
# Taken from here: https://github.com/Misterio77/nix-config/blob/main/home/misterio/features/productivity/neomutt.nix
|
||||||
|
xdg = {
|
||||||
|
desktopEntries = {
|
||||||
|
neomutt = {
|
||||||
|
name = "Neomutt";
|
||||||
|
genericName = "Email Client";
|
||||||
|
comment = "Read and send emails";
|
||||||
|
exec = "neomutt %U";
|
||||||
|
icon = "mutt";
|
||||||
|
terminal = true;
|
||||||
|
categories = [ "Network" "Email" "ConsoleOnly" ];
|
||||||
|
type = "Application";
|
||||||
|
mimeType = [ "x-scheme-handler/mailto" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
mimeApps.defaultApplications = {
|
||||||
|
"x-scheme-handler/mailto" = "neomutt.desktop";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
# }}}
|
||||||
|
# }}}
|
||||||
|
# {{{ Storage & persistence
|
||||||
|
accounts.email.maildirBasePath = "${config.home.homeDirectory}/maildir";
|
||||||
|
satellite.persistence.at.data.apps.mail.directories = [
|
||||||
|
config.accounts.email.maildirBasePath
|
||||||
|
];
|
||||||
|
# }}}
|
||||||
|
}
|
|
@ -1,6 +1,7 @@
|
||||||
smos_github_token: ENC[AES256_GCM,data:kqy5mQf96DoPN1iEt2akJWFfD3IJWdSkvZa0MeAyF0WJ/+V5P5C4iQ==,iv:QwmIdV/vzGTLE89XJVi3prgfmXqRa/OYcp9CA7KJDYc=,tag:+S1EZBcxoOQO2ADjDx9STQ==,type:str]
|
smos_github_token: ENC[AES256_GCM,data:kqy5mQf96DoPN1iEt2akJWFfD3IJWdSkvZa0MeAyF0WJ/+V5P5C4iQ==,iv:QwmIdV/vzGTLE89XJVi3prgfmXqRa/OYcp9CA7KJDYc=,tag:+S1EZBcxoOQO2ADjDx9STQ==,type:str]
|
||||||
intray_password: ENC[AES256_GCM,data:lTCLWSZIk93LhzHJ/ymc,iv:NcmCK3raatp25cKY6GrlL9hiuJp4HGzVNk/eWqDoobo=,tag:v1dirckcNXJjATvMikfNYw==,type:str]
|
intray_password: ENC[AES256_GCM,data:lTCLWSZIk93LhzHJ/ymc,iv:NcmCK3raatp25cKY6GrlL9hiuJp4HGzVNk/eWqDoobo=,tag:v1dirckcNXJjATvMikfNYw==,type:str]
|
||||||
smos_password: ENC[AES256_GCM,data:s+WuVJpe+bSZ7IPYKqA=,iv:fH4k1VTxkcgBwabX7TwZFu1bdWtinK8vug71xa0PiSo=,tag:epqGvDj5pfh9IVLFQLcifA==,type:str]
|
smos_password: ENC[AES256_GCM,data:s+WuVJpe+bSZ7IPYKqA=,iv:fH4k1VTxkcgBwabX7TwZFu1bdWtinK8vug71xa0PiSo=,tag:epqGvDj5pfh9IVLFQLcifA==,type:str]
|
||||||
|
moonythm_mail_pass: ENC[AES256_GCM,data:FmBUICHDxmn72EGnYVSh,iv:L45AeAiXUfz4jH+4q+PDGwvKnEb4r/XDP+55Cf+Q+Nc=,tag:171ImWbCqdEUUK/nlrldCQ==,type:str]
|
||||||
vaultwarden_env: ENC[AES256_GCM,data:dKAkO1pckFVpuN3srD99aGln8fhT69ZNCO1QbdfyJMHlypyNX3YOReR7BoAeDK5DYGRs//8/PLPynRzKPAICng7+yfNDsHHzaF+QNpY=,iv:oNntDA4cXlg5gbTZwqnpyx5nGkYzmLvds5BsAdpdUdc=,tag:IXYS+CKnVb9ZfBm/zcG3JA==,type:str]
|
vaultwarden_env: ENC[AES256_GCM,data:dKAkO1pckFVpuN3srD99aGln8fhT69ZNCO1QbdfyJMHlypyNX3YOReR7BoAeDK5DYGRs//8/PLPynRzKPAICng7+yfNDsHHzaF+QNpY=,iv:oNntDA4cXlg5gbTZwqnpyx5nGkYzmLvds5BsAdpdUdc=,tag:IXYS+CKnVb9ZfBm/zcG3JA==,type:str]
|
||||||
sops:
|
sops:
|
||||||
kms: []
|
kms: []
|
||||||
|
@ -17,8 +18,8 @@ sops:
|
||||||
Y2E3bmM1TkZoOEN0anJqYUNSQUN5ZDAKtobUBBKbfaUeiPtKN4/oTNaxY3C2joCK
|
Y2E3bmM1TkZoOEN0anJqYUNSQUN5ZDAKtobUBBKbfaUeiPtKN4/oTNaxY3C2joCK
|
||||||
8h4FlRLXd+CGnAyjN2p4FliWzLgmOg4HFNmZSmYLpIh4E9yqadNSSg==
|
8h4FlRLXd+CGnAyjN2p4FliWzLgmOg4HFNmZSmYLpIh4E9yqadNSSg==
|
||||||
-----END AGE ENCRYPTED FILE-----
|
-----END AGE ENCRYPTED FILE-----
|
||||||
lastmodified: "2024-02-12T17:57:29Z"
|
lastmodified: "2024-02-12T23:55:37Z"
|
||||||
mac: ENC[AES256_GCM,data:Ggc4CJuCxQM6vYR8BvCQsPX0dKOAi0TqiHlRgANFaP++d8er5Qz2JIsggwpmABt2E1ueZVY08DNgtg6GQYJDtC5rYzdj0b2kWrfy3NUMh9UAaqxRhcFi8W1Rhn2tQEEf+JRx1hW2yCkqoBvAzzmb+WOM4yS/Fr3IBpPO2jaerrM=,iv:dUqDjN9KHm9yGXs9dO+FkZBzmaHT1UjFoiUjwuzFz88=,tag:LbSy8jFFp2HjBkq3W0zbfQ==,type:str]
|
mac: ENC[AES256_GCM,data:RvJMumDJ2S8JgHwRLG/jhyj1a/ekBmjbzFFk7+6hrDg1/Zi8UzzATLEsEBUhX0X4vlqHBUxv4r61SQEroCl5GXBst+Wtac/zxMGIKm5PDH92HccjJhi4aftGP22PHlYCEOis7+D/Vw7W8ovRCFpEYVxxslxibCIo9RuUf8vDE94=,iv:kavw38JSPem1eChO+ntLwLFt6bAJT1rd8s00nmHNzGY=,tag:QuncWa50NvpLqMZGS0F9ug==,type:str]
|
||||||
pgp: []
|
pgp: []
|
||||||
unencrypted_suffix: _unencrypted
|
unencrypted_suffix: _unencrypted
|
||||||
version: 3.8.1
|
version: 3.8.1
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"name": "adriels-snippets",
|
"name": "lunar-snippets",
|
||||||
"engines": {
|
"engines": {
|
||||||
"vscode": "^1.11.0"
|
"vscode": "^1.11.0"
|
||||||
},
|
},
|
||||||
|
|
|
@ -34,23 +34,28 @@
|
||||||
# lutris # Game launcher
|
# lutris # Game launcher
|
||||||
# }}}
|
# }}}
|
||||||
# {{{ Clis
|
# {{{ Clis
|
||||||
|
sops # Secret editing
|
||||||
# sherlock # Search for usernames across different websites
|
# sherlock # Search for usernames across different websites
|
||||||
# }}}
|
# }}}
|
||||||
# {{{ Misc
|
# {{{ Misc
|
||||||
obsidian # Notes
|
obsidian # Note-taking
|
||||||
# peek # GIF recorder
|
bitwarden # Password-manager
|
||||||
# mpv # Video player
|
|
||||||
# plover.dev # steno engine
|
# plover.dev # steno engine
|
||||||
# qbittorrent # Torrent client
|
# qbittorrent # Torrent client
|
||||||
# google-chrome # Not my primary browser, but sometimes needed in webdev
|
# google-chrome # Not my primary browser, but sometimes needed in webdev
|
||||||
# obs-studio # video recorder
|
|
||||||
# }}}
|
# }}}
|
||||||
|
# {{{ Media playing/recording
|
||||||
|
mpv # Video player
|
||||||
|
img # Image viewer
|
||||||
|
# peek # GIF recorder
|
||||||
|
# obs-studio # video recorder
|
||||||
|
# }}}
|
||||||
];
|
];
|
||||||
|
|
||||||
home.sessionVariables.QT_SCREEN_SCALE_FACTORS = 1.4; # Bigger text in qt apps
|
home.sessionVariables.QT_SCREEN_SCALE_FACTORS = 1.4; # Bigger text in qt apps
|
||||||
|
|
||||||
satellite = {
|
satellite = {
|
||||||
# Simlink some commonly modified dotfiles outside the store
|
# Symlink some commonly modified dotfiles outside the nix store
|
||||||
dev.enable = true;
|
dev.enable = true;
|
||||||
|
|
||||||
monitors = [{
|
monitors = [{
|
||||||
|
|
186
hosts/nixos/common/optional/services/kanata.nix
Normal file
186
hosts/nixos/common/optional/services/kanata.nix
Normal file
|
@ -0,0 +1,186 @@
|
||||||
|
{ ... }:
|
||||||
|
let mkConfig = { blueTrigger, redTrigger, chordDelay }: ''
|
||||||
|
;; {{{ Source layout
|
||||||
|
(defsrc
|
||||||
|
grv 1 2 3 4 5 6 7 8 9 0 - = bspc
|
||||||
|
tab q w e r t y u i o p [ ] \
|
||||||
|
caps a s d f g h j k l ; ' ret
|
||||||
|
lsft z x c v b n m , . / rsft
|
||||||
|
lctl lmet ${redTrigger} spc ${blueTrigger}
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Layer & utility aliases
|
||||||
|
(defalias
|
||||||
|
red (layer-while-held red)
|
||||||
|
blue (layer-while-held blue)
|
||||||
|
purple (layer-while-held purple)
|
||||||
|
|
||||||
|
em (unicode —)
|
||||||
|
udo (arbitrary-code 131)
|
||||||
|
cpy (arbitrary-code 133)
|
||||||
|
pst (arbitrary-code 135)
|
||||||
|
cut (arbitrary-code 137)
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Chord aliases
|
||||||
|
(defalias
|
||||||
|
chq (chord mainchords q)
|
||||||
|
chw (chord mainchords w)
|
||||||
|
che (chord mainchords e)
|
||||||
|
chr (chord mainchords r)
|
||||||
|
cha (chord mainchords a)
|
||||||
|
chs (chord mainchords s)
|
||||||
|
chd (chord mainchords d)
|
||||||
|
chf (chord mainchords f)
|
||||||
|
chz (chord mainchords z)
|
||||||
|
chx (chord mainchords x)
|
||||||
|
chc (chord mainchords c)
|
||||||
|
chg (chord mainchords g)
|
||||||
|
chh (chord mainchords h)
|
||||||
|
chi (chord mainchords i)
|
||||||
|
chp (chord mainchords p)
|
||||||
|
chj (chord mainchords j)
|
||||||
|
chk (chord mainchords k)
|
||||||
|
chl (chord mainchords l)
|
||||||
|
ch: (chord mainchords :)
|
||||||
|
chn (chord mainchords n)
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
|
||||||
|
(defchords mainchords ${toString chordDelay}
|
||||||
|
;; {{{ Single keys
|
||||||
|
(q) q
|
||||||
|
(w) w
|
||||||
|
(e) e
|
||||||
|
(r) r
|
||||||
|
(a) a
|
||||||
|
(s) s
|
||||||
|
(d) d
|
||||||
|
(f) f
|
||||||
|
(z) z
|
||||||
|
(x) x
|
||||||
|
(c) c
|
||||||
|
(g) g
|
||||||
|
(h) h
|
||||||
|
(i) i
|
||||||
|
(p) p
|
||||||
|
(j) j
|
||||||
|
(k) k
|
||||||
|
(l) l
|
||||||
|
(:) ;
|
||||||
|
(n) n
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Left modifiers
|
||||||
|
(a s ) lalt
|
||||||
|
( s d ) lsft
|
||||||
|
( s f) lctl
|
||||||
|
( s d f) C-lsft
|
||||||
|
(a s d ) S-lalt
|
||||||
|
(a s d f) C-S-lalt
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Right modifiers
|
||||||
|
( l :) ralt
|
||||||
|
( k l ) rsft
|
||||||
|
(j l ) rctl
|
||||||
|
(j k l ) C-rsft
|
||||||
|
( k l :) S-ralt
|
||||||
|
(j k l :) C-S-ralt
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Special keys
|
||||||
|
(d f) tab
|
||||||
|
(e f) ret
|
||||||
|
(q w) esc
|
||||||
|
|
||||||
|
(g h) bspc
|
||||||
|
(n l) rmet
|
||||||
|
|
||||||
|
(j k) f10
|
||||||
|
(c p) f11
|
||||||
|
(j i) f12
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Wm keybinds
|
||||||
|
(n l k) M-p
|
||||||
|
(n l q) M-1
|
||||||
|
(n l w) M-2
|
||||||
|
(n l e) M-3
|
||||||
|
(n l r) M-4
|
||||||
|
(n l a) M-5
|
||||||
|
(n l s) M-6
|
||||||
|
(n l d) M-7
|
||||||
|
(n l f) M-8
|
||||||
|
(n l z) M-9
|
||||||
|
(n l x) M-0
|
||||||
|
;; }}}
|
||||||
|
)
|
||||||
|
|
||||||
|
;; {{{ Qwerty
|
||||||
|
(deflayer qwerty
|
||||||
|
XX XX XX XX XX XX XX XX XX XX XX XX XX XX
|
||||||
|
XX @chq @chw @che @chr t y u @chi o @chp XX XX XX
|
||||||
|
XX @cha @chs @chd @chf @chg @chh @chj @chk @chl @ch: XX XX
|
||||||
|
lsft @chz @chx @chc v b @chn m , . ' XX
|
||||||
|
XX lmet @red spc @blue
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Transparent template
|
||||||
|
(deflayer template
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ _
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Blue
|
||||||
|
(deflayer blue
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ S-1 S-2 S-3 S-4 S-5 S-6 S-7 S-8 grv S-grv _ _ _
|
||||||
|
_ S-, S-9 [ S-[ - S-/ S-- / = S-; _ _
|
||||||
|
_ S-. S-0 ] S-] @em _ S-\ \ S-= S-' _
|
||||||
|
_ _ @purple _ _
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Red
|
||||||
|
(deflayer red
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ 1 2 3 4 _ _ _ _ _ _ _ _ _
|
||||||
|
_ 5 6 7 8 _ left down up rght _ _ _
|
||||||
|
_ 9 0 _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ @purple
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
;; {{{ Purple
|
||||||
|
(deflayer purple
|
||||||
|
_ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||||||
|
_ _ _ _ _ _ _ _ _ _ @cpy _ _ _
|
||||||
|
_ _ _ _ _ _ _ _ _ _ @pst _ _
|
||||||
|
_ _ _ _ _ _ _ _ @udo _ @cut _
|
||||||
|
_ _ _ _ _
|
||||||
|
)
|
||||||
|
;; }}}
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.kanata = {
|
||||||
|
enable = true;
|
||||||
|
keyboards.tethysLaptop = {
|
||||||
|
devices = [ "/dev/input/by-path/platform-i8042-serio-0-event-kbd" ];
|
||||||
|
|
||||||
|
config = mkConfig {
|
||||||
|
redTrigger = "lalt";
|
||||||
|
blueTrigger = "ralt";
|
||||||
|
chordDelay = 25;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
keyboards.keychronK6 = {
|
||||||
|
devices = [ "/dev/input/by-id/usb-Keychron_Keychron_K6-event-kbd" ];
|
||||||
|
|
||||||
|
config = mkConfig {
|
||||||
|
redTrigger = "lalt";
|
||||||
|
blueTrigger = "rctl";
|
||||||
|
chordDelay = 30;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -8,7 +8,8 @@
|
||||||
../common/optional/greetd.nix
|
../common/optional/greetd.nix
|
||||||
../common/optional/quietboot.nix
|
../common/optional/quietboot.nix
|
||||||
../common/optional/desktop/steam.nix
|
../common/optional/desktop/steam.nix
|
||||||
../common/optional/services/slambda.nix
|
# ../common/optional/services/slambda.nix
|
||||||
|
../common/optional/services/kanata.nix
|
||||||
../common/optional/desktop/xdg-portal.nix
|
../common/optional/desktop/xdg-portal.nix
|
||||||
../common/optional/wayland/hyprland.nix
|
../common/optional/wayland/hyprland.nix
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue