From b00a8e245d00ef12bae977196ea3fa62ae1b21ea Mon Sep 17 00:00:00 2001 From: Aoi Kurokawa <62386689+aoikurokawa@users.noreply.github.com> Date: Sun, 9 Feb 2025 10:55:08 +0900 Subject: [PATCH] Initial Setup (#1) * feat: install rust * feat: install rust --- init.lua | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 75 insertions(+), 7 deletions(-) diff --git a/init.lua b/init.lua index 4eae8e7d..24960daa 100644 --- a/init.lua +++ b/init.lua @@ -100,6 +100,7 @@ vim.g.have_nerd_font = false -- Make line numbers default vim.opt.number = true +vim.opt.relativenumber = true -- You can also add relative line numbers, to help with jumping. -- Experiment for yourself to see if you like it! -- vim.opt.relativenumber = true @@ -383,11 +384,14 @@ require('lazy').setup({ -- You can put your default mappings / updates / etc. in here -- All the info you're looking for is in `:help telescope.setup()` -- - -- defaults = { - -- mappings = { - -- i = { [''] = 'to_fuzzy_refine' }, - -- }, - -- }, + defaults = { + file_ignore_patterns = { + 'target', + }, + -- mappings = { + -- i = { [''] = 'to_fuzzy_refine' }, + -- }, + }, -- pickers = {} extensions = { ['ui-select'] = { @@ -438,6 +442,70 @@ require('lazy').setup({ end, }, + { + 'nvim-neo-tree/neo-tree.nvim', + branch = 'v3.x', + dependencies = { + 'nvim-lua/plenary.nvim', + 'nvim-tree/nvim-web-devicons', -- not strictly required, but recommended + 'MunifTanjim/nui.nvim', + -- "3rd/image.nvim", -- Optional image support in preview window: See `# Preview Mode` for more information + }, + config = function() + require('neo-tree').setup { + default_component_configs = { + container = { + enable_character_fade = true, + }, + indent = { + indent_size = 2, + padding = 1, -- extra padding on left hand side + -- indent guides + with_markers = true, + indent_marker = '│', + last_indent_marker = '└', + highlight = 'NeoTreeIndentMarker', + -- expander config, needed for nesting files + with_expanders = nil, -- if nil and file nesting is enabled, will enable expanders + expander_collapsed = '', + expander_expanded = '', + expander_highlight = 'NeoTreeExpander', + }, + icon = { + folder_closed = '►', + folder_open = '▼', + folder_empty = '-', + -- The next two settings are only a fallback, if you use nvim-web-devicons and configure default icons there + -- then these will never be used. + default = '*', + highlight = 'NeoTreeFileIcon', + }, + modified = { + symbol = '[+]', + highlight = 'NeoTreeModified', + }, + git_status = { + symbols = { + -- Change type + added = '', -- or "✚", but this is redundant info if you use git_status_colors on the name + modified = '', -- or "", but this is redundant info if you use git_status_colors on the name + deleted = '✖', -- this can only be used in the git_status source + renamed = '󰁕', -- this can only be used in the git_status source + -- Status type + untracked = '', + ignored = '', + unstaged = '󰄱', + staged = '', + conflict = '', + }, + }, + }, + } + + vim.cmd [[nnoremap \ :Neotree reveal]] + end, + }, + -- LSP Plugins { -- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins @@ -619,7 +687,7 @@ require('lazy').setup({ -- clangd = {}, -- gopls = {}, -- pyright = {}, - -- rust_analyzer = {}, + rust_analyzer = {}, -- ... etc. See `:help lspconfig-all` for a list of all the pre-configured LSPs -- -- Some languages (like typescript) have entire language plugins that can be useful: @@ -849,7 +917,7 @@ require('lazy').setup({ -- Load the colorscheme here. -- Like many other themes, this one has different styles, and you could load -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'. - vim.cmd.colorscheme 'tokyonight-night' + vim.cmd.colorscheme 'retrobox' -- You can configure highlights by doing something like: vim.cmd.hi 'Comment gui=none'