repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

neovim: removed mason and neorg wezterm: random font on fedora

a32fc4ce51fb741f83b3161468f79b23d03ad479

Oliver Jan Krylow <oliver@bugabinga.net> ·

unsigned

Browse filesCompare with HEAD

Changed files (13)

cargo/config.toml

Modified
1 1 [build]
2 -# enable a cache for crates between builds
3 -rustc-wrapper = "sccache"
4 2 # since we only care for builds for our own machine, let's benefit from thise juicy modern cpu features
5 3 rustflags = ["-C", "target-cpu=native"]

fedora.symlinks

Added
new file mode 100644
1 +git/gitconfig
2 +~/.config/git/config
4 +git/gitconfig.linux
5 +~/.config/git/.gitconfig.include
7 +subversion/config
8 +~/.subversion/config
10 +subversion/diff
11 +~/.subversion/diff
13 +subversion/diff3
14 +~/.subversion/diff3
16 +subversion/merge
17 +~/.subversion/merge
19 +tools/git-info
20 +~/.local/bin/git-info
22 +cargo/config.toml
23 +~/.cargo/config.toml
25 +bat/config
26 +~/.config/bat/config
28 +nushell/config.nu
29 +~/.config/nushell/config.nu
31 +nushell/env.nu
32 +~/.config/nushell/env.nu
34 +nushell/modules
35 +~/.config/nushell/modules
37 +nushell/plugin.nu
38 +~/.config/nushell/plugin.nu
40 +topgrade/topgrade.linux.toml
41 +~/.config/topgrade.toml
43 +wezterm
44 +~/.config/wezterm
46 +wezterm/wezterm.service
47 +~/.config/systemd/user/wezterm.service
49 +helix/config.toml
50 +~/.config/helix/config.toml
52 +helix/languages.toml
53 +~/.config/helix/languages.toml
55 +helix/themes
56 +~/.config/helix/themes
58 +helix/systemd/helix-dark-mode.service
59 +~/.config/systemd/user/helix-dark-mode.service
61 +xplr
62 +~/.config/xplr
64 +ssh/config
65 +~/.ssh/config
67 +neovim
68 +~/.config/nvim

neovim/README.md

Modified
39 39 # todo
41 41 * remove mason
42 +* warn if trying to load a lsp client, that has no command
42 43 * navic highlights do not fit winbar
43 44 * make highlights more visible when expanding snippets
44 45 * cursor restore position on (session?) load jumps one location to somewhere

neovim/after/queries/lua/highlights.scm

Modified
1 1 ;; inherits: lua
2 2 ;; extends
3 -(("local" @keyword) (#set! conceal "·"))
4 3 (("function" @keyword.function) (#set! conceal "λ"))
5 -(("return" @keyword.return) (#set! conceal "󰌑"))

neovim/ftplugin/lua.lua

Modified
7 7 vim.opt_local.suffixesadd:prepend '.lua'
8 8 vim.opt_local.conceallevel = 1
9 +vim.opt_local.concealcursor = 'n'
10 11 local map = require 'std.map'

neovim/lazy-lock.json

Modified
19 19 "glow.nvim": { "branch": "main", "commit": "238070a686c1da3bccccf1079700eb4b5e19aea4" },
20 20 "heirline.nvim": { "branch": "master", "commit": "03cff30d7e7d3ba6fdc00925f015822f79cef908" },
21 21 "indent-blankline.nvim": { "branch": "master", "commit": "3d08501caef2329aba5121b753e903904088f7e6" },
22 - "lazy.nvim": { "branch": "main", "commit": "31ddbea7c10b6920c9077b66c97951ca8682d5c8" },
22 + "lazy.nvim": { "branch": "main", "commit": "bef521ac89c8d423f9d092e37b58e8af0c099309" },
23 23 "lspkind.nvim": { "branch": "master", "commit": "1735dd5a5054c1fb7feaf8e8658dbab925f4f0cf" },
24 24 "lua-utils.nvim": { "branch": "main", "commit": "e565749421f4bbb5d2e85e37c3cef9d56553d8bd" },
25 25 "mason-tool-installer.nvim": { "branch": "main", "commit": "b129892f783740e6cf741f2ea09fa5dd512aa584" },
27 27 "mini.bracketed": { "branch": "main", "commit": "65c7dfb51e832de9e279e5d5b0741e7af6755ab5" },
28 28 "mkdir.nvim": { "branch": "main", "commit": "c55d1dee4f099528a1853b28bb28caa802eba217" },
29 29 "neodev.nvim": { "branch": "main", "commit": "ce9a2e8eaba5649b553529c5498acb43a6c317cd" },
30 + "neogen": { "branch": "main", "commit": "0daffcec249bf42275e322361fe55b89a05ff278" },
30 31 "neorg": { "branch": "main", "commit": "c17b8e9e7327e03f78fbdccfb15abd09ec607bd0" },
31 32 "neotest": { "branch": "master", "commit": "f03a78cef74db5638e4312e18b767294a90de8da" },
32 33 "neotest-plenary": { "branch": "master", "commit": "dcaf5ed67a9e28a246e9783319e5aa6c9ea1c584" },

neovim/lua/bugabinga/lsp/clients/java.lua

Modified
3 3 local table = require 'std.table'
4 4 local project = require 'std.project'
5 5 local auto = require 'std.auto'
6 6 local map = require 'std.map'
8 -local create_shared_config_path = function ( base_path, syntax_server )
9 - local os_config
10 - if vim.fn.has 'linux' == 1 then
11 - os_config = syntax_server and 'config_ss_linux' or 'config_linux'
12 - elseif vim.fn.has 'mac' == 1 then
13 - os_config = syntax_server and 'config_ss_mac' or 'config_mac'
14 - else
15 - os_config = syntax_server and 'config_ss_win' or 'config_win'
16 - end
17 - return vim.fs.joinpath( base_path, os_config )
18 -end
20 -local find_launcher_jar = function ( base_path )
21 - local plugins_dir = vim.fs.joinpath( base_path, 'plugins' )
22 - local launchers = vim.fn.globpath( plugins_dir, 'org.eclipse.equinox.launcher_*.jar', false, true )
24 - if table.is_empty( launchers ) then
25 - error( 'Could not find jdtls launcher jar in ' .. plugins_dir )
26 - end
28 - -- vim.print('found launcher jars', launchers)
29 - return launchers[1]
30 -end
32 -local create_data_dir = function ()
33 - local cwd = vim.uv.cwd() or ''
34 - local data_name = vim.fn.sha256( cwd )
35 - local cache = vim.fn.stdpath 'cache'
36 - cache = type( cache ) == 'table' and cache[1] or cache
38 - return vim.fs.joinpath( cache, 'jdtls_data', data_name )
39 -end
41 -local function get_bundles()
42 - local mason_registry = require 'mason-registry'
43 - local java_debug = mason_registry.get_package 'java-debug-adapter'
44 - local java_test = mason_registry.get_package 'java-test'
45 - local java_debug_path = java_debug:get_install_path()
46 - local java_test_path = java_test:get_install_path()
47 - local bundles = {}
48 - --FIXME: refactor this!
49 - vim.list_extend( bundles,
50 - vim.split(
51 - --TODO: jdtls seemingly cannot get bindle info out of this jar
52 - --
53 - -- Contains: Failed to get bundleInfo for bundle from /home/oli/.local/share/nvim/mason/packages/java-test/extension/server/com.microsoft.java.test.runner-jar-with-dependencies.jar
54 - -- "
55 - vim.fn.glob( java_debug_path .. '/extension/server/com.microsoft.java.debug.plugin-*.jar' ), '\n' ) )
56 - vim.list_extend( bundles, vim.split( vim.fn.glob( java_test_path .. '/extension/server/*.jar' ), '\n' ) )
57 - return bundles
58 -end
60 -local create_jdtls_command = function ( syntax_server )
61 - local mason_registry = require 'mason-registry'
62 - local jdtls_package_path = mason_registry.get_package 'jdtls':get_install_path()
63 - local shared_config_path = create_shared_config_path( jdtls_package_path, syntax_server )
64 - local launcher_jar = find_launcher_jar( jdtls_package_path )
65 - local data_dir = create_data_dir()
67 - local ss_option = syntax_server and '-Dsyntaxserver=true' or nil
69 - local command = {
70 - 'java',
71 - '-Declipse.application=org.eclipse.jdt.ls.core.id1',
72 - '-Dosgi.bundles.defaultStartLevel=4',
73 - '-Declipse.product=org.eclipse.jdt.ls.core.product',
74 - '-Dlog.protocol=true',
75 - '-Dlog.level=ALL',
76 - '-Dosgi.checkConfiguration=true',
77 - '-Dosgi.sharedConfiguration.area=' .. shared_config_path,
78 - '-Dosgi.sharedConfiguration.area.readOnly=true',
79 - '-Dosgi.configuration.cascaded=true',
80 - '--add-modules=ALL-SYSTEM',
81 - '--add-opens', 'java.base/java.util=ALL-UNNAMED',
82 - '--add-opens', 'java.base/java.lang=ALL-UNNAMED',
83 - '-jar', launcher_jar,
84 - '-data', data_dir,
85 - }
87 - if ss_option then
88 - -- insert option after 'java'
89 - table.insert( command, 2, ss_option )
90 - end
92 - return command
93 -end
95 8 local find_jdks = function ()
96 9 local host = vim.uv.os_gethostname()
97 10 local jdk11 = {
159 -local jdtls_lsp_start = function ( config, opts )
160 - -- vim.print('jdtls lsp start', config, opts)
161 - require 'jdtls'.start_or_attach( config, opts )
162 -end
164 -local get_extended_capabilites = function ()
165 - local ext = require 'jdtls'.extendedClientCapabilities
166 - ext.resolveAdditionalTextEditsSupport = true
167 - return ext
168 -end
170 72 local on_attach = function ()
171 - local jdtls = require 'jdtls'
172 73 vim.lsp.codelens.refresh()
173 - jdtls.setup_dap { hotcodereplace = 'auto', }
174 - require 'jdtls.dap'.setup_dap_main_class_configs()
175 - require 'jdtls.setup'.add_commands()
177 - map.normal {
178 - description = 'Organize Imports',
179 - category = 'jdlts',
180 - keys = '<leader>ljo',
181 - command = jdtls.organize_imports,
182 - }
184 - map.normal {
185 - description = 'Extract Variable',
186 - category = 'jdlts',
187 - keys = '<leader>ljv',
188 - command = jdtls.extract_variable,
189 - }
191 - map.normal {
192 - description = 'Extract Constant',
193 - category = 'jdlts',
194 - keys = '<leader>ljc',
195 - command = jdtls.extract_constant,
196 - }
198 - map.normal {
199 - description = 'Test Nearest Method',
200 - category = 'jdlts',
201 - keys = '<leader>ljt',
202 - command = jdtls.test_nearest_method,
203 - }
205 - map.normal {
206 - description = 'Test Class',
207 - category = 'jdlts',
208 - keys = '<leader>ljT',
209 - command = jdtls.test_class,
210 - }
212 - map.normal {
213 - description = 'Update Config',
214 - category = 'jdlts',
215 - keys = '<leader>lju',
216 - command = '<cmd>JdtUpdateConfig<cr>',
217 - }
219 - map.visual {
220 - description = 'Extract Variable',
221 - category = 'jdlts',
222 - keys = '<leader>ljv',
223 - command = function () jdtls.extract_variable( true ) end,
224 - }
226 - map.visual {
227 - description = 'Extract Constant',
228 - category = 'jdlts',
229 - keys = '<leader>ljc',
230 - command = function () jdtls.extract_constant( true ) end,
231 - }
233 - map.visual {
234 - description = 'Extract Method',
235 - category = 'jdlts',
236 - keys = '<leader>ljm',
237 - command = function () jdtls.extract_method( true ) end,
238 - }
240 74 auto 'refresh_codelens' {
241 75 events = 'BufWritePost',
242 76 description = 'Refreshes LSP CodeLens after java file is written.',
248 82 return {
249 83 name = 'jdtls',
250 - custom_start = jdtls_lsp_start,
251 84 filetypes = 'java',
252 - command = create_jdtls_command( false ),
85 + command = 'jdtls',
253 86 root_dir = project.find_java_project_root,
254 87 single_file_support = true,
255 88 workspaces = true,
256 89 settings = { java = java_settings, },
257 90 on_attach = on_attach,
258 - init_options = {
259 - bundles = get_bundles(),
260 - extendedClientCapabilities = get_extended_capabilites(),
261 - },

neovim/lua/bugabinga/plugins/jdtls.lua

Deleted
deleted file mode 100644
1 -return { 'bugabinga/nvim-jdtls', }

neovim/lua/bugabinga/plugins/mason.lua

Deleted
deleted file mode 100644
1 -return {
2 - 'williamboman/mason.nvim',
3 - version = '1.*',
4 - lazy = false,
5 - opts = {
6 - ui = {
7 - border = vim.g.border_style,
8 - width = 0.69,
9 - height = 0.69,
10 - },
11 - },
12 - dependencies = {
13 - {
14 - 'WhoIsSethDaniel/mason-tool-installer.nvim',
15 - lazy = false,
16 - opts = {
17 - ensure_installed = {
18 - 'lua-language-server',
19 - 'shellcheck',
20 - 'editorconfig-checker',
21 - 'shfmt',
22 - 'jdtls',
23 - 'java-test',
24 - 'java-debug-adapter',
25 - 'lemminx',
26 - 'marksman',
27 - 'typos',
28 - 'gitleaks',
29 - 'mdslw',
30 - },
31 - },
32 - },
33 - },
34 -}

neovim/lua/bugabinga/plugins/neorg.lua

Deleted
deleted file mode 100644
1 -return {
2 - 'nvim-neorg/neorg',
3 - version = '8.*',
4 - dependencies = {
5 - { 'nvim-lua/plenary.nvim', version = '0.1.4', },
6 - { 'nvim-neorg/lua-utils.nvim', version = '1.0.2', },
7 - { 'nvim-neotest/nvim-nio', version = '1.7.*', },
8 - { 'MunifTanjim/nui.nvim', version = '0.3.0', },
9 - { 'nvim-treesitter/nvim-treesitter', },
10 - },
11 - build = function ()
12 - package.loaded['neorg'] = nil
14 - require 'neorg'.setup_after_build()
15 - pcall( vim.cmd.Neorg, 'sync-parsers' )
16 - end,
17 - ft = 'norg',
18 - cmd = 'Neorg',
19 - opts = {
20 - load = {
21 - ['core.defaults'] = {}, -- Loads default behaviour
22 - ['core.concealer'] = { -- Adds pretty icons to your documents
23 - config = {
24 - icons = {
25 - todo = {
26 - undone = {
27 - icon = ' ',
28 - },
29 - },
30 - },
31 - },
32 - },
33 - ['core.completion'] = {
34 - config = {
35 - engine = 'nvim-cmp',
36 - },
37 - },
38 - ['core.presenter'] = {
39 - config = {
40 - zen_mode = 'zen-mode',
41 - },
42 - },
43 - },
44 - },
45 -}

ssh/config

Modified
10 10 User git
11 11 IdentityFile ~/.ssh/github.key
13 +Host seaduck
14 + Hostname seaduck
15 + User oli
16 + IdentityFile ~/.ssh/seaduck.key
13 18 # catch-all pattern
14 19 Host *
15 20 User root

wezterm/nerdfonts

Added
new file mode 100644
1 +IBM 3270
2 +Anonymous Pro
3 +Aurulent Sans Mono
4 +BigBlueTerminalPlus
5 +Bitstream Vera Sans Mono
6 +IBM Plex Mono
7 +Cascadia Code
8 +Cousine
9 +D2Coding
10 +DejaVu Sans Mono
11 +Droid Sans Mono
12 +Envy Code R
13 +Fantasque Sans Mono
14 +FiraCode
15 +GeistMono
16 +Hack
17 +Hasklig
18 +Hermit
19 +iA Writer Mono V
20 +Inconsolata
21 +Intel One Mono
22 +Iosevka
23 +JetBrainsMono
24 +Lekton
25 +Liberation Mono
26 +Lilex
27 +MartianMono
28 +Monaspace Argon Var
29 +Monaspace Krypton Var
30 +Monaspace Neon Var
31 +Monofur
32 +Monoid
33 +Mononoki
34 +Rec Mono Casual
35 +Rec Mono Linear
36 +RobotoMono
37 +Share Tech Mono
38 +Source Code Pro
39 +Terminus
40 +VictorMono

wezterm/wezterm.lua

Modified
19 19 enable_wayland = true
20 20 elseif hostname == 'NB-00718' then
21 21 font_size = 19
22 +elseif hostname == 'fedora' then
23 + font_size = 16
24 + local font_names = {}
25 + local nerdfonts = io.open(wez.config_dir .. '/nerdfonts', 'r')
26 + for font_name in nerdfonts:lines() do
27 + table.insert(font_names,font_name)
28 + end
29 + local random_font = font_names[math.random(#font_names)]
30 + font = wez.font(random_font)
24 33 return {
49 58 hide_tab_bar_if_only_one_tab = false,
50 59 use_fancy_tab_bar = false,
51 60 check_for_updates = false,
52 - show_update_window = false,
53 61 audible_bell = 'Disabled',
54 62 visual_bell = {
55 63 fade_in_duration_ms = 69,