From 81e57446dedf7199c49df78a030cddec4d56cd15 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Mar 2025 16:19:46 +0900 Subject: [PATCH 01/16] fix(julials): write using at the top level --- bin/neovim/update_julials.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/neovim/update_julials.jl b/bin/neovim/update_julials.jl index cfdc4cf..082a2b9 100644 --- a/bin/neovim/update_julials.jl +++ b/bin/neovim/update_julials.jl @@ -1,8 +1,9 @@ #!/usr/bin/julia project_path = joinpath(homedir(), ".julia", "environments", "nvim-lspconfig") +using Pkg +using PackageCompiler; cd(project_path) do @info "now at " pwd() - using Pkg Pkg.activate(".") Pkg.update() compile_traces = Iterators.filter(eachline("tracecompile.jl")) do line @@ -11,7 +12,6 @@ cd(project_path) do end |> join read("precompile_exec_head.jl", String) * compile_traces |> (b -> write("precompile_exec.jl", b)) @info "compiling sysimage..." - using PackageCompiler; create_sysimage(["LanguageServer"], sysimage_path = "sys-ls.so", precompile_execution_file = ["precompile_exec.jl"])' @info "post precompile" run(`julia --project=. -J sys-ls.so -e 'using Pkg; Pkg.precompile()'`) From 54a9cdfca2dbbe65860e8b5c1f1d8a87f0356a87 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Mar 2025 16:21:56 +0900 Subject: [PATCH 02/16] new(pwsh): add YAZI_FILE_ONE env var to detect file --- dotfiles/pwsh/powershell_profile.ps1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dotfiles/pwsh/powershell_profile.ps1 b/dotfiles/pwsh/powershell_profile.ps1 index 096a09a..fa8f8ae 100644 --- a/dotfiles/pwsh/powershell_profile.ps1 +++ b/dotfiles/pwsh/powershell_profile.ps1 @@ -164,6 +164,8 @@ $env:LESS = "-i -M -R -S -W -z-4 -x4" $env:JL_SYSIMG_PATH = "$HOME/dotfiles/julia-sysimages" $env:JL_SYSIMG_PLT = "$HOME/dotfiles/julia-sysimages/sys-plotsmakie.so" $env:JL_SYSIMG_ETC = "$HOME/dotfiles/julia-sysimages/sys-etc.so" +# yazi file +$env:YAZI_FILE_ONE = "C:\Program Files\Git\usr\bin\file.exe" # ============================================================== From 279da20b9788543fd7b30a55e713e8e2d5da11a5 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Mar 2025 21:31:35 +0900 Subject: [PATCH 03/16] remove duplicated config --- dotfiles/neovim/init.lua | 8 -------- 1 file changed, 8 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 1e27109..f117e5b 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -125,14 +125,6 @@ require('lazy').setup({ }, { "andymass/vim-matchup", - config = function() - vim.g.matchup_matchparen_offscreen = { method = "popup" } - require 'nvim-treesitter.configs'.setup { - matchup = { - enable = true, - } - } - end, }, { 'nvim-telescope/telescope.nvim', From 8bf5f0adcf16eb6cc319fed46da94fa0d546ab1d Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Mar 2025 21:32:32 +0900 Subject: [PATCH 04/16] update: fix treesitter config in orgmode setup --- dotfiles/neovim/init.lua | 8 -------- 1 file changed, 8 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index f117e5b..9bf8253 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -226,14 +226,6 @@ require('lazy').setup({ }, -- event = 'VeryLazy', -- doesn't work with existing comp and treesitter config = function() - -- Setup treesitter - require('nvim-treesitter.configs').setup({ - highlight = { - enable = true, - additional_vim_regex_highlighting = { 'org' }, - }, - ensure_installed = { 'org' }, - }) -- Setup orgmode require('orgmode').setup({ From 47b4fc83bc62f212c082ad044ecd873fa46d7b2b Mon Sep 17 00:00:00 2001 From: qwjyh Date: Tue, 4 Mar 2025 23:29:16 +0900 Subject: [PATCH 05/16] remove unnecessary lines (unused lspconfig) --- dotfiles/neovim/init.lua | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 9bf8253..b813e64 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -734,17 +734,6 @@ lspconfig.powershell_es.setup { bundle_path = vim.fn.has('win32') == 1 and win_pwsh_es_path or arch_pwsh_es_path, capabilities = capabilities, } --- ccls --- -- csharp --- lspconfig.omnisharp.setup { --- cmd = {'omnisharp'}, --- } - --- lspconfig.typst_lsp.setup { --- on_attach = on_attach, --- capabilities = capabilities, --- single_file_support = true, --- } lspconfig.tinymist.setup { on_attach = on_attach, From 5f6e107b41c08b5faac368f2c09ccef7dd14816e Mon Sep 17 00:00:00 2001 From: qwjyh Date: Fri, 14 Mar 2025 04:34:52 +0900 Subject: [PATCH 06/16] refactor(nvim): separate lsp on_attach func to module to share the same config between general lspconfig & lean config --- bin/install.ps1 | 1 + bin/install.sh | 1 + dotfiles/neovim/init.lua | 50 ++---------------------------- dotfiles/neovim/lua/lsp_config.lua | 37 ++++++++++++++++++++++ 4 files changed, 41 insertions(+), 48 deletions(-) create mode 100644 dotfiles/neovim/lua/lsp_config.lua diff --git a/bin/install.ps1 b/bin/install.ps1 index be17a41..581923d 100644 --- a/bin/install.ps1 +++ b/bin/install.ps1 @@ -54,6 +54,7 @@ scoop import .\bin\windows\scoop_apps\scoop_minimal_apps.json New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\init.lua -Target (Resolve-Path .\dotfiles\neovim\init.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\lualine_setup.lua -Target (Resolve-Path .\dotfiles\neovim\lua\lualine_setup.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\term_powershell.lua -Target (Resolve-Path .\dotfiles\neovim\lua\term_powershell.lua) -Force +New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\lsp_config.lua -Target (Resolve-Path .\dotfiles\neovim\lua\lsp_config.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\lspconfig\server_configurations\satysfi_ls.lua -Target (Resolve-Path .\dotfiles\neovim\lua\lspconfig\server_configurations\satysfi_ls.lua) -Force mkdir $env:LOCALAPPDATA\nvim\after\ftplugin New-Item -ItemType SymbolicLink -Path $env:LOCALAPPDATA\nvim\after\ftplugin\satysfi.lua -Target (Resolve-Path .\dotfiles\neovim\after\ftplugin\satysfi.lua) diff --git a/bin/install.sh b/bin/install.sh index 90626e9..3e649f6 100755 --- a/bin/install.sh +++ b/bin/install.sh @@ -25,6 +25,7 @@ ln -sf $(pwd)/dotfiles/neovim/init.lua ~/.config/nvim/init.lua mkdir -p ~/.config/nvim/lua ln -sf $(pwd)/dotfiles/neovim/lua/lualine_setup.lua ~/.config/nvim/lua/lualine_setup.lua ln -sf $(pwd)/dotfiles/neovim/lua/term_powershell.lua ~/.config/nvim/lua/term_powershell.lua +ln -sf $(pwd)/dotfiles/neovim/lua/lsp_config.lua ~/.config/nvim/lua/lsp_config.lua ln -sf $(pwd)/dotfiles/neovim/lua/pluto_nvim.lua ~/.config/nvim/lua/pluto_nvim.lua mkdir -p ~/.config/nvim/lua/lspconfig/server_configurations ln -sf $(pwd)/dotfiles/neovim/lua/lspconfig/server_configurations/satysfi_ls.lua ~/.config/nvim/lua/lspconfig/server_configurations/satysfi_ls.lua diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index b813e64..4d6599f 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -188,29 +188,7 @@ require('lazy').setup({ -- see Julian/lean.nvim readme opts = { lsp = { - on_attach = function(client, bufnr) - -- Enable completion triggered by - --vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc') - - -- Mappings - -- See `:help vim.lsp.*` for documentation on any of the below function - local bufopts = { noremap = true, silent = true, buffer = bufnr } - vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, bufopts) - vim.keymap.set('n', 'gd', vim.lsp.buf.definition, bufopts) - vim.keymap.set('n', 'K', vim.lsp.buf.hover, bufopts) - vim.keymap.set('n', 'g1', vim.lsp.buf.implementation, bufopts) - vim.keymap.set('n', '', vim.lsp.buf.signature_help, bufopts) - vim.keymap.set('n', 'wa', vim.lsp.buf.add_workspace_folder, bufopts) - vim.keymap.set('n', 'wr', vim.lsp.buf.remove_workspace_folder, bufopts) - vim.keymap.set('n', 'wl', function() - print(vim.inspect(vim.lsp.buf.list_workspace_folders())) - end, bufopts) - vim.keymap.set('n', 'D', vim.lsp.buf.type_definition, bufopts) - vim.keymap.set('n', 'rn', vim.lsp.buf.rename, bufopts) - vim.keymap.set('n', 'ca', vim.lsp.buf.code_action, bufopts) - vim.keymap.set('n', 'grf', vim.lsp.buf.references, bufopts) - vim.keymap.set('n', 'f', function() vim.lsp.buf.format { async = true } end, bufopts) - end, + on_attach = require("lsp_config").on_attach, }, mappings = true, }, @@ -226,7 +204,6 @@ require('lazy').setup({ }, -- event = 'VeryLazy', -- doesn't work with existing comp and treesitter config = function() - -- Setup orgmode require('orgmode').setup({ org_agenda_files = '~/orgfiles/**/*', @@ -608,30 +585,7 @@ vim.keymap.set('n', 'q', vim.diagnostic.setloclist, opts) -- Use an on_attach function to only map the following keys -- after the language server attaches to the current buffer -local on_attach = function(client, bufnr) - -- Enable completion triggered by - --vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc') - - -- Mappings - -- See `:help vim.lsp.*` for documentation on any of the below function - local bufopts = { noremap = true, silent = true, buffer = bufnr } - vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, bufopts) - vim.keymap.set('n', 'gd', vim.lsp.buf.definition, bufopts) - vim.keymap.set('n', 'gT', vim.lsp.buf.type_definition, bufopts) - vim.keymap.set('n', 'K', vim.lsp.buf.hover, bufopts) - vim.keymap.set('n', 'g1', vim.lsp.buf.implementation, bufopts) - vim.keymap.set('n', '', vim.lsp.buf.signature_help, bufopts) - vim.keymap.set('n', 'wa', vim.lsp.buf.add_workspace_folder, bufopts) - vim.keymap.set('n', 'wr', vim.lsp.buf.remove_workspace_folder, bufopts) - vim.keymap.set('n', 'wl', function() - print(vim.inspect(vim.lsp.buf.list_workspace_folders())) - end, bufopts) - vim.keymap.set('n', 'D', vim.lsp.buf.type_definition, bufopts) - vim.keymap.set('n', 'rn', vim.lsp.buf.rename, bufopts) - vim.keymap.set('n', 'ca', vim.lsp.buf.code_action, bufopts) - vim.keymap.set('n', 'grf', vim.lsp.buf.references, bufopts) - vim.keymap.set('n', 'f', function() vim.lsp.buf.format { async = true } end, bufopts) -end +local on_attach = require("lsp_config").on_attach -- cmp_nvim_lsp supports additional LSP completion capabilities local capabilities = require("cmp_nvim_lsp").default_capabilities() diff --git a/dotfiles/neovim/lua/lsp_config.lua b/dotfiles/neovim/lua/lsp_config.lua new file mode 100644 index 0000000..1f714f1 --- /dev/null +++ b/dotfiles/neovim/lua/lsp_config.lua @@ -0,0 +1,37 @@ +local M = {} + +---Add `desc` to bufopts table. +---@param bufopts vim.keymap.set.Opts +---@param desc string +---@return vim.keymap.set.Opts +local function with_desc(bufopts, desc) + return vim.tbl_extend("error", bufopts, { desc = desc }) +end + +M.on_attach = function(client, bufnr) + -- Enable completion triggered by + --vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc') + + -- Mappings + -- See `:help vim.lsp.*` for documentation on any of the below function + local bufopts = { noremap = true, silent = true, buffer = bufnr } + vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, with_desc(bufopts, "goto declaration")) + vim.keymap.set('n', 'gd', vim.lsp.buf.definition, with_desc(bufopts, "goto definition")) + vim.keymap.set('n', 'gT', vim.lsp.buf.type_definition, with_desc(bufopts, "goto type definition")) + vim.keymap.set('n', 'K', vim.lsp.buf.hover, with_desc(bufopts, "lsp hover")) + vim.keymap.set('n', 'g1', vim.lsp.buf.implementation, with_desc(bufopts, "lsp implementations")) + vim.keymap.set('n', '', vim.lsp.buf.signature_help, with_desc(bufopts, "lsp signature help")) + vim.keymap.set('n', 'wa', vim.lsp.buf.add_workspace_folder, with_desc(bufopts, "lsp add_workspace_folder")) + vim.keymap.set('n', 'wr', vim.lsp.buf.remove_workspace_folder, + with_desc(bufopts, "lsp remove_workspace_folder")) + vim.keymap.set('n', 'wl', function() + print(vim.inspect(vim.lsp.buf.list_workspace_folders())) + end, with_desc(bufopts, "lsp list_workspace_folders")) + vim.keymap.set('n', 'D', vim.lsp.buf.type_definition, with_desc(bufopts, "lsp type definition")) + vim.keymap.set('n', 'rn', vim.lsp.buf.rename, with_desc(bufopts, "lsp rename")) + vim.keymap.set('n', 'ca', vim.lsp.buf.code_action, with_desc(bufopts, "lsp code_action")) + vim.keymap.set('n', 'grf', vim.lsp.buf.references, with_desc(bufopts, "lsp references")) + vim.keymap.set('n', 'f', function() vim.lsp.buf.format { async = true } end, with_desc(bufopts, "lsp format")) +end + +return M From eb60fcf0b66275d33b38f8bb73f17fef40a11641 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Tue, 18 Mar 2025 02:51:14 +0900 Subject: [PATCH 07/16] update(nvim): update keyremap func annot --- dotfiles/neovim/init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 4d6599f..6645d65 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -423,7 +423,7 @@ require('gitsigns').setup { ---@param mode string|string[] ---@param l string ---@param r any - ---@param opts table? + ---@param opts vim.keymap.set.Opts? local function map(mode, l, r, opts) opts = opts or {} opts.buffer = bufnr From dc3cfa603510e9317d6cba8c183ff9f3b8547053 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Tue, 25 Mar 2025 16:19:36 +0900 Subject: [PATCH 08/16] update(nvim): remove typst_lsp --- dotfiles/neovim/init.lua | 6 ------ 1 file changed, 6 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 1e27109..c985132 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -756,12 +756,6 @@ lspconfig.powershell_es.setup { -- cmd = {'omnisharp'}, -- } --- lspconfig.typst_lsp.setup { --- on_attach = on_attach, --- capabilities = capabilities, --- single_file_support = true, --- } - lspconfig.tinymist.setup { on_attach = on_attach, capabilities = capabilities, From 42d3439dbe254fa4c64e3109b62922469dca2ec7 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Tue, 25 Mar 2025 16:20:14 +0900 Subject: [PATCH 09/16] new(xremap): map Capslock to shift_l since my laptop's shift_l is broken --- extra_configs/xremap_config.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/extra_configs/xremap_config.yml b/extra_configs/xremap_config.yml index db85d9e..15ba982 100644 --- a/extra_configs/xremap_config.yml +++ b/extra_configs/xremap_config.yml @@ -16,6 +16,9 @@ modmap: Win_L: held: Win_L alone: Key_Chat + - name: left shift + remap: + Capslock: shift_l keymap: - name: ZenkakuHankaku to Esc remap: From 88aabfd88f471dd0b34f88a8c26cb3b5ea939f0d Mon Sep 17 00:00:00 2001 From: qwjyh Date: Tue, 25 Mar 2025 16:21:27 +0900 Subject: [PATCH 10/16] new(nvim): add JETLS config https://github.com/aviatesk/JETLS.jl --- dotfiles/neovim/init.lua | 9 +++++ .../lspconfig/server_configurations/jetls.lua | 36 +++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 dotfiles/neovim/lua/lspconfig/server_configurations/jetls.lua diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index c985132..f3d4224 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -731,6 +731,15 @@ lspconfig.julials.setup { run(server) ]] } } +-- JETLS +require 'lspconfig.server_configurations.jetls' +lspconfig.jetls.setup { + on_attach = function(client, bufnr) + on_attach(client, bufnr) + vim.lsp.inlay_hint.enable(true, { bufnr = bufnr }) + end, + capabilities = capabilities, +} -- SATySFi require 'lspconfig.server_configurations.satysfi_ls' lspconfig.satysfi_ls.setup { diff --git a/dotfiles/neovim/lua/lspconfig/server_configurations/jetls.lua b/dotfiles/neovim/lua/lspconfig/server_configurations/jetls.lua new file mode 100644 index 0000000..fb6b304 --- /dev/null +++ b/dotfiles/neovim/lua/lspconfig/server_configurations/jetls.lua @@ -0,0 +1,36 @@ +local configs = require 'lspconfig.configs' +local util = require 'lspconfig.util' + +local root_files = { 'Project.toml', 'JuliaProject.toml' } + +configs.jetls = { + default_config = { + cmd = { + 'julia', + '--project=' .. vim.env.HOME .. '/work/julia/JETLS.jl', + '--startup-file=no', + '--history-file=no', + '-e', + [[ + using JETLS + runserver(stdin, stdout) + ]] + }, + filetypes = { 'julia' }, + root_dir = function(fname) + return util.root_pattern(unpack(root_files))(fname) + or vim.fs.dirname(vim.fs.find('.git', { path = fname, upward = true, })[1]) + end, + single_file_support = true, + }, + commands = { + -- JuliaActivateEnv = { + -- activate_env + -- } + }, + docs = { + description = [[ +JETLS: https://github.com/aviatesk/JETLS.jl + ]], + }, +} From 0e68dd36508d8129399627571a54d0c9e3562f89 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:20:51 +0900 Subject: [PATCH 11/16] refactor(nvim): remove treesitter setup from orgmode setup it is no longer in the example (maybe conflicted?) --- dotfiles/neovim/init.lua | 9 --------- 1 file changed, 9 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index f3d4224..a33a0db 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -234,15 +234,6 @@ require('lazy').setup({ }, -- event = 'VeryLazy', -- doesn't work with existing comp and treesitter config = function() - -- Setup treesitter - require('nvim-treesitter.configs').setup({ - highlight = { - enable = true, - additional_vim_regex_highlighting = { 'org' }, - }, - ensure_installed = { 'org' }, - }) - -- Setup orgmode require('orgmode').setup({ org_agenda_files = '~/orgfiles/**/*', From bc623a70d9cc4294732d7cfb4cb58985888a39f7 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:21:46 +0900 Subject: [PATCH 12/16] update(nvim): modify typst-preview settings (use external tinymist, enable debug) --- dotfiles/neovim/init.lua | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index a33a0db..d0cb50b 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -282,8 +282,9 @@ require('lazy').setup({ end, config = function() require 'typst-preview'.setup { - -- Setting this true will enable printing debug information with print() - debug = false, + -- Setting this true will enable logging debug information to + -- `vim.fn.stdpath 'data' .. '/typst-preview/log.txt'` + debug = true, -- Custom format string to open the output link provided with %s -- Example: open_cmd = 'firefox %s -P typst-preview --class typst-preview' @@ -305,8 +306,8 @@ require('lazy').setup({ -- Warning: Be aware that your version might be older than the one -- required. dependencies_bin = { - ['tinymist'] = nil, - ['websocat'] = nil + ['tinymist'] = 'tinymist', + ['websocat'] = nil, }, -- A list of extra arguments (or nil) to be passed to previewer. From 9d1015a48dacb52741090fc4c7982e9f233dc1c9 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:22:49 +0900 Subject: [PATCH 13/16] update(nvim): add lsp settings for nixd, nil_ls, verible, svls --- dotfiles/neovim/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index d0cb50b..4f487da 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -786,7 +786,8 @@ lspconfig.rust_analyzer.setup { } local lss = { "pyright", "texlab", --[[ "ccls", ]] "clangd", "ts_ls", --[["tailwindcss"]] "hls", "cmake", - "csharp_ls", "html", "r_language_server", "cssls", "jsonls", "sqls", "vhdl_ls", "ruff", "lemminx" } + "csharp_ls", "html", "r_language_server", "cssls", "jsonls", "sqls", "vhdl_ls", "ruff", "lemminx", "nixd", "nil_ls", + "verible", "svls" } for _, ls in pairs(lss) do lspconfig[ls].setup { on_attach = on_attach, From b4bf8d3ac24bfbfc6910ab66fb471746b801dbed Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:23:31 +0900 Subject: [PATCH 14/16] update(nvim): enable inlay_hint for julials --- dotfiles/neovim/init.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 4f487da..1827201 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -680,7 +680,10 @@ if julials_so_file then -- if sysimage doesn't exist, julials_so_file == nil end -- main lspconfig.julials.setup { - on_attach = on_attach, + on_attach = function(client, bufnr) + on_attach(client, bufnr) + vim.lsp.inlay_hint.enable(true, { bufnr = bufnr }) + end, capabilities = capabilities, cmd = { "julia", "--startup-file=no", "--history-file=no", -- julials_so_option[1], julials_so_option[2], From 650d31faec8a9ac45d78c655ff7620973c2e4353 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:24:25 +0900 Subject: [PATCH 15/16] change colorscheme (catppuccin-latte to catppuccin-mocha) coming back to dark theme... --- dotfiles/bat/config | 2 +- dotfiles/neovim/init.lua | 3 ++- dotfiles/startup_linux.jl | 2 +- dotfiles/wezterm/wezterm.lua | 8 +++++--- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/dotfiles/bat/config b/dotfiles/bat/config index 7042fd2..a717d92 100644 --- a/dotfiles/bat/config +++ b/dotfiles/bat/config @@ -1,4 +1,4 @@ # use Catppuccin for bat # https://github.com/catppuccin/bat # Installation instruction on the readme ---theme="Catppuccin Latte" +--theme="Catppuccin Mocha" diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 1827201..9113676 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -384,7 +384,8 @@ vim.keymap.set('n', 'L', 'tabn', { desc = 'tab next' }) require('catppuccin').setup({ transparent_background = true, }) -vim.cmd.colorscheme "catppuccin-latte" +vim.cmd.colorscheme "catppuccin-mocha" +-- vim.cmd.colorscheme "catppuccin-latte" ----------------------------------------------------------- vim.g.mapleader = ' ' diff --git a/dotfiles/startup_linux.jl b/dotfiles/startup_linux.jl index 9534be9..ce4427a 100644 --- a/dotfiles/startup_linux.jl +++ b/dotfiles/startup_linux.jl @@ -2,7 +2,7 @@ try using OhMyREPL enable_autocomplete_brackets(false) include("catppuccin.jl") - OhMyREPL.colorscheme!("CatppuccinLatte") + OhMyREPL.colorscheme!("CatppuccinMocha") catch e @warn "Failed to load OhMyREPL" end diff --git a/dotfiles/wezterm/wezterm.lua b/dotfiles/wezterm/wezterm.lua index c93fc86..b081795 100644 --- a/dotfiles/wezterm/wezterm.lua +++ b/dotfiles/wezterm/wezterm.lua @@ -44,11 +44,13 @@ return { -- } -- }, - -- color_scheme = "iceberg-dark", - color_scheme = "catppuccin-latte", + color_scheme = "iceberg-dark", + -- color_scheme = "catppuccin-macchiato", + -- color_scheme = "catppuccin-latte", + -- color_scheme = "Everforest Dark (Gogh)", use_fancy_tab_bar = false, tab_bar_at_bottom = true, - window_background_opacity = 0.85, + window_background_opacity = 0.90, -- font = wezterm.font 'FirgeNerd Console' font = wezterm.font_with_fallback { { From d30feea25c147d2faa7e2c502f38b6f2e74e507f Mon Sep 17 00:00:00 2001 From: qwjyh Date: Wed, 9 Apr 2025 05:31:30 +0900 Subject: [PATCH 16/16] update(nvim): add gitignored local settings for nvim config --- bin/install.ps1 | 1 + bin/install.sh | 1 + dotfiles/neovim/.gitignore | 1 + dotfiles/neovim/init.lua | 2 +- 4 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 dotfiles/neovim/.gitignore diff --git a/bin/install.ps1 b/bin/install.ps1 index be17a41..9cb8591 100644 --- a/bin/install.ps1 +++ b/bin/install.ps1 @@ -54,6 +54,7 @@ scoop import .\bin\windows\scoop_apps\scoop_minimal_apps.json New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\init.lua -Target (Resolve-Path .\dotfiles\neovim\init.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\lualine_setup.lua -Target (Resolve-Path .\dotfiles\neovim\lua\lualine_setup.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\term_powershell.lua -Target (Resolve-Path .\dotfiles\neovim\lua\term_powershell.lua) -Force +New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\local_settings.lua -Target (Resolve-Path .\dotfiles\neovim\lua\local_settings.lua) -Force New-Item -ItemType SymbolicLink -Path ~\AppData\Local\nvim\lua\lspconfig\server_configurations\satysfi_ls.lua -Target (Resolve-Path .\dotfiles\neovim\lua\lspconfig\server_configurations\satysfi_ls.lua) -Force mkdir $env:LOCALAPPDATA\nvim\after\ftplugin New-Item -ItemType SymbolicLink -Path $env:LOCALAPPDATA\nvim\after\ftplugin\satysfi.lua -Target (Resolve-Path .\dotfiles\neovim\after\ftplugin\satysfi.lua) diff --git a/bin/install.sh b/bin/install.sh index 90626e9..2c174a5 100755 --- a/bin/install.sh +++ b/bin/install.sh @@ -26,6 +26,7 @@ mkdir -p ~/.config/nvim/lua ln -sf $(pwd)/dotfiles/neovim/lua/lualine_setup.lua ~/.config/nvim/lua/lualine_setup.lua ln -sf $(pwd)/dotfiles/neovim/lua/term_powershell.lua ~/.config/nvim/lua/term_powershell.lua ln -sf $(pwd)/dotfiles/neovim/lua/pluto_nvim.lua ~/.config/nvim/lua/pluto_nvim.lua +ln -sf $(pwd)/dotfiles/neovim/lua/local_settings.lua ~/.config/nvim/lua/local_settings.lua mkdir -p ~/.config/nvim/lua/lspconfig/server_configurations ln -sf $(pwd)/dotfiles/neovim/lua/lspconfig/server_configurations/satysfi_ls.lua ~/.config/nvim/lua/lspconfig/server_configurations/satysfi_ls.lua mkdir -p ~/.config/nvim/after/ftplugin diff --git a/dotfiles/neovim/.gitignore b/dotfiles/neovim/.gitignore new file mode 100644 index 0000000..8089223 --- /dev/null +++ b/dotfiles/neovim/.gitignore @@ -0,0 +1 @@ +lua/local_settings.lua diff --git a/dotfiles/neovim/init.lua b/dotfiles/neovim/init.lua index 9113676..812ae3e 100644 --- a/dotfiles/neovim/init.lua +++ b/dotfiles/neovim/init.lua @@ -236,7 +236,7 @@ require('lazy').setup({ config = function() -- Setup orgmode require('orgmode').setup({ - org_agenda_files = '~/orgfiles/**/*', + org_agenda_files = require("local_settings").org_agenda_files, org_default_notes_file = '~/orgfiles/refile.org', org_todo_keywords = { "TODO(t)",