chore: better format on save for python
This commit is contained in:
parent
842cc8df30
commit
fc6b1e5fe5
5 changed files with 34 additions and 26 deletions
|
@ -30,6 +30,7 @@
|
||||||
"vim-fugitive": { "branch": "master", "commit": "d4877e54cef67f5af4f950935b1ade19ed6b7370" },
|
"vim-fugitive": { "branch": "master", "commit": "d4877e54cef67f5af4f950935b1ade19ed6b7370" },
|
||||||
"vim-kitty-navigator": { "branch": "master", "commit": "20abf8613aa228a5def1ae02cd9da0f2d210352a" },
|
"vim-kitty-navigator": { "branch": "master", "commit": "20abf8613aa228a5def1ae02cd9da0f2d210352a" },
|
||||||
"vim-rhubarb": { "branch": "master", "commit": "ee69335de176d9325267b0fd2597a22901d927b1" },
|
"vim-rhubarb": { "branch": "master", "commit": "ee69335de176d9325267b0fd2597a22901d927b1" },
|
||||||
|
"vim-xcode": { "branch": "main", "commit": "2adc409bd7bb58499218f4f487c825e55306e46d" },
|
||||||
"volt": { "branch": "main", "commit": "43f72b49037c191eb3cfe26ba7a5574b4bfce226" },
|
"volt": { "branch": "main", "commit": "43f72b49037c191eb3cfe26ba7a5574b4bfce226" },
|
||||||
"which-key.nvim": { "branch": "main", "commit": "8badb359f7ab8711e2575ef75dfe6fbbd87e4821" },
|
"which-key.nvim": { "branch": "main", "commit": "8badb359f7ab8711e2575ef75dfe6fbbd87e4821" },
|
||||||
"zen-mode.nvim": { "branch": "main", "commit": "29b292bdc58b76a6c8f294c961a8bf92c5a6ebd6" }
|
"zen-mode.nvim": { "branch": "main", "commit": "29b292bdc58b76a6c8f294c961a8bf92c5a6ebd6" }
|
||||||
|
|
|
@ -3,7 +3,7 @@ local options = {
|
||||||
lua = { "stylua" },
|
lua = { "stylua" },
|
||||||
css = { "prettier" },
|
css = { "prettier" },
|
||||||
html = { "prettier" },
|
html = { "prettier" },
|
||||||
python = { "ruff_format" },
|
python = { "ruff_format", "ruff_fix", "ruff_organize_imports" },
|
||||||
go = { "goimports", "gofmt" },
|
go = { "goimports", "gofmt" },
|
||||||
json = { "jq" },
|
json = { "jq" },
|
||||||
},
|
},
|
||||||
|
|
|
@ -13,8 +13,8 @@ local servers = {
|
||||||
},
|
},
|
||||||
ruff = {
|
ruff = {
|
||||||
lint = {
|
lint = {
|
||||||
run = "onSave"
|
run = "onSave",
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
zls = {},
|
zls = {},
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@ local servers = {
|
||||||
ts_ls = {
|
ts_ls = {
|
||||||
settings = {
|
settings = {
|
||||||
completions = {
|
completions = {
|
||||||
completeFunctionCalls = true
|
completeFunctionCalls = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -51,4 +51,3 @@ for name, opts in pairs(servers) do
|
||||||
|
|
||||||
require("lspconfig")[name].setup(opts)
|
require("lspconfig")[name].setup(opts)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
require "nvchad.options"
|
require("nvchad.options")
|
||||||
|
|
||||||
-- add yours here!
|
-- add yours here!
|
||||||
|
|
||||||
-- local o = vim.o
|
local o = vim.o
|
||||||
-- o.cursorlineopt ='both' -- to enable cursorline!
|
o.cursorlineopt = "both" -- to enable cursorline!
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
return {
|
return {
|
||||||
{
|
{
|
||||||
"stevearc/conform.nvim",
|
"stevearc/conform.nvim",
|
||||||
event = 'BufWritePre', -- uncomment for format on save
|
event = "BufWritePre", -- uncomment for format on save
|
||||||
opts = require "configs.conform",
|
opts = require "configs.conform",
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -17,9 +17,14 @@ return {
|
||||||
"nvim-treesitter/nvim-treesitter",
|
"nvim-treesitter/nvim-treesitter",
|
||||||
opts = {
|
opts = {
|
||||||
ensure_installed = {
|
ensure_installed = {
|
||||||
"vim", "lua", "vimdoc",
|
"vim",
|
||||||
"html", "css", "python",
|
"lua",
|
||||||
"typescript", "go"
|
"vimdoc",
|
||||||
|
"html",
|
||||||
|
"css",
|
||||||
|
"python",
|
||||||
|
"typescript",
|
||||||
|
"go",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -28,13 +33,16 @@ return {
|
||||||
cmd = { "Git", "G", "Gdiffsplit", "Gvdiffsplit", "Gwrite", "Gread", "Ggrep", "GMove", "GDelete", "GBrowse" },
|
cmd = { "Git", "G", "Gdiffsplit", "Gvdiffsplit", "Gwrite", "Gread", "Ggrep", "GMove", "GDelete", "GBrowse" },
|
||||||
keys = {
|
keys = {
|
||||||
{ "<leader>gs", "<cmd>vertical Git<cr>" },
|
{ "<leader>gs", "<cmd>vertical Git<cr>" },
|
||||||
desc = "Open Fugitive"
|
desc = "Open Fugitive",
|
||||||
},
|
},
|
||||||
opts = {
|
opts = {
|
||||||
enabled = true
|
enabled = true,
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{ "tpope/vim-rhubarb", opts = { enabled = true, lazy = false } },
|
dependencies = {
|
||||||
|
"tpope/vim-rhubarb",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{ "tpope/vim-rhubarb", opts = { enabled = true } },
|
||||||
{
|
{
|
||||||
"folke/zen-mode.nvim",
|
"folke/zen-mode.nvim",
|
||||||
cmd = "ZenMode",
|
cmd = "ZenMode",
|
||||||
|
@ -125,8 +133,8 @@ return {
|
||||||
enabled = true,
|
enabled = true,
|
||||||
lazy = false,
|
lazy = false,
|
||||||
build = {
|
build = {
|
||||||
"cp ./*.py ~/.config/kitty/"
|
"cp ./*.py ~/.config/kitty/",
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"gfontenot/vim-xcode",
|
"gfontenot/vim-xcode",
|
||||||
|
|
Loading…
Add table
Reference in a new issue