dotfiles/home/dot_config/fish/config.fish.tmpl
Felipe M. 9c2531e294
Configure the SOPS age item reference
The homelab SOPS tools need the 1Password item reference in each fish session. The private age key stays in 1Password and is read only when a tool needs it.

Verified with chezmoi verify, rendered-source comparison, fish syntax checks, and git diff --check.
2026-09-02 18:38:11 +02:00

23 lines
841 B
Go Template

if status is-interactive
# Commands to run in interactive sessions can go here
end
# Claude local installation
fish_add_path ~/.claude/local
# Local binaries (dotfiles)
fish_add_path ~/.local/bin
# The homelab SOPS helper reads this 1Password item only when it needs the age
# private key. The key itself does not go into the environment or this source.
set --export OP_SOPS_AGE_ITEM "op://Infra/i5pclbnt5dm2hoj4wlch3pe6u4/password"
# Go binaries. Resolved at apply time so each machine gets its own GOPATH/GOBIN;
# ~/go/bin is the upstream default for machines without Go installed yet.
{{ if lookPath "go" -}}
{{ $gobin := output "go" "env" "GOBIN" | trim -}}
{{ if eq $gobin "" }}{{ $gobin = printf "%s/bin" (output "go" "env" "GOPATH" | trim) }}{{ end -}}
fish_add_path {{ $gobin }}
{{ else -}}
fish_add_path ~/go/bin
{{ end -}}