Compare commits

...

2 Commits

Author SHA1 Message Date
c3f1877067 Disable on type formatting of biome 2025-10-26 11:41:24 +01:00
e637e48a66 Fix prompt 2025-10-26 11:41:24 +01:00
2 changed files with 14 additions and 4 deletions

View File

@@ -6,7 +6,7 @@ zmodload zsh/stat
timer_preexec() {
timer=$EPOCHREALTIME
}
add-zsh-hook preexec timer_precmd
add-zsh-hook preexec timer_preexec
timer_precmd() {
if [ -z $timer ]; then
EXEC_TIME=""
@@ -39,7 +39,7 @@ kube_precmd() {
add-zsh-hook precmd kube_precmd
FILL="%F{#808080}${(l.$COLUMNS..·.)}%f"
FILL='%F{#808080}${(l.$COLUMNS..·.)}%f'
NEWLINE=$'\n'
WORKDIR='%B%F{blue}%~%b%f'
@@ -50,8 +50,8 @@ KUBE='%F{cyan}$KCTX${KNS:+/$KNS}%f'
PROMPT_SHLVL='%(?.%F{green}.%F{red})$(printf "%.0s" {1..$SHLVL})%f'
EXEC_TIME=""
EXIT_CODE=' %(?..%F{red}x${(j[|])pipestatus}%f)'
JOBS=' %F{cyan}%(1j.&%j.)%f'
EXIT_CODE='%(?.. %F{red}x${(j[|])pipestatus}%f)'
JOBS='%F{cyan}%(1j. &%j.)%f'
export PROMPT="${FILL}${NEWLINE}${WORKDIR}$RO$GIT $KUBE $PROMPT_SHLVL "
export RPROMPT="\${EXEC_TIME}${EXIT_CODE}${JOBS}"

View File

@@ -1,3 +1,13 @@
vim.api.nvim_create_autocmd('LspAttach', {
callback = function(args)
local client_id = args.data.client_id
local client = assert(vim.lsp.get_client_by_id(client_id))
if client.name == 'biome' then
vim.lsp.on_type_formatting.enable(false, { client_id = client_id })
end
end,
})
return {
-- Disable lunching from node_modules (no nix binary)
cmd = { "biome", "lsp-proxy" },