starship: add git status and small vim fix

This commit is contained in:
Julien Rabier 2023-05-04 10:07:18 +02:00
parent e6309e34cb
commit 05611371d5
2 changed files with 15 additions and 0 deletions

View File

@ -3,3 +3,13 @@
-- Add any additional keymaps here
vim.keymap.set("n", ",c", "<esc>2GddOTo: contact@sysnove.fr<esc>jddOCc: <esc>")
vim.keymap.set("n", "<leader>b", ":!bash gen.sh<cr><cr>")
-- function to toggle "normal" diagnostics or lsp-lines diagnostics.
local function toggle_diagnostics()
local diagnostics_on = require("lsp_lines").toggle()
if diagnostics_on then
vim.diagnostic.config({ virtual_text = false })
else
vim.diagnostic.config({ virtual_text = { spacing = 4, prefix = "" } })
end
end
vim.keymap.set("n", "<Leader>ui", toggle_diagnostics, { desc = "Toggle [i]nline diagnostic type" })

View File

@ -1,2 +1,7 @@
[time]
disabled = false
[git_status]
ahead = '⇡${count}'
diverged = '⇕⇡${ahead_count}⇣${behind_count}'
behind = '⇣${count}'