1
0
Fork 0
This commit is contained in:
Luca Bilke 2024-11-13 19:55:24 +01:00
commit 97e2b95153
No known key found for this signature in database
GPG Key ID: C9E851809C1A5BDE
5 changed files with 37 additions and 4 deletions

0
.gitmodules vendored
View File

View File

@ -12,4 +12,3 @@ o.conceallevel = 0
g.lazyvim_php_lsp = "intelephense"
g.lazyvim_python_lsp = "basedpyright"
g.lazyvim_python_ruff = "ruff_lsp"

View File

@ -14,6 +14,16 @@ function xsi() {
}
function whed() {
local script
script=$(which "$1")
[ -e "$script" ] && $EDITOR $(which "$script")
}
function hosthost() {
local ip
ip=$(
host -t A "$1" | awk '{print $4}' ||
host -t AAAA "$1" | awk '{print $5}'
)
host "$ip" | awk '{print $5}' | sed 's/.$//'
}

View File

@ -33,7 +33,26 @@ zsnippet https://raw.githubusercontent.com/python-virtualenvwrapper/virtualenvwr
# NOTE: notify on long running commands
turbo
zload MichaelAquilina/zsh-auto-notify
AUTO_NOTIFY_IGNORE+=("lf" "lazygit" "elia")
AUTO_NOTIFY_IGNORE+=(
vim
nvim
less
more
man
tig
watch
git
commit
top
htop
ssh
nano
lf
lazygit
elia
gunicorn
kube
)
# NOTE: colorize help output
turbo
@ -60,6 +79,11 @@ zload "software/tralios-kube"
turbo as:"completion" from:"gitlab.tralios.de" pick:"_kube"
zload "software/tralios-kube"
# NOTE: fzf bindings and completions
turbo multisrc"shell/{completion,key-bindings}.zsh" \
id-as"junegunn/fzf_completions" pick"/dev/null"
zload junegunn/fzf
# NOTE: fzf completion menu
turbo
zload Aloxaf/fzf-tab

View File

@ -87,8 +87,8 @@ function lf-wrap() {
zle -N lf-wrap
function lazygit-wrap() {
[ ! -d "$(pwd)/.git" ] && [[ $(read -erk "?Not in a git repository. Create a new git repository? (y/n): ") =~ ^[Yy]$ ]] && git init
[ -d "$(pwd)/.git" ] && lazygit -p "$(pwd)"
[ ! -d "${PWD}/.git" ] && [[ $(read -erk "?Not in a git repository. Create a new git repository? (y/n): ") =~ ^[Yy]$ ]] && git init "$PWD"
[ -d "${PWD}/.git" ] && lazygit -p "$PWD"
reset_prompt
}
zle -N lazygit-wrap