File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 88 pkgs . runCommand "op-plugin-list" { }
99 # 1Password CLI tries to create the config directory automatically, so set a temp XDG_CONFIG_HOME
1010 # since we don't actually need it for this
11- "mkdir $out && XDG_CONFIG_HOME=$out ${ pkgs . _1password } /bin/op plugin list | cut -d ' ' -f1 | tail -n +2 > $out/plugins.txt"
11+ "mkdir $out && XDG_CONFIG_HOME=$out ${ cfg . package } /bin/op plugin list | cut -d ' ' -f1 | tail -n +2 > $out/plugins.txt"
1212 } /plugins.txt" ) ;
1313 getExeName = package :
1414 # NOTE: SAFETY: This is okay because the `packages` list is also referred
2121 options = {
2222 programs . _1password-shell-plugins = {
2323 enable = mkEnableOption "1Password Shell Plugins" ;
24+
25+ package = lib . mkPackageOption pkgs "_1password" { } ;
26+
2427 plugins = mkOption {
2528 type = types . listOf types . package ;
2629 default = [ ] ;
6265 name = package ;
6366 value = "op plugin run -- ${ package } " ;
6467 } ) pkg-exe-names ) ;
65- packages = [ pkgs . _1password ] ++ cfg . plugins ;
68+ packages = [ cfg . package ] ++ cfg . plugins ;
6669 in mkIf cfg . enable ( mkMerge [
6770 ( {
6871 programs = {
You can’t perform that action at this time.
0 commit comments