Add Arch Wayland dotfiles: sway/waybar/kitty/nvim/zsh, idempotent installer

Auto-adapts sway workspace routing to however many monitors are
connected (laptop vs. desktop) instead of hardcoding output names.
This commit is contained in:
2026-08-21 22:59:26 -05:00
commit 5c57ee20f7
35 changed files with 870 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
require("config.options")
require("config.plugins")
require("config.keymaps")
require("config.autocmds")
+10
View File
@@ -0,0 +1,10 @@
local group = vim.api.nvim_create_augroup("dotfiles", { clear = true })
vim.api.nvim_create_autocmd("TextYankPost", {
group = group,
callback = function() vim.highlight.on_yank({ timeout = 150 }) end,
})
vim.api.nvim_create_autocmd("BufWritePre", {
group = group,
pattern = "*",
callback = function() pcall(vim.cmd, [[%s/\s\+$//e]]) end,
})
+11
View File
@@ -0,0 +1,11 @@
local map = vim.keymap.set
map("n", "<leader>w", "<cmd>write<cr>", { desc = "Save file" })
map("n", "<leader>q", "<cmd>quit<cr>", { desc = "Quit" })
map("n", "<leader>e", "<cmd>Explore<cr>", { desc = "File explorer" })
map("n", "<Esc>", "<cmd>nohlsearch<cr>")
map("n", "<C-Left>", "<C-w><Left>")
map("n", "<C-Down>", "<C-w><Down>")
map("n", "<C-Up>", "<C-w><Up>")
map("n", "<C-Right>", "<C-w><Right>")
map("v", "J", ":m '>+1<cr>gv=gv")
map("v", "K", ":m '<-2<cr>gv=gv")
+31
View File
@@ -0,0 +1,31 @@
vim.g.mapleader = " "
vim.g.maplocalleader = " "
local opt = vim.opt
opt.number = true
opt.relativenumber = true
opt.cursorline = true
opt.termguicolors = true
opt.signcolumn = "yes"
opt.wrap = false
opt.scrolloff = 8
opt.sidescrolloff = 8
opt.tabstop = 2
opt.shiftwidth = 2
opt.expandtab = true
opt.smartindent = true
opt.ignorecase = true
opt.smartcase = true
opt.splitbelow = true
opt.splitright = true
opt.undofile = true
opt.updatetime = 250
opt.timeoutlen = 400
vim.cmd.colorscheme("habamax")
vim.api.nvim_set_hl(0, "Normal", { fg = "#d4d4d4", bg = "#000000" })
vim.api.nvim_set_hl(0, "NormalFloat", { fg = "#d4d4d4", bg = "#0a0a0a" })
vim.api.nvim_set_hl(0, "CursorLine", { bg = "#0a0a0a" })
vim.api.nvim_set_hl(0, "Visual", { bg = "#2563eb" })
vim.api.nvim_set_hl(0, "LineNr", { fg = "#525252" })
vim.api.nvim_set_hl(0, "CursorLineNr", { fg = "#60a5fa", bold = true })
+10
View File
@@ -0,0 +1,10 @@
vim.pack.add({
"https://github.com/preservim/nerdtree",
}, { confirm = false })
vim.g.NERDTreeWinPos = "left"
vim.g.NERDTreeWinSize = 32
vim.api.nvim_create_user_command("Tree", "NERDTreeToggle", {
desc = "Toggle the NERDTree sidebar",
})
+8
View File
@@ -0,0 +1,8 @@
{
"plugins": {
"nerdtree": {
"rev": "690d061b591525890f1471c6675bcb5bdc8cdff9",
"src": "https://github.com/preservim/nerdtree"
}
}
}