From 9c733a135a6fbdc1a2429a3a2d80acc59609cb94 Mon Sep 17 00:00:00 2001 From: John Lancaster <32917998+jsl12@users.noreply.github.com> Date: Thu, 26 Mar 2026 17:22:18 -0500 Subject: [PATCH] onepassword --- modules/programs/onepassword.nix | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/modules/programs/onepassword.nix b/modules/programs/onepassword.nix index d51dee4..fab64ad 100644 --- a/modules/programs/onepassword.nix +++ b/modules/programs/onepassword.nix @@ -1,5 +1,25 @@ { - flake.modules.homeManager.onepassword = { - # TODO: Port `_1password = true` behavior into an explicit Home Manager module. + flake.modules.homeManager.onepassword = { pkgs, lib, ... }: { + programs._1password-shell-plugins = { + # enable 1Password shell plugins for bash, zsh, and fish shell + enable = true; + # the specified packages as well as 1Password CLI will be + # automatically installed and configured to use shell plugins + # https://developer.1password.com/docs/cli/shell-plugins + plugins = with pkgs; [ gh ]; + }; + + home.file.".config/1Password/ssh/agent.toml".text = '' + # https://developer.1password.com/docs/ssh/agent/config + [[ssh-keys]] + vault = "Private" + ''; + programs.ssh = { + enable = true; + extraConfig = '' + Host * + IdentityAgent ${config.home.homeDirectory}/.1password/agent.sock + ''; + }; }; } \ No newline at end of file