1
0
Fork 0

Compare commits

...

4 commits

7 changed files with 76 additions and 10 deletions

View file

@ -0,0 +1,36 @@
#!/bin/zsh
set -e
trap 'echo {} ; exit 0' ERR
add() {
gopass insert -f docker/$serverurl <<END
$secret
login: $login
END
}
case $1 in
get)
read serverurl || true
[[ -n $serverurl ]]
pass="$(gopass show --password docker/$serverurl)"
login="$(gopass show --password docker/$serverurl login)"
jo serverurl=dhub.corp.metrans.cz username=$login secret=$pass
exit ;;
store)
jq '.username+"|"+.secret+"|"+.serverurl' | IFS='|' read login secret serverurl
add
exit ;;
erase)
read serverurl
[[ -z $serverurl ]] && exit 1
gopass delete -f docker/$serverurl
exit ;;
list)
gopass ls --flat -s docker | jq -R | jq -s
exit ;;
esac
echo "get|list|store|erase"

View file

@ -0,0 +1,5 @@
{
"credHelpers": {
"dhub.corp.metrans.cz": "gopass"
}
}

View file

@ -131,7 +131,7 @@ end
---@param bg ?color ---@param bg ?color
---@param styles style[] ---@param styles style[]
function M:hl(group, fg, bg, styles, opts) function M:hl(group, fg, bg, styles, opts)
local o = opts or {}; local o = opts or { force = true }
if fg ~= nil if fg ~= nil
then then

View file

@ -1,6 +1,5 @@
local M = { local M = {
'gruvbox-community/gruvbox', 'gruvbox-community/gruvbox',
commit = 'f150aa7',
lazy = false, lazy = false,
priority = 999, priority = 999,
} }
@ -183,8 +182,31 @@ function M.config()
gr:hl('Strikethrough', nil, nil, { 'strikethrough' }, {}) gr:hl('Strikethrough', nil, nil, { 'strikethrough' }, {})
gr:hl('Underlined', nil, nil, { 'underline' }, {}) gr:hl('Underlined', nil, nil, { 'underline' }, {})
gr:hl('@text.uri', 'bright_blue', nil, {'underline'}, {}) gr:hl('@text.uri', 'bright_blue', nil, { 'underline' }, {})
gr:hl('@text.emphasis', nil, nil, {'italic'}, {}) gr:hl('@text.emphasis', nil, nil, { 'italic' }, {})
link('DiagnosticError', 'GruvboxRed')
link('DiagnosticWarn', 'GruvboxYellow')
link('DiagnosticInfo', 'GruvboxBlue')
link('DiagnosticHint', 'GruvboxAqua')
link('DiagnosticOk', 'GruvboxGreen')
link('RedrawDebugClear', 'GruvboxAqua')
link('RedrawDebugComposed', 'GruvboxGreen')
link('RedrawDebugRecompose', 'GruvboxRed')
link('DiagnosticFloatingError', 'DiagnosticError')
link('DiagnosticFloatingWarn', 'DiagnosticWarn')
link('DiagnosticFloatingInfo', 'DiagnosticInfo')
link('DiagnosticFloatingHint', 'DiagnosticHint')
link('DiagnosticFloatingOk', 'DiagnosticOk')
link('DiagnosticUnderlineOk', 'GruvboxAquaUnderline')
link('DiagnosticUnderlineError', 'GruvboxRedUnderline')
link('DiagnosticUnderlineWarn', 'GruvboxYellowUnderline')
link('DiagnosticUnderlineInfo', 'GruvboxBlueUnderline')
link('DiagnosticUnderlineHint', 'GruvboxAquaUnderline')
gr:hl('DiagnosticDeprecated', nil, nil, { 'strikethrough' }, { sp = 'red' })
gr:hl('NormalFloat', 'light0_hard', 'dark1', {}, nil)
-- gr:hl('GitSignsAddLine', nil, 'faded_green', {}) -- gr:hl('GitSignsAddLine', nil, 'faded_green', {})
-- vim.fn.sign_define('GitSignsAdd', { text = '│', texthl = 'GitSignsAdd', linehl = 'GitSignsAddLine', culhl='CursorLine' }) -- vim.fn.sign_define('GitSignsAdd', { text = '│', texthl = 'GitSignsAdd', linehl = 'GitSignsAddLine', culhl='CursorLine' })

View file

@ -190,11 +190,11 @@ local function on_attach(args) -- {{{
display_automatically = true, display_automatically = true,
silent = true, silent = true,
keymaps = { keymaps = {
next_signature = '<C-j>', next_signature = '<M-j>',
previous_signature = '<C-k>', previous_signature = '<M-k>',
next_parameter = '<C-l>', next_parameter = '<M-l>',
previous_parameter = '<C-h>', previous_parameter = '<M-h>',
close_signature = '', close_signature = '<M-y>',
}, },
}) })

View file

@ -44,3 +44,6 @@ alias podr='podman run -it --rm'
alias podrs='podman run -it --rm --entrypoint /bin/sh' alias podrs='podman run -it --rm --entrypoint /bin/sh'
alias kubegen='kubectl create --dry-run=client -oyaml' alias kubegen='kubectl create --dry-run=client -oyaml'
alias k=kubectl
alias kg='kubectl get'
alias kctx='kubectl config use-context'

View file

@ -110,7 +110,7 @@
# Blue current directory. # Blue current directory.
typeset -g POWERLEVEL9K_DIR_FOREGROUND=$blue typeset -g POWERLEVEL9K_DIR_FOREGROUND=$blue
typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|k9s|flux' typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|k9s|flux|trivy'
# Context format when root: user@host. The first part white, the rest grey. # Context format when root: user@host. The first part white, the rest grey.
typeset -g POWERLEVEL9K_CONTEXT_ROOT_TEMPLATE="%F{$white}%n%f%F{$grey}@%m%f" typeset -g POWERLEVEL9K_CONTEXT_ROOT_TEMPLATE="%F{$white}%n%f%F{$grey}@%m%f"