mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 12:29:19 -08:00
nixdirfmt, vim fixes (sway, notmuch on systems)
This commit is contained in:
parent
dd8758c8bc
commit
f510d05c8f
6 changed files with 54 additions and 48 deletions
|
|
@ -6,9 +6,7 @@ let
|
|||
};
|
||||
in {
|
||||
|
||||
imports = lib.attrValues homeModules ++ [
|
||||
../modules/home
|
||||
./private/profile/home
|
||||
];
|
||||
imports = lib.attrValues homeModules
|
||||
++ [ ../modules/home ./private/profile/home ];
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,35 +2,35 @@
|
|||
|
||||
{
|
||||
config = lib.mkIf config.deploy.profile.gui {
|
||||
programs.notmuch = {
|
||||
enable = true;
|
||||
hooks = { preNew = "mbsync --all"; };
|
||||
};
|
||||
programs.mbsync.enable = true;
|
||||
programs.msmtp.enable = true;
|
||||
accounts.email = {
|
||||
maildirBasePath = "${config.home.homeDirectory}/mail";
|
||||
accounts.kat = {
|
||||
address = "kat@kittywit.ch";
|
||||
primary = true;
|
||||
realName = "kat witch";
|
||||
userName = "kat@kittywit.ch";
|
||||
passwordCommand = ''
|
||||
bitw -p gpg://${
|
||||
../../../private/files/bitw/master.gpg
|
||||
} get "kittywitch email"'';
|
||||
msmtp.enable = true;
|
||||
mbsync.enable = true;
|
||||
mbsync.create = "maildir";
|
||||
notmuch.enable = true;
|
||||
imap.host = "kittywit.ch";
|
||||
smtp.host = "kittywit.ch";
|
||||
gpg = {
|
||||
signByDefault = true;
|
||||
key = "01F50A29D4AA91175A11BDB17248991EFA8EFBEE";
|
||||
programs.notmuch = {
|
||||
enable = true;
|
||||
hooks = { preNew = "mbsync --all"; };
|
||||
};
|
||||
programs.mbsync.enable = true;
|
||||
programs.msmtp.enable = true;
|
||||
accounts.email = {
|
||||
maildirBasePath = "${config.home.homeDirectory}/mail";
|
||||
accounts.kat = {
|
||||
address = "kat@kittywit.ch";
|
||||
primary = true;
|
||||
realName = "kat witch";
|
||||
userName = "kat@kittywit.ch";
|
||||
passwordCommand = ''
|
||||
bitw -p gpg://${
|
||||
../../../private/files/bitw/master.gpg
|
||||
} get "kittywitch email"'';
|
||||
msmtp.enable = true;
|
||||
mbsync.enable = true;
|
||||
mbsync.create = "maildir";
|
||||
notmuch.enable = true;
|
||||
imap.host = "kittywit.ch";
|
||||
smtp.host = "kittywit.ch";
|
||||
gpg = {
|
||||
signByDefault = true;
|
||||
key = "01F50A29D4AA91175A11BDB17248991EFA8EFBEE";
|
||||
};
|
||||
};
|
||||
};
|
||||
programs.vim.plugins = [ pkgs.arc.pkgs.vimPlugins.notmuch-vim ];
|
||||
};
|
||||
programs.vim.plugins = [ pkgs.arc.pkgs.vimPlugins.notmuch-vim ];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@
|
|||
#extraPython3Packages = (ps: with ps; [ jedi pylint ]);
|
||||
extraConfig = import ./vimrc.nix { inherit pkgs config; };
|
||||
};
|
||||
xdg.dataFile = {
|
||||
xdg.dataFile = {
|
||||
"vim/undo/.keep".text = "";
|
||||
"vim/swap/.keep".text = "";
|
||||
"vim/backup/.keep".text = "";
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@
|
|||
" Enable mouse
|
||||
set mouse=a
|
||||
|
||||
" notmuch!
|
||||
let g:notmuch_config_file='$XDG_CONFIG_HOME/notmuch/notmuchrc'
|
||||
" notmuch!
|
||||
let g:notmuch_config_file='${config.xdg.configHome}/notmuch/notmuchrc'
|
||||
let g:notmuch_folders_count_threads=0
|
||||
let g:notmuch_date_format='%y-%m-%d %H:%M'
|
||||
let g:notmuch_datetime_format='%y-%m-%d %H:%M'
|
||||
|
|
@ -195,4 +195,10 @@
|
|||
nnoremap <silent><nowait> <space>k :<C-u>CocPrev<CR>
|
||||
" Resume latest coc list.
|
||||
nnoremap <silent><nowait> <space>p :<C-u>CocListResume<CR>
|
||||
''
|
||||
'' + (if config.deploy.profile.sway == true then ''
|
||||
noremap "+y y:call system("wl-copy", @")<CR>
|
||||
nnoremap "+p :let @"=substitute(system("wl-paste --no-newline"), '<C-v><C-m>', ''', 'g')<CR>p
|
||||
nnoremap "*p :let @"=substitute(system("wl-paste --no-newline --primary"), '<C-v><C-m>', ''', 'g')<CR>p
|
||||
'' else
|
||||
"")
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
{
|
||||
config = lib.mkIf config.deploy.profile.kat {
|
||||
xdg.enable = true;
|
||||
};
|
||||
config = lib.mkIf config.deploy.profile.kat { xdg.enable = true; };
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,15 +4,19 @@ with lib;
|
|||
|
||||
let
|
||||
cfg = config.deploy;
|
||||
secretsScript = concatMapStrings (file: ''
|
||||
ssh $NIX_SSHOPTS root@${cfg.ssh.host} "mkdir -p ${toString file.out.dir}
|
||||
cat > ${file.path}
|
||||
chmod ${file.mode} ${file.path}
|
||||
chown ${file.owner}:${file.group} ${file.path}"'' + (if file.source != null then "< ${toString file.source}\n" else ''
|
||||
<<'EOF'
|
||||
${file.text}
|
||||
EOF
|
||||
'')) (attrValues config.secrets.files);
|
||||
secretsScript = concatMapStrings (file:
|
||||
''
|
||||
ssh $NIX_SSHOPTS root@${cfg.ssh.host} "mkdir -p ${toString file.out.dir}
|
||||
cat > ${file.path}
|
||||
chmod ${file.mode} ${file.path}
|
||||
chown ${file.owner}:${file.group} ${file.path}"''
|
||||
+ (if file.source != null then ''
|
||||
< ${toString file.source}
|
||||
'' else ''
|
||||
<<'EOF'
|
||||
${file.text}
|
||||
EOF
|
||||
'')) (attrValues config.secrets.files);
|
||||
in {
|
||||
options = {
|
||||
deploy = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue