Compare commits
6 Commits
1c2b5f8a0e
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| c3806dfd61 | |||
| 1b250f4500 | |||
| 0ef267297e | |||
| 17c19d3452 | |||
| da91033d53 | |||
| 1c6f0a0e46 |
5
Makefile
5
Makefile
@@ -1,10 +1,10 @@
|
|||||||
# prefer this if stow is available
|
# prefer this if stow is available
|
||||||
.PHONY: stow unstow
|
.PHONY: stow unstow
|
||||||
stow:
|
stow:
|
||||||
stow nvim
|
stow nvim ghostty
|
||||||
|
|
||||||
unstow:
|
unstow:
|
||||||
stow -D nvim
|
stow -D nvim ghostty
|
||||||
|
|
||||||
LN := ln -svf
|
LN := ln -svf
|
||||||
LNDIR := ln -sv
|
LNDIR := ln -sv
|
||||||
@@ -13,6 +13,7 @@ DOTFILES_DIR := $(shell pwd)
|
|||||||
TARGET_DIR := $(HOME)
|
TARGET_DIR := $(HOME)
|
||||||
|
|
||||||
# if stow is not available, symlink configs instead
|
# if stow is not available, symlink configs instead
|
||||||
|
# this is currently outdated
|
||||||
.PHONY: link unlink
|
.PHONY: link unlink
|
||||||
link: nvim
|
link: nvim
|
||||||
|
|
||||||
|
|||||||
13
ghostty/.config/ghostty/config.ghostty
Normal file
13
ghostty/.config/ghostty/config.ghostty
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
font-feature = -calt, -liga, -dlig
|
||||||
|
|
||||||
|
# Use Alt for multi-teriminal management
|
||||||
|
keybind = ctrl+shift+t=unbind
|
||||||
|
keybind = alt+t=new_tab
|
||||||
|
keybind = ctrl+shift+w=unbind
|
||||||
|
keybind = alt+w=close_tab:this
|
||||||
|
keybind = ctrl+enter=unbind
|
||||||
|
keybind = alt+enter=toggle_fullscreen
|
||||||
|
|
||||||
|
# Disable touchpad horizontal-swipe tab switching.
|
||||||
|
# Will come in next version
|
||||||
|
# gtk-horizontal-tab-scroll = false
|
||||||
@@ -43,6 +43,14 @@ Git shortcuts:
|
|||||||
|
|
||||||
- `:Git` to run commands directly (`:Git status`, `:Git log --oneline`)
|
- `:Git` to run commands directly (`:Git status`, `:Git log --oneline`)
|
||||||
- `<leader>lg` open LazyGit
|
- `<leader>lg` open LazyGit
|
||||||
|
- `<leader>dv` open Diffview
|
||||||
|
- `<leader>dc` close Diffview
|
||||||
|
|
||||||
|
Toggle shortcuts:
|
||||||
|
|
||||||
|
- `<leader>tw` toggle soft wrap
|
||||||
|
- `<leader>ti` toggle inline diagnostics
|
||||||
|
- `<leader>tv` toggle virtual diagnostics
|
||||||
|
|
||||||
Oil usage:
|
Oil usage:
|
||||||
|
|
||||||
@@ -104,8 +112,8 @@ Diagnostics:
|
|||||||
- `g.` open diagnostic float
|
- `g.` open diagnostic float
|
||||||
- `gl` send diagnostics to the location list
|
- `gl` send diagnostics to the location list
|
||||||
- `gld` display diagnostic information
|
- `gld` display diagnostic information
|
||||||
- `gid` toggle inline diagnostics
|
- `<leader>ti` toggle inline diagnostics
|
||||||
- `gvd` toggle virtual line diagnostics
|
- `<leader>tv` toggle virtual diagnostics
|
||||||
- `]g` jump to next warning or error
|
- `]g` jump to next warning or error
|
||||||
- `[g` jump to previous warning or error
|
- `[g` jump to previous warning or error
|
||||||
|
|
||||||
|
|||||||
1
nvim/.config/nvim/after/ftplugin/markdown.lua
Normal file
1
nvim/.config/nvim/after/ftplugin/markdown.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require("romanzy.custom.wrap").toggle(true)
|
||||||
1
nvim/.config/nvim/after/ftplugin/text.lua
Normal file
1
nvim/.config/nvim/after/ftplugin/text.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require("romanzy.custom.wrap").toggle(true)
|
||||||
1
nvim/.config/nvim/after/ftplugin/txt.lua
Normal file
1
nvim/.config/nvim/after/ftplugin/txt.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require("romanzy.custom.wrap").toggle(true)
|
||||||
1
nvim/.config/nvim/after/ftplugin/typst.lua
Normal file
1
nvim/.config/nvim/after/ftplugin/typst.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require("romanzy.custom.wrap").toggle(true)
|
||||||
@@ -16,6 +16,9 @@ function M.render()
|
|||||||
return table.concat(parts)
|
return table.concat(parts)
|
||||||
end
|
end
|
||||||
|
|
||||||
_G.RomanzyTabline = M.render
|
function M.setup()
|
||||||
|
_G.RomanzyTabline = M.render
|
||||||
|
vim.opt.tabline = "%!v:lua.RomanzyTabline()"
|
||||||
|
end
|
||||||
|
|
||||||
return M
|
return M
|
||||||
|
|||||||
17
nvim/.config/nvim/lua/romanzy/custom/wrap.lua
Normal file
17
nvim/.config/nvim/lua/romanzy/custom/wrap.lua
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
local M = {}
|
||||||
|
|
||||||
|
--- Toggle wrapping, or force it to the provided state.
|
||||||
|
--- @param enabled? boolean
|
||||||
|
function M.toggle(enabled)
|
||||||
|
if enabled == nil then
|
||||||
|
enabled = not vim.wo.wrap
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.wo.wrap = enabled
|
||||||
|
vim.wo.linebreak = enabled
|
||||||
|
vim.wo.breakindent = enabled
|
||||||
|
vim.bo.textwidth = enabled and 80 or 0
|
||||||
|
vim.bo.wrapmargin = 0
|
||||||
|
end
|
||||||
|
|
||||||
|
return M
|
||||||
@@ -26,12 +26,15 @@ map("n", "<leader>fg", telescope_picker("live_grep"), { desc = "live grep" })
|
|||||||
map("n", "<leader>fb", telescope_picker("buffers"), { desc = "find buffers" })
|
map("n", "<leader>fb", telescope_picker("buffers"), { desc = "find buffers" })
|
||||||
map("n", "<leader>fh", telescope_picker("help_tags"), { desc = "help tags" })
|
map("n", "<leader>fh", telescope_picker("help_tags"), { desc = "help tags" })
|
||||||
map("n", "<leader>lg", "<Cmd>LazyGit<CR>", { desc = "open lazygit" })
|
map("n", "<leader>lg", "<Cmd>LazyGit<CR>", { desc = "open lazygit" })
|
||||||
|
map("n", "<leader>dv", "<Cmd>DiffviewOpen<CR>", { desc = "open diffview" })
|
||||||
|
map("n", "<leader>dc", "<Cmd>DiffviewClose<CR>", { desc = "close diffview" })
|
||||||
|
map("n", "<leader>tw", require("romanzy.custom.wrap").toggle, { desc = "toggle soft wrap" })
|
||||||
|
|
||||||
-- map("n", "<leader>s", ":set spell!<CR>", { desc = "toggle spell" })
|
|
||||||
map("n", "<leader>sv", "<Cmd>vs<CR>", { desc = "split vertical" })
|
map("n", "<leader>sv", "<Cmd>vs<CR>", { desc = "split vertical" })
|
||||||
map("n", "<leader>sh", "<Cmd>sp<CR>", { desc = "split horizontal" })
|
map("n", "<leader>sh", "<Cmd>sp<CR>", { desc = "split horizontal" })
|
||||||
map("n", "<leader>se", "<C-w>=", { desc = "equalize splits" })
|
map("n", "<leader>se", "<C-w>=", { desc = "equalize splits" })
|
||||||
map("n", "<leader>sc", "<C-w>c", { desc = "close split" })
|
map("n", "<leader>sc", "<C-w>c", { desc = "close split" })
|
||||||
|
|
||||||
map("n", "<leader>rh", "<Cmd>vertical resize -10<CR>", { desc = "make buffer narrower" })
|
map("n", "<leader>rh", "<Cmd>vertical resize -10<CR>", { desc = "make buffer narrower" })
|
||||||
map("n", "<leader>rl", "<Cmd>vertical resize +10<CR>", { desc = "make buffer wider" })
|
map("n", "<leader>rl", "<Cmd>vertical resize +10<CR>", { desc = "make buffer wider" })
|
||||||
map("n", "<leader>rj", "<Cmd>resize -5<CR>", { desc = "make buffer shorter" })
|
map("n", "<leader>rj", "<Cmd>resize -5<CR>", { desc = "make buffer shorter" })
|
||||||
@@ -47,10 +50,8 @@ map("n", "<leader>Y", '"+Y', { desc = "yank line to system clipboard" })
|
|||||||
map("n", "<leader>p", '"+p', { desc = "paste from system clipboard" })
|
map("n", "<leader>p", '"+p', { desc = "paste from system clipboard" })
|
||||||
map("n", "<leader>P", '"+P', { desc = "paste before from system clipboard" })
|
map("n", "<leader>P", '"+P', { desc = "paste before from system clipboard" })
|
||||||
|
|
||||||
map("t", "\\\\", "<C-\\><C-n>", { desc = "exit terminal" })
|
-- experimenting
|
||||||
map("t", "<C-\\><C-\\>", "<C-\\><C-n>", { desc = "exit terminal" })
|
map("t", { "\\\\", "<C-\\><C-\\>", "<C-Esc>", "\\<Esc>" }, "<C-\\><C-n>", { desc = "exit terminal" })
|
||||||
map("t", "<C-Esc>", "<C-\\><C-n>", { desc = "exit terminal" })
|
|
||||||
map("t", "\\<Esc>", "<C-\\><C-n>", { desc = "exit terminal" })
|
|
||||||
|
|
||||||
map("n", "<C-h>", "<C-w>h", { desc = "window left" })
|
map("n", "<C-h>", "<C-w>h", { desc = "window left" })
|
||||||
map("n", "<C-j>", "<C-w>j", { desc = "window down" })
|
map("n", "<C-j>", "<C-w>j", { desc = "window down" })
|
||||||
@@ -145,9 +146,9 @@ map("n", "[g", function()
|
|||||||
end, { desc = "prev warning/error" })
|
end, { desc = "prev warning/error" })
|
||||||
|
|
||||||
map("n", "gld", vim.diagnostic.setloclist, { desc = "display diagnostic information" })
|
map("n", "gld", vim.diagnostic.setloclist, { desc = "display diagnostic information" })
|
||||||
map("n", "gid", function()
|
map("n", "<leader>ti", function()
|
||||||
vim.diagnostic.config({ virtual_text = not vim.diagnostic.config().virtual_text })
|
vim.diagnostic.config({ virtual_text = not vim.diagnostic.config().virtual_text })
|
||||||
end, { desc = "toggle inline diagnostics" })
|
end, { desc = "toggle inline diagnostics" })
|
||||||
map("n", "gvd", function()
|
map("n", "<leader>tv", function()
|
||||||
vim.diagnostic.config({ virtual_lines = not vim.diagnostic.config().virtual_lines })
|
vim.diagnostic.config({ virtual_lines = not vim.diagnostic.config().virtual_lines })
|
||||||
end, { desc = "toggle virtual line diagnostics" })
|
end, { desc = "toggle virtual diagnostics" })
|
||||||
|
|||||||
@@ -1,40 +1,39 @@
|
|||||||
local g = vim.g
|
local g = vim.g
|
||||||
local o = vim.opt
|
local o = vim.opt
|
||||||
|
|
||||||
g.mapleader = " " -- Uses space as the global leader key.
|
g.mapleader = " " -- Uses space as the global leader key.
|
||||||
g.maplocalleader = " " -- Uses space as the local leader key.
|
g.maplocalleader = " " -- Uses space as the local leader key.
|
||||||
g.clipboard = "osc52" -- Routes the + and * registers through OSC52 in terminal Neovim.
|
g.clipboard = "osc52" -- Routes the + and * registers through OSC52 in terminal Neovim.
|
||||||
|
|
||||||
o.number = true -- Shows absolute line numbers.
|
o.number = true -- Shows absolute line numbers.
|
||||||
o.relativenumber = true -- Shows relative numbers for easier motion.
|
o.relativenumber = true -- Shows relative numbers for easier motion.
|
||||||
o.cursorline = true -- Highlights the line under the cursor.
|
o.cursorline = true -- Highlights the line under the cursor.
|
||||||
o.textwidth = 80 -- Wraps inserted text after 80 columns when formatting is active.
|
o.textwidth = 80 -- Wraps inserted text after 80 columns when formatting is active.
|
||||||
o.scrolloff = 8 -- Keeps context lines visible around the cursor.
|
o.scrolloff = 8 -- Keeps context lines visible around the cursor.
|
||||||
o.signcolumn = "yes" -- Always reserves space for signs in the gutter.
|
o.signcolumn = "yes" -- Always reserves space for signs in the gutter.
|
||||||
o.colorcolumn = "+1" -- Highlights the preferred maximum line width.
|
o.colorcolumn = "+1" -- Highlights the preferred maximum line width.
|
||||||
o.wrap = false -- Prevents long lines from wrapping on screen.
|
o.list = true -- Displays whitespace characters using listchars.
|
||||||
o.list = true -- Displays whitespace characters using listchars.
|
|
||||||
o.listchars = {
|
o.listchars = {
|
||||||
tab = "» ",
|
tab = "» ",
|
||||||
trail = "·",
|
trail = "·",
|
||||||
extends = "⟩",
|
extends = "⟩",
|
||||||
precedes = "⟨",
|
precedes = "⟨",
|
||||||
nbsp = "␣",
|
nbsp = "␣",
|
||||||
} -- Defines how invisible characters are rendered.
|
} -- Defines how invisible characters are rendered.
|
||||||
o.termguicolors = true -- Enables full RGB color support.
|
o.termguicolors = true -- Enables full RGB color support.
|
||||||
o.mouse = "" -- Disables mouse support.
|
o.mouse = "" -- Disables mouse support.
|
||||||
o.tabstop = 4 -- Renders tab characters as four columns.
|
o.tabstop = 4 -- Renders tab characters as four columns.
|
||||||
o.softtabstop = 4 -- Makes tab/backspace feel like four spaces.
|
o.softtabstop = 4 -- Makes tab/backspace feel like four spaces.
|
||||||
o.shiftwidth = 4 -- Uses four columns for each indent step.
|
o.shiftwidth = 4 -- Uses four columns for each indent step.
|
||||||
o.expandtab = true -- Inserts spaces when indenting by default.
|
o.expandtab = true -- Inserts spaces when indenting by default.
|
||||||
o.smartindent = true -- Adds indentation automatically on new lines.
|
o.smartindent = true -- Adds indentation automatically on new lines.
|
||||||
o.swapfile = false -- Disables swapfile creation.
|
o.swapfile = false -- Disables swapfile creation.
|
||||||
o.incsearch = true -- Updates search matches as you type.
|
o.incsearch = true -- Updates search matches as you type.
|
||||||
o.completeopt = { "menuone", "noselect", "fuzzy", "nosort" } -- Enables fuzzy completion matching without preselecting or reordering candidates.
|
o.completeopt = { "menuone", "noselect", "fuzzy", "nosort" } -- Enables fuzzy completion matching.
|
||||||
o.updatetime = 50 -- Reduces idle delay for swap and CursorHold events.
|
o.pumheight = 8 -- Limits the completion popup menu size.
|
||||||
o.spelllang = { "en_us" } -- Uses US English for spell checking.
|
o.updatetime = 50 -- Reduces idle delay for swap and CursorHold events.
|
||||||
o.shell = "bash" -- Runs shell commands through bash.
|
o.spelllang = { "en_us" } -- Uses US English for spell checking.
|
||||||
o.tabline = "%!v:lua.RomanzyTabline()" -- Shows native tabs with custom labels.
|
o.shell = "bash" -- Runs shell commands through bash.
|
||||||
|
|
||||||
-- Only show the invisible characters inside the code editing buffers
|
-- Only show the invisible characters inside the code editing buffers
|
||||||
vim.cmd([[autocmd BufWinEnter * if &buftype != '' | setlocal nolist | endif]])
|
vim.cmd([[autocmd BufWinEnter * if &buftype != '' | setlocal nolist | endif]])
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
require("romanzy.plugins.rose-pine")
|
require("romanzy.plugins.rose-pine")
|
||||||
require("romanzy.plugins.mini")
|
require("romanzy.plugins.mini")
|
||||||
require("romanzy.plugins.lazygit")
|
require("romanzy.plugins.lazygit")
|
||||||
|
require("romanzy.plugins.diffview")
|
||||||
require("romanzy.plugins.oil")
|
require("romanzy.plugins.oil")
|
||||||
require("romanzy.plugins.telescope")
|
require("romanzy.plugins.telescope")
|
||||||
require("romanzy.plugins.nvim-treesitter")
|
require("romanzy.plugins.nvim-treesitter")
|
||||||
require("romanzy.plugins.conform")
|
require("romanzy.plugins.conform")
|
||||||
require("romanzy.plugins.lsp")
|
require("romanzy.plugins.lsp")
|
||||||
require("romanzy.plugins.codamheader")
|
require("romanzy.plugins.codamheader")
|
||||||
|
require("romanzy.plugins.romanzy")
|
||||||
-- custom "plugins"
|
|
||||||
require("romanzy.custom.tabline")
|
|
||||||
|
|||||||
6
nvim/.config/nvim/lua/romanzy/plugins/diffview.lua
Normal file
6
nvim/.config/nvim/lua/romanzy/plugins/diffview.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
vim.pack.add({
|
||||||
|
{
|
||||||
|
src = "https://github.com/sindrets/diffview.nvim",
|
||||||
|
name = "diffview.nvim",
|
||||||
|
},
|
||||||
|
})
|
||||||
@@ -55,6 +55,7 @@ local managed_servers = {
|
|||||||
"ts_ls",
|
"ts_ls",
|
||||||
"tailwindcss",
|
"tailwindcss",
|
||||||
"eslint",
|
"eslint",
|
||||||
|
"tinymist",
|
||||||
}
|
}
|
||||||
local servers = {
|
local servers = {
|
||||||
bashls = {},
|
bashls = {},
|
||||||
@@ -62,8 +63,6 @@ local servers = {
|
|||||||
jsonls = {},
|
jsonls = {},
|
||||||
marksman = {},
|
marksman = {},
|
||||||
taplo = {},
|
taplo = {},
|
||||||
tailwindcss = {},
|
|
||||||
ts_ls = {},
|
|
||||||
yamlls = {},
|
yamlls = {},
|
||||||
lua_ls = {
|
lua_ls = {
|
||||||
settings = {
|
settings = {
|
||||||
@@ -81,6 +80,10 @@ local servers = {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
ts_ls = {},
|
||||||
|
tailwindcss = {},
|
||||||
|
eslint = {},
|
||||||
|
tinymist = {},
|
||||||
}
|
}
|
||||||
|
|
||||||
for server_name, config in pairs(servers) do
|
for server_name, config in pairs(servers) do
|
||||||
|
|||||||
2
nvim/.config/nvim/lua/romanzy/plugins/romanzy.lua
Normal file
2
nvim/.config/nvim/lua/romanzy/plugins/romanzy.lua
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
require("romanzy.custom.tabline").setup()
|
||||||
|
require("romanzy.custom.wrap").toggle(false)
|
||||||
@@ -8,6 +8,10 @@
|
|||||||
"rev": "619363c30309d29ffa631e67c8183f2a72caa373",
|
"rev": "619363c30309d29ffa631e67c8183f2a72caa373",
|
||||||
"src": "https://github.com/stevearc/conform.nvim"
|
"src": "https://github.com/stevearc/conform.nvim"
|
||||||
},
|
},
|
||||||
|
"diffview.nvim": {
|
||||||
|
"rev": "4516612fe98ff56ae0415a259ff6361a89419b0a",
|
||||||
|
"src": "https://github.com/sindrets/diffview.nvim"
|
||||||
|
},
|
||||||
"lazygit.nvim": {
|
"lazygit.nvim": {
|
||||||
"rev": "a04ad0dbc725134edbee3a5eea29290976695357",
|
"rev": "a04ad0dbc725134edbee3a5eea29290976695357",
|
||||||
"src": "https://github.com/kdheepak/lazygit.nvim"
|
"src": "https://github.com/kdheepak/lazygit.nvim"
|
||||||
|
|||||||
Reference in New Issue
Block a user