From 66ba8b63abfe144e7c492202fbc4f5767b51d686 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois?= Date: Wed, 29 Oct 2025 17:17:36 +0100 Subject: [PATCH] Change layout 2 --- .../nvim/lua/config/options.lua | 11 ++++++++++ .../nvim/lua/plugins/barbar.lua | 1 + .../nvim/lua/plugins/comment.lua | 1 + .../nvim/lua/plugins/fzf-lua.lua | 1 + .../nvim/lua/plugins/lualine.lua | 2 ++ .../nvim/lua/plugins/nvim-tree.lua | 8 +++++++ .../nvim/lua/plugins/treesitter.lua | 20 +++++++++++++++++ .../nvim/lua/plugins/twilight.lua | 22 +++++++++++++++++++ .../nvim/lua/plugins/which-key.lua | 1 + 9 files changed, 67 insertions(+) create mode 100644 private_dot_config/nvim/lua/config/options.lua create mode 100644 private_dot_config/nvim/lua/plugins/barbar.lua create mode 100644 private_dot_config/nvim/lua/plugins/comment.lua create mode 100644 private_dot_config/nvim/lua/plugins/fzf-lua.lua create mode 100644 private_dot_config/nvim/lua/plugins/lualine.lua create mode 100644 private_dot_config/nvim/lua/plugins/nvim-tree.lua create mode 100644 private_dot_config/nvim/lua/plugins/treesitter.lua create mode 100644 private_dot_config/nvim/lua/plugins/twilight.lua create mode 100644 private_dot_config/nvim/lua/plugins/which-key.lua diff --git a/private_dot_config/nvim/lua/config/options.lua b/private_dot_config/nvim/lua/config/options.lua new file mode 100644 index 0000000..7743dba --- /dev/null +++ b/private_dot_config/nvim/lua/config/options.lua @@ -0,0 +1,11 @@ +local options = { + termguicolors = true, +} + +for k, v in pairs(options) do + vim.opt[k] = v +end + +vim.diagnostic.config({ + signs = false, +}) diff --git a/private_dot_config/nvim/lua/plugins/barbar.lua b/private_dot_config/nvim/lua/plugins/barbar.lua new file mode 100644 index 0000000..58b207b --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/barbar.lua @@ -0,0 +1 @@ +require("barbar").setup({}) diff --git a/private_dot_config/nvim/lua/plugins/comment.lua b/private_dot_config/nvim/lua/plugins/comment.lua new file mode 100644 index 0000000..5e62812 --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/comment.lua @@ -0,0 +1 @@ +require("Comment").setup({}) diff --git a/private_dot_config/nvim/lua/plugins/fzf-lua.lua b/private_dot_config/nvim/lua/plugins/fzf-lua.lua new file mode 100644 index 0000000..c543034 --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/fzf-lua.lua @@ -0,0 +1 @@ +require("fzf-lua").setup({}) diff --git a/private_dot_config/nvim/lua/plugins/lualine.lua b/private_dot_config/nvim/lua/plugins/lualine.lua new file mode 100644 index 0000000..4035781 --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/lualine.lua @@ -0,0 +1,2 @@ +local lualine = require('lualine') +lualine.setup({}) diff --git a/private_dot_config/nvim/lua/plugins/nvim-tree.lua b/private_dot_config/nvim/lua/plugins/nvim-tree.lua new file mode 100644 index 0000000..9e3bfc5 --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/nvim-tree.lua @@ -0,0 +1,8 @@ +-- disable netrw at the very start of your init.lua +vim.g.loaded_netrw = 1 +vim.g.loaded_netrwPlugin = 1 + +-- empty setup using defaults +require("nvim-tree").setup() + +vim.g.nvim_tree_respect_buf_cwd = 1 diff --git a/private_dot_config/nvim/lua/plugins/treesitter.lua b/private_dot_config/nvim/lua/plugins/treesitter.lua new file mode 100644 index 0000000..9cc569b --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/treesitter.lua @@ -0,0 +1,20 @@ +require("nvim-treesitter.configs").setup { + ensure_installed = { "bash", "c", "css", "cpp", "go", "html", "java", "javascript", "json", "lua", "markdown", "markdown_inline", "python", "rust", "tsx", "typescript", "yaml" }, + highlight = { + enable = true, + -- Setting this to true will run `:h syntax` and tree-sitter at the same time. + -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation). + -- Using this option may slow down your editor, and you may see some duplicate highlights. + -- Instead of true it can also be a list of languages + additional_vim_regex_highlighting = false, + }, + incremental_selection = { + enable = true, + keymaps = { + init_selection = "gnn", -- set to `false` to disable one of the mappings + node_incremental = "grn", + scope_incremental = "grc", + node_decremental = "grm", + }, + }, +} diff --git a/private_dot_config/nvim/lua/plugins/twilight.lua b/private_dot_config/nvim/lua/plugins/twilight.lua new file mode 100644 index 0000000..3d0bbab --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/twilight.lua @@ -0,0 +1,22 @@ +require("twilight").setup({ + + dimming = { + alpha = 0.3, -- amount of dimming + -- we try to get the foreground from the highlight groups or fallback color + color = { "Normal", "#ffffff" }, + term_bg = "#000000", -- if guibg=NONE, this will be used to calculate text color + inactive = true, -- when true, other windows will be fully dimmed (unless they contain the same buffer) + }, + context = 7, -- amount of lines we will try to show around the current line + treesitter = true, -- use treesitter when available for the filetype + -- treesitter is used to automatically expand the visible text, + -- but you can further control the types of nodes that should always be fully expanded + expand = { -- for treesitter, we we always try to expand to the top-most ancestor with these types + "function", + "method", + "table", + "if_statement", + }, + exclude = {}, -- exclude these filetypes + +}) diff --git a/private_dot_config/nvim/lua/plugins/which-key.lua b/private_dot_config/nvim/lua/plugins/which-key.lua new file mode 100644 index 0000000..fd2000b --- /dev/null +++ b/private_dot_config/nvim/lua/plugins/which-key.lua @@ -0,0 +1 @@ +local wk = require("which-key")