diff --git a/overlay.nix b/overlay.nix index ff66a93..4107bdb 100644 --- a/overlay.nix +++ b/overlay.nix @@ -57,7 +57,24 @@ in rec { nerdfonts = nur.balsoft.pkgs.roboto-mono-nerd; pass-secret-service = - prev.pass-secret-service.overrideAttrs (_: { installCheckPhase = null; }); + prev.pass-secret-service.overrideAttrs (_: { + installCheckPhase = null; + postInstall = '' + mkdir -p $out/share/{dbus-1/services,xdg-desktop-portal/portals} + cat > $out/share/dbus-1/services/org.freedesktop.secrets.service << EOF + [D-BUS Service] + Name=org.freedesktop.secrets + Exec=/run/current-system/sw/bin/systemctl --user start pass-secret-service + EOF + cp $out/share/dbus-1/services/{org.freedesktop.secrets.service,org.freedesktop.impl.portal.Secret.service} + cat > $out/share/xdg-desktop-portal/portals/pass-secret-service.portal << EOF + [portal] + DBusName=org.freedesktop.secrets + Interfaces=org.freedesktop.impl.portal.Secrets + UseIn=gnome + EOF + ''; + }); nix-direnv = inputs.nix-direnv.defaultPackage.${system}; diff --git a/profiles/applications/vscodium/default.nix b/profiles/applications/vscodium/default.nix index f673c7b..1663d6f 100644 --- a/profiles/applications/vscodium/default.nix +++ b/profiles/applications/vscodium/default.nix @@ -54,7 +54,6 @@ in { mutableExtensionsDir = false; extensions = with pkgs.vscode-extensions; [ - asvetliakov.vscode-neovim kahole.magit (inputs.direnv-vscode.packages.${pkgs.system}.vsix.overrideAttrs (_: { buildPhase = "yarn run build"; diff --git a/profiles/workspace/gnome3/default.nix b/profiles/workspace/gnome3/default.nix index 604e667..ac3e4cb 100644 --- a/profiles/workspace/gnome3/default.nix +++ b/profiles/workspace/gnome3/default.nix @@ -9,11 +9,15 @@ gnome-settings-daemon.enable = true; glib-networking.enable = true; # pass-secret-service is used instead - gnome-keyring.enable = true; + gnome-keyring.enable = lib.mkForce false; gnome-online-accounts.enable = true; gnome-online-miners.enable = true; }; + environment.systemPackages = [ pkgs.pass-secret-service ]; + services.dbus.packages = [ pkgs.pass-secret-service ]; + xdg.portal.extraPortals = [ pkgs.pass-secret-service ]; + services.gvfs.enable = true; services.geoclue2.enable = true; @@ -43,14 +47,12 @@ systemd.user.services.pass-secret-service = { Service = { - ExecStart = lib.mkForce - "${pkgs.pass-secret-service}/bin/pass_secret_service --path ${config.environment.variables.PASSWORD_STORE_DIR}"; Type = "dbus"; Environment = [ "GPG_TTY=/dev/tty1" "DISPLAY=:0" ]; BusName = "org.freedesktop.secrets"; }; Unit = rec { - Wants = [ "gpg-agent.service" "activate-secrets.service" ]; + Wants = [ "gpg-agent.service" ]; After = Wants; PartOf = [ "graphical-session-pre.target" ]; };