260428.2 · e0d14439e1eb7792eb5538dbe025d38c9022d497
nvim: tweaks
reading declarations
@@ -206,7 +206,7 @@ vim.api.nvim_create_autocmd('FileType', { vim.api.nvim_create_autocmd('FileType', { pattern = 'sh', callback = function()- spacing.space4()+ spacing.space2() vim.b.comment = '#' end, })
@@ -12,6 +12,9 @@ vim.lsp.config('ty', { completions = { autoImport = true, },+ inlayHints = {+ variableTypes = true,+ }, }, }, })@@ -150,6 +153,9 @@ vim.keymap.set('n', [[\gd]], function() end) vim.keymap.set('n', [[<C-d>]], vim.diagnostic.open_float) vim.keymap.set('n', [[\gh]], vim.lsp.buf.typehierarchy)+vim.keymap.set('n', [[\gri]], function()+ vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled())+end) vim.lsp.enable('ty') vim.lsp.enable('rust_analyzer')
@@ -1,15 +1,25 @@ #!/bin/bash +ty_stderr=/tmp/ty-stderr.log+if [ -n "$TYERR" ]; then+ ty_stderr="$TYERR"+fi++if [ -n "$TYBIN" ]; then+ exec "$TYBIN" server 2> "$ty_stderr"+fi+ if [ "$(myhostname)" = "bart" ]; then- exec /home/andrew/bin/x86_64/ty server 2> /tmp/ty-stderr.log+ exec /home/andrew/bin/x86_64/ty server 2> "$ty_stderr" else paths=(+ /home/andrew/astral/ruff/pr1/target/profiling/ty /home/andrew/astral/ruff/pr1/target/debug/ty /home/andrew/astral/ruff/pr2/target/debug/ty ) for path in "${paths[@]}"; do if [ -f "$path" ]; then- exec "$path" server 2> /tmp/ty-stderr.log+ exec "$path" server 2> "$ty_stderr" fi done echo "failed to find ty server binary" >&2