]> Freerunner's - dotfiles.git/commitdiff
kak: configure starship to use kak-lsp info
authorAndre Ramnitz <tux.rising@gmail.com>
Thu, 28 Nov 2024 17:42:25 +0000 (18:42 +0100)
committerAndre Ramnitz <tux.rising@gmail.com>
Thu, 28 Nov 2024 17:42:25 +0000 (18:42 +0100)
dot-config/kak/starship.toml

index 5a2db18f185fbdde43196b7e8e26740ac4133dd1..1602da511d9a39628991f4876d1bcf2717caf000 100644 (file)
@@ -1,8 +1,12 @@
 add_newline = false
 format = """\
+${custom.kaklsp_err}\
+${custom.kaklsp_warn}\
+${custom.kaklsp_hint}\
+${custom.kaklsp_code_actions}\
+${custom.kaklsp_progress}\
 ${custom.kakmode}\
 ${custom.kakcontext}\
-${custom.kaklsp_progress}\
 $git_branch\
 $git_commit\
 $git_state\
@@ -10,10 +14,6 @@ $git_status\
 $directory\
 ${custom.kakfile}\
 ${custom.kakfiletype}\
-${custom.kaklsp_err}\
-${custom.kaklsp_warn}\
-${custom.kaklsp_hint}\
-${custom.kaklsp_code_actions}\
 $package\
 ${custom.kaksession}\
 ${custom.kakbuflist}\
@@ -28,6 +28,46 @@ ${custom.kakposition}\
 [fill]
 symbol = ' '
 
+[custom.kaklsp_err]
+description = "Show errors number from kak-lsp if any"
+format = "[ %opt{lsp_diagnostic_error_count}]($style)"
+style = "fg:red bold bg:default"
+when = '[ -n "$kak_opt_lsp_diagnostic_error_count" -a "$kak_opt_lsp_diagnostic_error_count" -ne 0 ]'
+shell = ['sh']
+disabled = false
+
+[custom.kaklsp_warn]
+description = "Show warnings number from kak-lsp if any"
+format = "[  %opt{lsp_diagnostic_warning_count}]($style)"
+style = "fg:yellow bold bg:default"
+when = '[ -n "$kak_opt_lsp_diagnostic_warning_count" -a "$kak_opt_lsp_diagnostic_warning_count" -ne 0 ]'
+shell = ['sh']
+disabled = false
+
+[custom.kaklsp_hint]
+description = "Show hints number from kak-lsp if any"
+format = "[ ﯦ %opt{lsp_diagnostic_hint_count}]($style)"
+style = "fg:white bold bg:default"
+when = '[ -n "$kak_opt_lsp_diagnostic_hint_count" -a "$kak_opt_lsp_diagnostic_hint_count" -ne 0 ]'
+shell = ['sh']
+disabled = false
+
+[custom.kaklsp_code_actions]
+description = "Show lsp code actions if any"
+format = "[ %opt{lsp_modeline_code_actions} ]($style)"
+style = "fg:yellow bold bg:default"
+when = '[ -n "$kak_opt_lsp_modeline_code_actions" ]'
+shell = ['sh']
+disabled = false
+
+[custom.kaklsp_progress]
+description = "Show activity of kak-lsp if any"
+format = " [ ]($style)"
+style = "fg:bright-white bold bg:default"
+when = '[ -n "$kak_opt_lsp_modeline_progress" ]'
+shell = ['sh']
+disabled = false
+
 [git_branch]
 symbol = ""
 style = "fg:black bg:cyan bold"
@@ -112,46 +152,6 @@ when = ''
 shell = ['true']
 disabled = false
 
-[custom.kaklsp_err]
-description = "Show errors number from kak-lsp if any"
-format = "[ %opt{lsp_diagnostic_error_count}]($style)"
-style = "fg:red bold bg:black"
-when = '[ -n "$kak_opt_lsp_diagnostic_error_count" -a "$kak_opt_lsp_diagnostic_error_count" -ne 0 ]'
-shell = ['sh']
-disabled = true
-
-[custom.kaklsp_warn]
-description = "Show warnings number from kak-lsp if any"
-format = "[  %opt{lsp_diagnostic_warning_count}]($style)"
-style = "fg:yellow bold bg:black"
-when = '[ -n "$kak_opt_lsp_diagnostic_warning_count" -a "$kak_opt_lsp_diagnostic_warning_count" -ne 0 ]'
-shell = ['sh']
-disabled = true
-
-[custom.kaklsp_hint]
-description = "Show hints number from kak-lsp if any"
-format = "[ ﯦ %opt{lsp_diagnostic_hint_count}]($style)"
-style = "fg:white bold bg:black"
-when = '[ -n "$kak_opt_lsp_diagnostic_hint_count" -a "$kak_opt_lsp_diagnostic_hint_count" -ne 0 ]'
-shell = ['sh']
-disabled = true
-
-[custom.kaklsp_code_actions]
-description = "Show lsp code actions if any"
-format = "[ %opt{lsp_modeline_code_actions} ]($style)"
-style = "fg:yellow bold bg:black"
-when = '[ -n "$kak_opt_lsp_modeline_code_actions" ]'
-shell = ['sh']
-disabled = true
-
-[custom.kaklsp_progress]
-description = "Show activity of kak-lsp if any"
-format = " [ ]($style)"
-style = "fg:bright-white bold bg:black"
-when = '[ -n "$kak_opt_lsp_modeline_progress" ]'
-shell = ['sh']
-disabled = false
-
 [custom.kakbuflist]
 description = "Open buffers"
 format = '[](fg:white bg:bright-black)[ numbufs: $output ]($style)'