feat(config): fish formatting, secrets, op

Signed-off-by: Ismo Vuorinen <ismo@ivuorinen.net>
This commit is contained in:
2025-04-19 04:11:14 +03:00
parent 196077bea9
commit 5321ad7bd7
5 changed files with 32 additions and 1 deletions

View File

@@ -8,6 +8,9 @@ indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[*.fish]
max_line_length = 80
[*.md]
max_line_length = 100

View File

@@ -8,13 +8,23 @@ test -e "$HOME/.config/fish/alias.fish" &&
test -e "$HOME/.config/fish/exports.fish" &&
source "$HOME/.config/fish/exports.fish"
test -e "$HOME/.config/fish/exports.secret.fish" &&
source "$HOME/.config/fish/exports.secret.fish"
test -e "$HOME/.dotfiles/config/fzf/key-bindings.fish" &&
source "$HOME/.dotfiles/config/fzf/key-bindings.fish"
if status is-interactive
# Commands to run in interactive shell
# 1Password plugins if op command is available
type -q op; and test -e "$HOME/.config/op/plugins.sh" &&
source "$HOME/.config/op/plugins.sh"
# version manager initializers
type -q rbenv; and source (rbenv init -|psub)
type -q pyenv; and source (pyenv init -|psub)
type -q pyenv; and source (pyenv virtualenv-init -)
type -q pyenv; and source (pyenv virtualenv-init -|psub)
type -q goenv; and source (goenv init -|psub)
# type -q fnm; and fnm env --use-on-cd --shell fish | source
type -q load_nvm; and load_nvm > /dev/stderr

2
config/op/plugins.sh Normal file
View File

@@ -0,0 +1,2 @@
export OP_PLUGIN_ALIASES_SOURCED=1
alias gh="op plugin run -- gh"

15
config/op/plugins/gh.json Normal file
View File

@@ -0,0 +1,15 @@
{
"account_id": "S5Z2DMNFKJEZBPCWRHRWC4DCGI",
"entrypoint": [
"gh"
],
"credentials": [
{
"plugin": "github",
"credential_type": "personal_access_token",
"usage_id": "personal_access_token",
"vault_id": "injcin7obv3jdet3r2u3kfihfy",
"item_id": "f6vinbnc6l7ngdzvlw66ayewlq"
}
]
}

View File

@@ -0,0 +1 @@
[{"account_id":"S5Z2DMNFKJEZBPCWRHRWC4DCGI","vault_id":"injcin7obv3jdet3r2u3kfihfy","item_id":"f6vinbnc6l7ngdzvlw66ayewlq"}]