commit 37636d204ae5a6f6c885eb9b8e924ec9b0ffbc11
parent 45efb01ce26d98c5f6200f0e7943d4841aae13c0
Author: Vincent Demeester <vincent@sbr.pm>
Date: Wed, 16 Sep 2020 17:37:22 +0200
nixos: fix with 20.09 update
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
4 files changed, 165 insertions(+), 180 deletions(-)
diff --git a/overlays/sbr.nix b/overlays/sbr.nix
@@ -23,23 +23,6 @@ rec {
inherit (self) pkgs;
};
- emacs27 = (self.emacs.override { srcRepo = true; }).overrideAttrs (
- old: {
- name = "emacs-dev";
- version = "27.0.91";
- src = super.fetchFromGitHub {
- owner = "emacs-mirror";
- repo = "emacs";
- rev = "emacs-27.0.91";
- sha256 = "0mlrg2npy1r79laahkgzhxd1qassfcdz8qk1cpw7mqgf6y5x505h";
- };
- buildInputs = old.buildInputs ++ [ super.jansson ];
- patches = [
- ./patches/clean-env.patch
- ];
- }
- );
-
bookmark-plus = compileEmacsFiles {
name = "bookmark-plus";
src = super.fetchFromGitHub {
diff --git a/systems/modules/core/nix.nix b/systems/modules/core/nix.nix
@@ -77,7 +77,8 @@ in
automatic = true;
dates = [ "01:10" "12:10" ];
};
- nrBuildUsers = config.nix.maxJobs * 2;
+ nrBuildUsers = 4;
+ #nrBuildUsers = config.nix.maxJobs * 2;
trustedUsers = [ "root" "@wheel" ];
useSandbox = true;
};
diff --git a/users/modules/profiles/mails.nix b/users/modules/profiles/mails.nix
@@ -20,189 +20,192 @@ in
};
};
- config = mkIf cfg.enable (mkMerge [
- {
- accounts.email = {
- maildirBasePath = "desktop/mails";
- accounts = {
- "redhat" = {
- address = "vdemeest@redhat.com";
- userName = "vdemeest@redhat.com";
- realName = "Vincent Demeester";
- passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/rh.pass -d ${config.home.homeDirectory}/desktop/documents/rh.pass.gpg";
- imap.host = "imap.gmail.com";
- smtp.host = "smtp.gmail.com";
- mbsync = {
- enable = true;
- create = "both";
- expunge = "both";
- patterns = [ "*" "![Gmail]*" "[Gmail]/Sent Mail" "[Gmail]/Starred" "[Gmail]/All Mail" ];
- extraConfig = {
- channel = {
- Sync = "All";
- };
- account = {
- Timeout = 120;
- PipelineDepth = 1;
+ config = mkIf cfg.enable (
+ mkMerge [
+ {
+ accounts.email = {
+ maildirBasePath = "desktop/mails";
+ accounts = {
+ "redhat" = {
+ address = "vdemeest@redhat.com";
+ userName = "vdemeest@redhat.com";
+ realName = "Vincent Demeester";
+ passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/rh.pass -d ${config.home.homeDirectory}/desktop/documents/rh.pass.gpg";
+ imap.host = "imap.gmail.com";
+ smtp.host = "smtp.gmail.com";
+ mbsync = {
+ enable = true;
+ create = "both";
+ expunge = "both";
+ patterns = [ "*" "![Gmail]*" "[Gmail]/Sent Mail" "[Gmail]/Starred" "[Gmail]/All Mail" ];
+ extraConfig = {
+ channel = {
+ Sync = "All";
+ };
+ account = {
+ Timeout = 120;
+ PipelineDepth = 1;
+ };
};
};
+ notmuch.enable = cfg.sync;
+ astroid.enable = cfg.sync;
+ msmtp.enable = true;
};
- notmuch.enable = cfg.sync;
- astroid.enable = cfg.sync;
- msmtp.enable = true;
- };
- "perso" = {
- address = "vinc.demeester@gmail.com";
- userName = "vinc.demeester@gmail.com";
- realName = "Vincent Demeester";
- passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/perso.pass -d ${config.home.homeDirectory}/desktop/documents/perso.pass.gpg";
- imap.host = "imap.gmail.com";
- smtp.host = "smtp.gmail.com";
- mbsync = {
- enable = true;
- create = "both";
- expunge = "both";
- patterns = [ "*" "![Gmail]*" "[Gmail]/Sent Mail" "[Gmail]/Starred" "[Gmail]/All Mail" ];
- extraConfig = {
- channel = {
- Sync = "All";
- };
- account = {
- Timeout = 120;
- PipelineDepth = 1;
+ "perso" = {
+ address = "vinc.demeester@gmail.com";
+ userName = "vinc.demeester@gmail.com";
+ realName = "Vincent Demeester";
+ passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/perso.pass -d ${config.home.homeDirectory}/desktop/documents/perso.pass.gpg";
+ imap.host = "imap.gmail.com";
+ smtp.host = "smtp.gmail.com";
+ mbsync = {
+ enable = true;
+ create = "both";
+ expunge = "both";
+ patterns = [ "*" "![Gmail]*" "[Gmail]/Sent Mail" "[Gmail]/Starred" "[Gmail]/All Mail" ];
+ extraConfig = {
+ channel = {
+ Sync = "All";
+ };
+ account = {
+ Timeout = 120;
+ PipelineDepth = 1;
+ };
};
};
+ notmuch.enable = cfg.sync;
+ astroid.enable = cfg.sync;
+ msmtp.enable = true;
};
- notmuch.enable = cfg.sync;
- astroid.enable = cfg.sync;
- msmtp.enable = true;
- };
- "prv" = {
- primary = true;
- address = "vincent@demeester.fr";
- userName = "vincent@demeester.fr";
- realName = "Vincent Demeester";
- passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/prv.pass -d ${config.home.homeDirectory}/desktop/documents/prv.pass.gpg";
- imap.host = "mail.gandi.net";
- smtp.host = "mail.gandi.net";
- mbsync = {
- enable = true;
- create = "both";
- expunge = "both";
- patterns = [ "*" ];
- extraConfig = {
- channel = {
- Sync = "All";
- };
- account = {
- Timeout = 120;
- PipelineDepth = 1;
+ "prv" = {
+ primary = true;
+ address = "vincent@demeester.fr";
+ userName = "vincent@demeester.fr";
+ realName = "Vincent Demeester";
+ passwordCommand = "${pkgs.gnupg}/bin/gpg -q --for-your-eyes-only --no-tty --exit-on-status-write-error --batch --passphrase-file ${config.home.homeDirectory}/sync/prv.pass -d ${config.home.homeDirectory}/desktop/documents/prv.pass.gpg";
+ imap.host = "mail.gandi.net";
+ smtp.host = "mail.gandi.net";
+ mbsync = {
+ enable = true;
+ create = "both";
+ expunge = "both";
+ patterns = [ "*" ];
+ extraConfig = {
+ channel = {
+ Sync = "All";
+ };
+ account = {
+ Timeout = 120;
+ PipelineDepth = 1;
+ };
};
};
+ notmuch.enable = cfg.sync;
+ astroid.enable = cfg.sync;
+ msmtp.enable = true;
};
- notmuch.enable = cfg.sync;
- astroid.enable = cfg.sync;
- msmtp.enable = true;
};
};
- };
- home.file."bin/msmtp" = {
- text = ''
- #!${pkgs.stdenv.shell}
- ${pkgs.libnotify}/bin/notify-send "Sending mail ✉️"
- ${pkgs.msmtp}/bin/msmtp --read-envelope-from $@
- '';
- executable = true;
- };
+ home.file."bin/msmtp" = {
+ text = ''
+ #!${pkgs.stdenv.shell}
+ ${pkgs.libnotify}/bin/notify-send "Sending mail ✉️"
+ ${pkgs.msmtp}/bin/msmtp --read-envelope-from $@
+ '';
+ executable = true;
+ };
- programs.msmtp.enable = true;
+ programs.msmtp.enable = true;
- }
+ }
- (mkIf cfg.sync {
+ (
+ mkIf cfg.sync {
- services.mbsync = {
- enable = true;
- preExec = "${config.xdg.configHome}/mbsync/preExec";
- postExec = "${config.xdg.configHome}/mbsync/postExec";
- frequency = cfg.frequency;
- };
+ services.mbsync = {
+ enable = true;
+ preExec = "${config.xdg.configHome}/mbsync/preExec";
+ postExec = "${config.xdg.configHome}/mbsync/postExec";
+ frequency = cfg.frequency;
+ };
- xdg.configFile."mbsync/preExec" = {
- text = ''
- #!${pkgs.stdenv.shell}
+ xdg.configFile."mbsync/preExec" = {
+ text = ''
+ #!${pkgs.stdenv.shell}
- export NOTMUCH_CONFIG=${config.xdg.configHome}/notmuch/notmuchrc
- export NMBGIT=${config.xdg.dataHome}/notmuch/nmbug
+ export NOTMUCH_CONFIG=${config.xdg.configHome}/notmuch/notmuchrc
+ export NMBGIT=${config.xdg.dataHome}/notmuch/nmbug
- ${pkgs.coreutils}/bin/mkdir -p ${config.home.homeDirectory}/desktop/mails/redhat ${config.home.homeDirectory}/desktop/mails/perso
- ${pkgs.afew}/bin/afew -C ${config.xdg.configHome}/notmuch/notmuchrc -m -v
- '';
- executable = true;
- };
+ ${pkgs.coreutils}/bin/mkdir -p ${config.home.homeDirectory}/desktop/mails/redhat ${config.home.homeDirectory}/desktop/mails/perso
+ ${pkgs.afew}/bin/afew -C ${config.xdg.configHome}/notmuch/notmuchrc -m -v
+ '';
+ executable = true;
+ };
- xdg.configFile."mbsync/postExec" = {
- text = ''
- #!${pkgs.stdenv.shell}
-
- export NOTMUCH_CONFIG=${config.xdg.configHome}/notmuch/notmuchrc
- export NMBGIT=${config.xdg.dataHome}/notmuch/nmbug
-
- ${pkgs.notmuch}/bin/notmuch new
- ${pkgs.afew}/bin/afew -C ${config.xdg.configHome}/notmuch/notmuchrc --tag --new -v
- # Remove inbox (lower-case)
- ${pkgs.notmuch}/bin/notmuch tag -inbox -- tag:inbox
- # Remove Inbox tagged message that are not in an Inbox
- ${pkgs.notmuch}/bin/notmuch tag -Inbox -- not folder:redhat/Inbox and not folder:perso/Inbox and tag:Inbox
- ${pkgs.libnotify}/bin/notify-send "Mails synced 📬"
- '';
- executable = true;
- };
+ xdg.configFile."mbsync/postExec" = {
+ text = ''
+ #!${pkgs.stdenv.shell}
+
+ export NOTMUCH_CONFIG=${config.xdg.configHome}/notmuch/notmuchrc
+ export NMBGIT=${config.xdg.dataHome}/notmuch/nmbug
+
+ ${pkgs.notmuch}/bin/notmuch new
+ ${pkgs.afew}/bin/afew -C ${config.xdg.configHome}/notmuch/notmuchrc --tag --new -v
+ # Remove inbox (lower-case)
+ ${pkgs.notmuch}/bin/notmuch tag -inbox -- tag:inbox
+ # Remove Inbox tagged message that are not in an Inbox
+ ${pkgs.notmuch}/bin/notmuch tag -Inbox -- not folder:redhat/Inbox and not folder:perso/Inbox and tag:Inbox
+ ${pkgs.libnotify}/bin/notify-send "Mails synced 📬"
+ '';
+ executable = true;
+ };
- home.file."bin/msync" = {
- text = ''
- #!${pkgs.stdenv.shell}
- ${pkgs.libnotify}/bin/notify-send "Syncing mails 📫️"
- systemctl --user start mbsync
- '';
- executable = true;
- };
+ home.file."bin/msync" = {
+ text = ''
+ #!${pkgs.stdenv.shell}
+ ${pkgs.libnotify}/bin/notify-send "Syncing mails 📫️"
+ systemctl --user start mbsync
+ '';
+ executable = true;
+ };
- programs.mbsync.enable = true;
- programs.notmuch.enable = true;
-
- programs.afew = {
- enable = true;
- extraConfig = ''
- [SpamFilter]
- [KillThreadsFilter]
- [ListMailsFilter]
- [ArchiveSentMailsFilter]
- [FolderNameFilter]
- maildir_separator = /
-
- [MailMover]
- folders = perso/Inbox redhat/Inbox
- rename = true
-
- perso/Inbox = 'NOT tag:Inbox':"perso/[Gmail]/All Mail"
- redhat/Inbox = 'NOT tag:Inbox':"redhat/[Gmail]/All Mail"
- '';
- };
+ programs.mbsync.enable = true;
+ programs.notmuch.enable = true;
+
+ programs.afew = {
+ enable = true;
+ extraConfig = ''
+ [SpamFilter]
+ [KillThreadsFilter]
+ [ListMailsFilter]
+ [ArchiveSentMailsFilter]
+ [FolderNameFilter]
+ maildir_separator = /
+
+ [MailMover]
+ folders = perso/Inbox redhat/Inbox
+ rename = true
+
+ perso/Inbox = 'NOT tag:Inbox':"perso/[Gmail]/All Mail"
+ redhat/Inbox = 'NOT tag:Inbox':"redhat/[Gmail]/All Mail"
+ '';
+ };
- programs.astroid = {
- enable = true;
- externalEditor = "emacsclient -c";
- extraConfig = {
- startup.queries.inbox = "tag:Inbox";
- startup.queries.inbox_perso = "folder:perso/Inbox";
- startup.queries.inbox_redhat = "folder:redhat/Inbox";
- };
- };
+ programs.astroid = {
+ enable = true;
+ externalEditor = "emacsclient -c";
+ extraConfig = {
+ startup.queries.inbox = "tag:Inbox";
+ startup.queries.inbox_perso = "folder:perso/Inbox";
+ startup.queries.inbox_redhat = "folder:redhat/Inbox";
+ };
+ };
- }
- )
+ }
+ )
- ]);
+ ]
+ );
}
diff --git a/users/vincent/dev/go.nix b/users/vincent/dev/go.nix
@@ -19,9 +19,7 @@
dep
# misc
protobuf
- my.protobuild
my.ram
- my.sec
my.esc
my.yaspell
];