mirror of
https://github.com/ivuorinen/dotfiles.git
synced 2026-03-20 14:06:47 +00:00
feat(fish): add secrets.d for secret env vars
Add config/fish/secrets.d/ directory pattern to .gitignore while allowing *.example and README.md through. Add README and example file documenting the secrets convention. Source secrets.d/*.fish files in exports.fish so secret environment variables are loaded automatically.
This commit is contained in:
@@ -180,6 +180,15 @@ if test -f "$DOTFILES/hosts/$HOSTNAME/config/fish/exports-secret.fish"
|
||||
source "$DOTFILES/hosts/$HOSTNAME/config/fish/exports-secret.fish"
|
||||
end
|
||||
|
||||
# Source secret environment variables from secrets.d directory
|
||||
if test -d "$DOTFILES/config/fish/secrets.d"
|
||||
for secret_file in "$DOTFILES/config/fish/secrets.d"/*.fish
|
||||
if test -f "$secret_file"
|
||||
source "$secret_file"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
# Configure tide prompt
|
||||
set -gx tide_prompt_transient_enabled true
|
||||
set -gx tide_prompt_add_newline_before true
|
||||
|
||||
Reference in New Issue
Block a user