diff --git a/Makefile b/Makefile index 97108776..33904650 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ USER := hlissner HOST := kuro -NIXOS_VERSION := 19.09 +NIXOS_VERSION := 20.03 NIXOS_PREFIX := $(PREFIX)/etc/nixos COMMAND := test FLAGS := -I "config=$$(pwd)/config" \ diff --git a/README.md b/README.md index 8776d03b..db0740cd 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,6 @@ +[![Made with Doom Emacs](https://img.shields.io/badge/Made_with-Doom_Emacs-blueviolet.svg?style=flat-square&logo=GNU%20Emacs&logoColor=white)](https://github.com/hlissner/doom-emacs) +[![NixOS 20.03](https://img.shields.io/badge/NixOS-v20.03-blue.svg?style=flat-square&logo=NixOS&logoColor=white)](https://nixos.org) + ![Me looking busy](/../screenshots/fluorescence/fakebusy.png?raw=true)
@@ -34,7 +37,7 @@ Which is equivalent to: ```sh USER=${USER:-hlissner} HOST=${HOST:-kuro} -NIXOS_VERSION=19.09 +NIXOS_VERSION=20.03 DOTFILES=/home/$USER/.dotfiles git clone https://github.com/hlissner/dotfiles /etc/dotfiles diff --git a/default.nix b/default.nix index 8ea4c544..200d8961 100644 --- a/default.nix +++ b/default.nix @@ -57,5 +57,5 @@ device: username: # compatible, in order to avoid breaking some software such as database # servers. You should change this only after NixOS release notes say you # should. - system.stateVersion = "19.09"; # Did you read the comment? + system.stateVersion = "20.03"; # Did you read the comment? } diff --git a/modules/desktop/bspwm.nix b/modules/desktop/bspwm.nix index 55b7c41c..5ed095af 100644 --- a/modules/desktop/bspwm.nix +++ b/modules/desktop/bspwm.nix @@ -25,9 +25,9 @@ with lib; redshift.enable = true; xserver = { enable = true; + displayManager.defaultSession = "none+bspwm"; displayManager.lightdm.enable = true; displayManager.lightdm.greeters.mini.enable = true; - windowManager.default = "bspwm"; windowManager.bspwm.enable = true; }; }; diff --git a/modules/shell/gnupg.nix b/modules/shell/gnupg.nix index 401d2f4a..cf911083 100644 --- a/modules/shell/gnupg.nix +++ b/modules/shell/gnupg.nix @@ -3,6 +3,7 @@ with lib; let cfg = config.modules; gnupgCfg = cfg.shell.gnupg; + homedir = "$XDG_CONFIG_HOME/gnupg"; in { options.modules.shell.gnupg = { enable = mkOption { type = types.bool; default = false; }; @@ -11,28 +12,23 @@ in { config = mkIf gnupgCfg.enable { my = { - packages = with pkgs; [ - gnupg - pinentry - ]; - env.GNUPGHOME = "$XDG_CONFIG_HOME/gnupg"; - }; + env.GNUPGHOME = homedir; - system.activationScripts.setupGnuPG = "mkdir -p \"${config.my.env.GNUPGHOME}\" -m 700"; + # HACK Without this config file you get "No pinentry program" on 20.03. + # program.gnupg.agent.pinentryFlavor doesn't appear to work, and this + # is cleaner than overriding the systemd unit. + home.xdg.configFile."gnupg/gpg-agent.conf" = { + text = '' + allow-emacs-pinentry + default-cache-ttl ${toString gnupgCfg.cacheTTL} + pinentry-program ${pkgs.pinentry.gtk2}/bin/pinentry + ''; + }; + }; programs.gnupg.agent = { enable = true; enableSSHSupport = true; }; - - systemd.user.services.gpg-agent.serviceConfig.ExecStart = [ - "" '' - ${pkgs.gnupg}/bin/gpg-agent \ - --supervised \ - --allow-emacs-pinentry \ - --default-cache-ttl ${toString gnupgCfg.cacheTTL} \ - --pinentry-program ${pkgs.pinentry}/bin/pinentry-gtk-2 - '' - ]; }; }