diff --git a/bootstrap b/bootstrap index 0a996f2..14bcc22 100755 --- a/bootstrap +++ b/bootstrap @@ -5,13 +5,14 @@ if [[ -z "${DOTFILES_DIR:-}" ]]; then export DOTFILES_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) fi -script_dir="$script_dir/installer" +script_dir="$DOTFILES_DIR/installer" shopt -s nullglob ran_any=false for script in "$script_dir"/*.sh; do if [[ -f "$script" && -x "$script" ]]; then + echo $script "$script" ran_any=true fi diff --git a/config/nvim-old/.delete/nvim_task_keymaps.vim b/config/agents/AGENTS.md similarity index 100% rename from config/nvim-old/.delete/nvim_task_keymaps.vim rename to config/agents/AGENTS.md diff --git a/config/btop/btop.conf b/config/btop/btop.conf index 1f160c5..46947b3 100644 --- a/config/btop/btop.conf +++ b/config/btop/btop.conf @@ -1,4 +1,4 @@ -#? Config file for btop v.1.4.6 +#? Config file for btop v.1.4.7 #* Name of a btop++/bpytop/bashtop formatted ".theme" file, "Default" and "TTY" for builtin themes. #* Themes should be placed in "../share/btop/themes" relative to binary or "$HOME/.config/btop/themes" @@ -14,6 +14,11 @@ truecolor = true #* Will force 16-color mode and TTY theme, set all graph symbols to "tty" and swap out other non tty friendly symbols. force_tty = false +#* Option to disable presets. Either the default preset, custom presets, or all presets. +#* "Off" All presets are enabled. +#* "Default" preset is disabled.#* "Custom" presets are disabled.#* "All" presets are disabled. +disable_presets = "Off" + #* Define presets for the layout of the boxes. Preset 0 is always all boxes shown with default settings. Max 9 presets. #* Format: "box_name:P:G,box_name:P:G" P=(0 or 1) for alternate positions, G=graph symbol to use for box. #* Use whitespace " " as separator between different presets. @@ -24,6 +29,9 @@ presets = "cpu:1:default,proc:0:default cpu:0:default,mem:0:default,net:0:defaul #* Conflicting keys for h:"help" and k:"kill" is accessible while holding shift. vim_keys = false +#* Disable all mouse events. +disable_mouse = false + #* Rounded corners on boxes, is ignored if TTY mode is ON. rounded_corners = true @@ -92,6 +100,9 @@ proc_left = true #* (Linux) Filter processes tied to the Linux kernel(similar behavior to htop). proc_filter_kernel = false +#* Should the process list follow the selected process when detailed view is open. +proc_follow_detailed = true + #* In tree-view, always accumulate child process resources in the parent process. proc_aggregate = false @@ -208,6 +219,9 @@ io_graph_combined = false #* Example: "/mnt/media:100 /:20 /boot:1". io_graph_speeds = "" +#* Swap the positions of the upload and download speed graphs. When true, upload will be on top. +swap_upload_download = false + #* Set fixed values for network graphs in Mebibits. Is only used if net_auto is also set to False. net_download = 100 @@ -250,7 +264,7 @@ rsmi_measure_pcie_speeds = true #* Horizontally mirror the GPU graph. gpu_mirror_graph = true -#* Set which GPU vendors to show. Available values are "nvidia amd intel" +#* Set which GPU vendors to show. Available values are "nvidia amd intel apple" shown_gpus = "nvidia amd intel" #* Custom gpu0 model name, empty string to disable. diff --git a/config/hypr/hyprland.lua b/config/hypr/hyprland.lua index f2a0701..0146b6a 100644 --- a/config/hypr/hyprland.lua +++ b/config/hypr/hyprland.lua @@ -1,9 +1,10 @@ -- require("keybinds.lua") hl.monitor({ output = "desc:Lenovo Group Limited 0x41A0", mode = "highrr", position = "0x0", scale = "1.0" }) +hl.monitor({ output = "desc:Samsung Display Corp. 0x4143", mode = "highrr", position = "0x0", scale = "2" }) hl.monitor({ output = "desc:LG Electronics LG HDR 4K 406NTZN74597", mode = "preferred", position = "auto-right", scale = "1.333333" }) hl.monitor({ output = "desc:Ancor Communications Inc ASUS MG28U 0x00009B77", mode = "preferred", position = "auto-right", scale = "1.333333" }) -hl.monitor({ output = "eDP-1", mode = "preferred", position = "0x0", scale = "1.0" }) +-- hl.monitor({ output = "eDP-1", mode = "preferred", position = "0x0", scale = "1.0" }) hl.monitor({ output = "desc:LG Electronics LG HDR WQHD 0x0006530C", mode = "preferred", position = "auto-up", scale = "1.333333" }) hl.monitor({ output = "CAP Capture 0x00000001", mode = "1920x1080@60", position = "auto-down", scale = 1 }) diff --git a/config/mise/config.toml b/config/mise/config.toml index c806191..b500ce8 100644 --- a/config/mise/config.toml +++ b/config/mise/config.toml @@ -4,7 +4,6 @@ experimental = true [tools] age = "latest" bun = "latest" -"cargo:cargo-llvm-cov" = "latest" codex = "latest" copilot-cli = "latest" "github:ZinoKader/portal" = "latest" @@ -18,3 +17,18 @@ herdr = "latest" opencode = "latest" pi = "latest" worktrunk = "latest" + +[tasks.setup_pi] +run = [ + 'pi install npm:pi-lens', + 'pi install npm:pi-native-search', + 'pi install npm:@tintinweb/pi-subagents', + 'pi install npm:context-mode', + 'pi install npm:@gotgenes/pi-permission-system', + 'test -x /usr/bin/pass && /usr/bin/pass show agent/pi/auth.json > ~/.pi/agent/auth.json' +] + +[tasks.setup_nvim] +run = [ + 'uv tool install vectorcode' +] diff --git a/config/nvim-old/after/compiler/cargo.vim b/config/nvim-old/after/compiler/cargo.vim deleted file mode 100644 index 2ee5606..0000000 --- a/config/nvim-old/after/compiler/cargo.vim +++ /dev/null @@ -1,8 +0,0 @@ -" Override cargo compiler defaults -setlocal makeprg=cargo\ build\ --message-format=short - -setlocal errorformat= - \%f:%l:%c:\ %t%*[^:]:\ %m, - \%f:%l:%c:\ %m, - \%f:%l:\ %t%*[^:]:\ %m, - \%f:%l:\ %m diff --git a/config/nvim-old/after/compiler/cmake.vim b/config/nvim-old/after/compiler/cmake.vim deleted file mode 100644 index 17faff7..0000000 --- a/config/nvim-old/after/compiler/cmake.vim +++ /dev/null @@ -1,2 +0,0 @@ -let current_compiler = "cmake" -CompilerSet makeprg=cmake \ No newline at end of file diff --git a/config/nvim-old/after/compiler/npm.vim b/config/nvim-old/after/compiler/npm.vim deleted file mode 100644 index b702788..0000000 --- a/config/nvim-old/after/compiler/npm.vim +++ /dev/null @@ -1,2 +0,0 @@ -let current_compiler = "npm" -CompilerSet makeprg=npm\ run \ No newline at end of file diff --git a/config/nvim-old/ftplugin/http.lua b/config/nvim-old/ftplugin/http.lua deleted file mode 100644 index d18816a..0000000 --- a/config/nvim-old/ftplugin/http.lua +++ /dev/null @@ -1,30 +0,0 @@ -vim.api.nvim_buf_set_keymap( - 0, - "n", - "", - "lua require('kulala').run()", - { noremap = true, silent = true, desc = "Execute the request" } -) - -vim.api.nvim_buf_set_keymap( - 0, - "n", - "[", - "lua require('kulala').jump_prev()", - { noremap = true, silent = true, desc = "Jump to the previous request" } -) -vim.api.nvim_buf_set_keymap( - 0, - "n", - "]", - "lua require('kulala').jump_next()", - { noremap = true, silent = true, desc = "Jump to the next request" } -) - -vim.api.nvim_buf_set_keymap( - 0, - "n", - "i", - "lua require('kulala').inspect()", - { noremap = true, silent = true, desc = "Inspect the current request" } -) \ No newline at end of file diff --git a/config/nvim-old/init.lua b/config/nvim-old/init.lua deleted file mode 100644 index 211669c..0000000 --- a/config/nvim-old/init.lua +++ /dev/null @@ -1,163 +0,0 @@ --- Steve Beaulac nvim configuration using kickstart git: 2ba39c6 -- -vim.g.mapleader = ' ' -vim.g.maplocalleader = ' ' - -vim.g.have_nerd_fonts = true - --- set as my leader key -vim.g.autoformat = true - --- vim.g.root_spec = { "lsp", { ".git", "lua" }, "cwd" } - -vim.g.editorconfig = true - -vim.wo.number = true - -vim.opt.background = "dark" -vim.opt.backup = false -vim.opt.clipboard:append("unnamedplus") -vim.opt.modifiable = true -vim.opt.cmdheight = 1 -vim.opt.completeopt = { 'menuone', 'noinsert', 'noselect', 'fuzzy', 'popup' } -vim.opt.conceallevel = 0 --- vim.opt.concealcursor = "" -vim.opt.encoding = "UTF-8" -vim.opt.lazyredraw = true -vim.opt.redrawtime = 10000 -vim.opt.maxmempattern = 20000 -vim.opt.synmaxcol = 300 -vim.opt.pumheight = 10 -vim.opt.pumblend = 10 -vim.opt.winblend = 0 -vim.opt.hlsearch = true -vim.opt.breakindent = true -vim.opt.ignorecase = true -vim.opt.backspace = "indent,eol,start" -vim.opt.formatoptions = "jcroqlnt" -vim.opt.grepformat = "%f:%l:%c:%m" -vim.opt.grepprg = "rg --vimgrep" -vim.opt.ignorecase = true -vim.opt.inccommand = "split" -vim.opt.list = true -vim.opt.listchars = { tab = "» ", trail = "·", nbsp = "␣" } -vim.opt.mouse = "a" -vim.opt.pumblend = 10 -vim.opt.pumheight = 10 -vim.opt.showmode = false -vim.opt.showmatch = true -vim.opt.showtabline = 0 -vim.opt.smartcase = true -vim.opt.smartindent = true -vim.opt.splitbelow = true -vim.opt.splitright = true --- vim.opt.splitkeep = "screen" -vim.opt.swapfile = false -vim.opt.termguicolors = true -vim.opt.undofile = true -vim.opt.undolevels = 10000 -vim.opt.updatetime = 250 -- default 250 -vim.opt.timeoutlen = 500 -- default 1000 -vim.opt.ttimeoutlen = 0 --- vim.opt.timeout = false -vim.opt.autoread = true -vim.opt.autowrite = false -vim.opt.autochdir = false -vim.opt.writebackup = false -vim.opt.expandtab = true -vim.opt.shiftround = true -vim.opt.shiftwidth = 4 -vim.opt.softtabstop = 4 -vim.opt.tabstop = 4 -vim.opt.hidden = true -vim.opt.shortmess:append({ W = true, I = true, c = true, C = true }) -vim.opt.spelllang = { "en" } -vim.opt.selection = "inclusive" -vim.opt.cursorline = true -vim.opt.number = true -vim.opt.relativenumber = true -vim.opt.laststatus = 3 -vim.opt.showcmd = false -vim.opt.ruler = false -vim.opt.numberwidth = 4 -vim.opt.signcolumn = "yes" -vim.opt.wrap = false -vim.opt.scrolloff = 8 -vim.opt.sidescrolloff = 8 -vim.opt.shell = "/bin/bash" -vim.opt.sessionoptions = { "blank", "buffers", "curdir", "tabpages", "winsize", "winpos", "terminal", "localoptions", "help", "skiprtp", "folds" } -vim.opt.virtualedit = "block" -vim.opt.wildmode = "longest:full,full" -vim.opt.diffopt:append("linematch:60") - -vim.opt.winminwidth = 5 --- vim.opt.hidden = false --- vim.opt.cindent = true --- vim.opt.autoindent = true - -if vim.fn.has("nvim-0.10") == 1 then - vim.opt.smoothscroll = true -end - -vim.opt.foldmethod = "expr" -vim.opt.foldexpr = "v:lua.vim.treesitter.foldexpr()" -vim.opt.foldlevel = 99 -vim.opt.errorbells = false -vim.opt.belloff = "all" -vim.opt.undodir = vim.fn.stdpath('data') .. "/undodir" -vim.opt.incsearch = true -vim.opt.fillchars = { eob = " " } -vim.opt.iskeyword:append("-") -vim.opt.path:append("**") -vim.opt.colorcolumn = "100" - -vim.diagnostic.config({ - virtual_text = { current_line = true } -}) - --- Lazy plugin manager -local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" -if not (vim.uv or vim.loop).fs_stat(lazypath) then - local lazyrepo = 'https://github.com/folke/lazy.nvim.git' - local out = vim.fn.system { 'git', 'clone', '--filter=blob:none', lazyrepo, '--branch=stable', lazypath } - if vim.v.shell_error ~= 0 then - error('Error cloning lazy.nvim:\n' .. out) - end -end -vim.opt.rtp:prepend(lazypath) - -require("lazy").setup({ - spec = { - { import = "plugins" } - }, - rocks = { - enabled = false, - hererocks = false, - }, - checker = { - enabled = true, - notify = false, - }, - change_detection = { - notify = false, - }, -}) - -vim.g.lazyvim_check_order = false - - -require("config.keymaps") -require("config.scripts") - --- When Nvim is idle or you switch focus/buffers, check if files changed -vim.api.nvim_create_autocmd({ "FocusGained", "BufEnter", "CursorHold", "CursorHoldI" }, { - pattern = "*", - command = "checktime", -}) - -vim.api.nvim_create_autocmd("User", { - pattern = "VeryLazy", - callback = function() - require("config.autocmds") - end, -}) - diff --git a/config/nvim-old/json_snippets/copyright.json b/config/nvim-old/json_snippets/copyright.json deleted file mode 100644 index 62f47c3..0000000 --- a/config/nvim-old/json_snippets/copyright.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "gCopyright": { - "prefix": "copy", - "description": "Generic Copyright", - "body": [ - "Copyright (c) ${CURRENT_YEAR} ${1:Author} <${2:email}>. All Rights Reserved.", - "$0" - ] - } -} \ No newline at end of file diff --git a/config/nvim-old/json_snippets/json.json b/config/nvim-old/json_snippets/json.json deleted file mode 100644 index 97f26fe..0000000 --- a/config/nvim-old/json_snippets/json.json +++ /dev/null @@ -1,49 +0,0 @@ -{ - "Starter Template": { - "prefix": "vsTaskHeader", - "body": [ - "{", - "\t\"version\": \"2.0.0\",", - "\t\"tasks\": [", - "\t\t$0", - "\t]", - "}" - ], - "scope": "json" - }, - "Tasks": { - "prefix": "vsTasks", - "body": [ - "{", - "\t\"label\": \"$1\",", - "\t\"type\": \"shell\",", - "\t\"command\": \"$2\",", - "\t\"args\": [ $3 ],", - "\t\"group\": {", - "\t\t\"kind\": \"build\",", - "\t\t\"isDefault\": true", - "\t}$0", - "}" - ], - "scope": "json" - }, - "Presentation": { - "prefix": "presentation", - "body": [ - "\"presentation\": {", - "\t\"reveal\": \"always\",", - "\t\"panel\": \"new\",", - "}" - ], - "scope": "json" - }, - "ProblemMatcher": { - "prefix": "problemMatcher", - "body": [ - "\"problemMatcher\": [", - "\t$0", - "]" - ], - "scope": "json" - } -} \ No newline at end of file diff --git a/config/nvim-old/json_snippets/package.json b/config/nvim-old/json_snippets/package.json deleted file mode 100644 index cf8ee78..0000000 --- a/config/nvim-old/json_snippets/package.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "sjb_snippets", - "contributes": { - "snippets": [ - { - "language": [ - "json" - ], - "path": "./json.json" - }, - { - "language": [ - "rust", - "global", - "all" - ], - "path": "./copyright.json" - } - ] - } - } \ No newline at end of file diff --git a/config/nvim-old/lua/config/autocmds.lua b/config/nvim-old/lua/config/autocmds.lua deleted file mode 100644 index 066601d..0000000 --- a/config/nvim-old/lua/config/autocmds.lua +++ /dev/null @@ -1,143 +0,0 @@ -vim.filetype.add({ - extension = { - ['http'] = 'http', - }, -}) - --- Check if we need to reload the file when it changed -vim.api.nvim_create_autocmd({ "FocusGained", "TermClose", "TermLeave" }, { - desc = 'Check time', - group = vim.api.nvim_create_augroup("sjb-checktime", { clear = true}), - callback = function() - if vim.o.buftype ~= 'nofile' then - vim.cmd('checktime') - end - end, -}) - -vim.api.nvim_create_autocmd('TextYankPost', { - desc = 'Highlight when yanking (copying) text', - group = vim.api.nvim_create_augroup('sjb-highlight-yank', { clear = true }), - callback = function() - vim.hl.on_yank() - end, -}) - --- windows to close -vim.api.nvim_create_autocmd("FileType", { - pattern = { - "OverseerForm", - "OverseerList", - "floggraph", - "fugitive", - "git", - "help", - "lspinfo", - "man", - "neotest-output", - "neotest-summary", - "qf", - "query", - "spectre_panel", - "startuptime", - "toggleterm", - "tsplayground", - "vim", - }, - group = vim.api.nvim_create_augroup('sjb-quick-close', { clear = true }), - callback = function(event) - vim.bo[event.buf].buflisted = false - vim.keymap.set("n", "q", "close", { buffer = event.buf, silent = true }) - end, -}) - --- wrap and check for spell in text filetypes -vim.api.nvim_create_autocmd("FileType", { - group = vim.api.nvim_create_augroup("sjb-wrap-spell", { clear = true }), - pattern = { "gitcommit", "markdown" }, - callback = function() - vim.opt_local.wrap = true - vim.opt_local.spell = true - end, -}) - --- Auto create dir when saving a file, in case some intermediate directory does not exist -vim.api.nvim_create_autocmd({ "BufWritePre" }, { - group = vim.api.nvim_create_augroup("sjb-auto-create-dir", { clear = true}), - callback = function(event) - if event.match:match("^%w%w+://") then - return - end - local file = vim.loop.fs_realpath(event.match) or event.match - vim.fn.mkdir(vim.fn.fnamemodify(file, ":p:h"), "p") - end, -}) - -vim.api.nvim_create_autocmd("BufWritePost", { - pattern = "*", - callback = function() - if vim.fn.isdirectory(".jj") == 1 then - vim.fn.jobstart({"jj", "status"}, { - on_exit = function(_, exit_code) - if exit_code ~= 0 then - vim.notify("jj command failed", vim.log.levels.WARN) - end - end, - }) - end - end, -}) - -local gpgGroup = vim.api.nvim_create_augroup("customGpg", { clear = true }) - -vim.api.nvim_create_autocmd({ "BufReadPre", "FileReadPre" }, { - pattern = "*.gpg", - group = gpgGroup, - callback = function() - -- Make sure nothing is written to shada file while editing an encrypted file. - vim.opt_local.shada = nil - -- We don't want a swap file, as it writes unencrypted data to disk - vim.opt_local.swapfile = false - -- Switch to binary mode to read the encrypted file - vim.opt_local.bin = true - -- Save the current 'ch' value to a buffer-local variable - vim.b.ch_save = vim.opt_local.ch:get() - vim.cmd "set ch=2" - end, -}) - -vim.api.nvim_create_autocmd({ "BufReadPost", "FileReadPost" }, { - pattern = "*.gpg", - group = gpgGroup, - callback = function() - vim.cmd "'[,']!gpg --decrypt 2> /dev/null" - -- Switch to normal mode for editing - vim.opt_local.bin = false - -- Restore the 'ch' value from the buffer-local variable - vim.opt_local.ch = vim.b.ch_save - vim.cmd "unlet b:ch_save" - vim.cmd(":doautocmd BufReadPost " .. vim.fn.expand "%:r") - end, -}) - --- Convert all text to encrypted text before writing -vim.api.nvim_create_autocmd({ "BufWritePre", "FileWritePre" }, { - pattern = "*.gpg", - group = gpgGroup, - callback = function() - -- Switch to binary mode to write the encrypted file - vim.opt_local.bin = true - -- So we can avoid the armor option - vim.cmd("'[,']!gpg --default-recipient-self -e 2>/dev/null") - end, -}) --- Undo the encryption so we are back in the normal text, directly after the file has been written. -vim.api.nvim_create_autocmd({ "BufWritePost", "FileWritePost" }, { - pattern = "*.gpg", - group = gpgGroup, - callback = function() - vim.cmd("u") - -- Switch to normal mode for editing - vim.opt_local.bin = false - end, -}) \ No newline at end of file diff --git a/config/nvim-old/lua/config/keymaps.lua b/config/nvim-old/lua/config/keymaps.lua deleted file mode 100644 index 6ca8a7b..0000000 --- a/config/nvim-old/lua/config/keymaps.lua +++ /dev/null @@ -1,78 +0,0 @@ --- Keymaps for better default experience --- See `:help vim.keymap.set()` ---vim.keymap.set({ 'n', 'v' }, '', '', { silent = true }) - --- Remap for dealing with word wrap -vim.keymap.set('n', 'k', "v:count == 0 ? 'gk' : 'k'", { expr = true, silent = true }) -vim.keymap.set('n', 'j', "v:count == 0 ? 'gj' : 'j'", { expr = true, silent = true }) - -vim.keymap.set("v", "J", ":m '>+1gv=gv") -vim.keymap.set("v", "K", ":m '<-2gv=gv") - --- save file --- vim.keymap.set({ "i", "x", "n", "s" }, "", "w", { desc = "Save file" }) --- vim.keymap.set({ "i", "x", "n", "s" }, "", ":qall", { desc = "Save file" }) - --- better indenting -vim.keymap.set("v", "<", "", ">gv") - --- better jumps -vim.keymap.set("n", "", "zz") -vim.keymap.set("n", "", "zz") -vim.keymap.set("n", "", "zz") -vim.keymap.set("n", "", "zz") - -vim.keymap.set("i", "", "", { noremap = true, silent = true }) -vim.keymap.set("i", "", "", { noremap = true, silent = true }) -vim.keymap.set("i", "", "", { noremap = true, silent = true }) - --- Paste over currently selected text without yanking it -vim.keymap.set("v", "p", '"_dP') - -vim.keymap.set("n", "p", [["_dP]], { desc = "Paste over currently selected text without yanking it" }) - -vim.keymap.set("n", "Y", [["+Y]], { noremap = true, silent = true }) -vim.keymap.set({ "n", "v" }, "y", [["+y]], { noremap = true, silent = true }) - -vim.keymap.set({"n", "v"}, "d", [["_d]], { noremap = true, silent = true }) - --- new file -vim.keymap.set("n", "bn", "enew", { desc = "New File" }) --- vim.keymap.set("n", "bd", "bdelete", { desc = "Unload Buffer" }) - -vim.keymap.set("n", "`", "e #", { desc = "Switch to Other Buffer" }) -vim.keymap.set("n", "bc", "tabclose", { desc = "Close Tab" }) - --- Clear search with -vim.keymap.set('n', '', 'nohlsearch', { desc = "clear hlsearch" }) --- vim.keymap.set("n", "", "nohlsearch", { desc = "clear hlsearch" }) - --- Diagnostic keymaps -vim.keymap.set('n', 'cl', vim.diagnostic.setloclist, { desc = 'Send diagnostic to location list' }) -vim.keymap.set("n", "cq", vim.diagnostic.setqflist, { desc = "Send diagnostic to Quickfix" }) --- vim.keymap.set("n", "gq", "copen", { desc = "Quickfix List" }) --- vim.keymap.set("n", "gl", "lopen", { desc = "Location List" }) - -vim.keymap.set('n', 'eb', ".w !bash -e", { desc = "Send line to bash" }) -vim.keymap.set('n', 'eB', "%w !bash -e", { desc = "Send buffer to bash" }) -vim.keymap.set('n', 'e.', ".!bash -e", { desc = "Execute current line" }) -vim.keymap.set('n', 'e%', "% !bash -e", { desc = "Execute current buffer" }) -vim.keymap.set('n', 'ex', "!chmod +x %", { desc = "Make file executable" }) - -vim.keymap.set('n', "eL", "source %", { desc = "Source current buffer" }) -vim.keymap.set('n', "el", ".lua", { desc = "Source current line" }) -vim.keymap.set('v', "el", "lua", { desc = "Source current line" }) -vim.keymap.set('n', 'xu', 'Lazy sync', { desc = 'Lazy sync' }) - - -vim.keymap.set("n", "cx", function() - local file = vim.fn.expand "%" - local line = vim.fn.line "." - vim.fn.setreg("+", string.format("%s:%d", file, line)) - vim.notify "Copied line reference to clipboard" - end, { desc = "Copy line reference to clipboard" }) - -vim.keymap.set("n", "ktn", require('tasks').create_new_task, { desc = "create new task" } ) -vim.keymap.set("n", "kts", require('tasks').start_task, { desc = "start task" } ) -vim.keymap.set("n", "kte", require('tasks').stop_task, { desc = "stop task" } ) diff --git a/config/nvim-old/lua/config/scripts.lua b/config/nvim-old/lua/config/scripts.lua deleted file mode 100644 index 6d0917a..0000000 --- a/config/nvim-old/lua/config/scripts.lua +++ /dev/null @@ -1,33 +0,0 @@ -function R(name) - require("plenary.reload").reload_module(name) - end - - function websearch(url, o) - -- Get visual selection or prompt for search - local search_term - - -- Check if there's a visual selection - if vim.fn.mode() == 'v' or vim.fn.mode() == 'V' then - -- Get the visual selection - local start_pos = vim.fn.getpos("'<") - local end_pos = vim.fn.getpos("'>") - local lines = vim.fn.getline(start_pos[2], end_pos[2]) - local selected_text = table.concat(lines, " ") - search_term = selected_text - else - search_term = (o and o.args) or vim.fn.input("Search: ") - end - - -- Encode the search term for URLs - local escaped = vim.uri_encode(search_term) - - -- Construct and execute the search URL - local search_url = (url):format(escaped) - - vim.ui.open(search_url) - end - -- Command to call the search function - vim.api.nvim_create_user_command('DuckDuckGo', function(o) websearch('https://duckduckgo.com/?q=%s', o) end, { nargs = 1 }) - vim.api.nvim_create_user_command('Docsrs', function(o) websearch('https://docs.rs/%s', o) end, { nargs = 1}) - vim.api.nvim_create_user_command('RustStd', function(o) websearch('https://doc.rust-lang.org/std/?search=%s', o) end, { nargs = 1}) - vim.keymap.set({ 'n', 'v'}, 'sW', function() websearch('https://duckduckgo.com/?q=%s', null) end, { desc = "Search on DuckDuckGo" }) \ No newline at end of file diff --git a/config/nvim-old/lua/overseer/template/user/cmake_build.lua b/config/nvim-old/lua/overseer/template/user/cmake_build.lua deleted file mode 100644 index 30adc24..0000000 --- a/config/nvim-old/lua/overseer/template/user/cmake_build.lua +++ /dev/null @@ -1,17 +0,0 @@ -return { - name = "CMake Build", - builder = function() - return { - cmd = { "cmake" }, - args = { "--build", "build", "--target", "all" }, - components = { - { "on_output_quickfix", set_diagnostics = true }, - "on_result_diagnostics", - "default", - }, - } - end, - condition = { - filetype = { "cpp", "c" }, - }, -} \ No newline at end of file diff --git a/config/nvim-old/lua/overseer/template/user/cmake_create.lua b/config/nvim-old/lua/overseer/template/user/cmake_create.lua deleted file mode 100644 index 0b4c8c1..0000000 --- a/config/nvim-old/lua/overseer/template/user/cmake_create.lua +++ /dev/null @@ -1,17 +0,0 @@ -return { - name = "CMake Create", - builder = function() - return { - cmd = { "cmake" }, - args = { "-B", "build", "-S", "." }, - components = { - { "on_output_quickfix", set_diagnostics = true }, - "on_result_diagnostics", - "default", - }, - } - end, - condition = { - filetype = { "cpp", "c" }, - }, -} \ No newline at end of file diff --git a/config/nvim-old/lua/overseer/template/user/init.lua b/config/nvim-old/lua/overseer/template/user/init.lua deleted file mode 100644 index 67463d8..0000000 --- a/config/nvim-old/lua/overseer/template/user/init.lua +++ /dev/null @@ -1 +0,0 @@ -return { "user.cmake_create", "user.cmake_build" } \ No newline at end of file diff --git a/config/nvim-old/lua/overseer/template/vscode/provider/rustc.lua b/config/nvim-old/lua/overseer/template/vscode/provider/rustc.lua deleted file mode 100644 index 46cf4c2..0000000 --- a/config/nvim-old/lua/overseer/template/vscode/provider/rustc.lua +++ /dev/null @@ -1,34 +0,0 @@ -local M = {} - -M.problem_patterns = { - ["$rustc"] = { - { - regexp = "^(error|warning)(\\[E\\d+\\])*:(.*)$", - message = 3 - }, - { - regexp = "^\\s+-+>\\s*([^:]*):(\\d+):(\\d+)$", - kind = "location", - file = 1, - line = 2, - column = 3 - }, - { - regexp = "^(\\s|\\d)+(\\||=).*$" - }, - { - regexp = "^$" - } - } -} - -M.problem_matchers = { - ["$rustc"] = { - fileLocation = { "relative", "${cwd}" }, - pattern = "$rustc", - - - } -} -return M - \ No newline at end of file diff --git a/config/nvim-old/lua/plugins/ai.lua b/config/nvim-old/lua/plugins/ai.lua deleted file mode 100644 index 7457769..0000000 --- a/config/nvim-old/lua/plugins/ai.lua +++ /dev/null @@ -1,864 +0,0 @@ -return { - { - "Davidyz/VectorCode", - version = "*", - build = "uv tool upgrade vectorcode", -- This helps keeping the CLI up-to-date - -- build = "pipx upgrade vectorcode", -- If you used pipx to install the CLI - dependencies = { "nvim-lua/plenary.nvim" }, - }, - { - "olimorris/codecompanion.nvim", - version = "^18.0.0", - opts = {}, - dependencies = { - "nvim-lua/plenary.nvim", - "franco-ruggeri/codecompanion-spinner.nvim", - "ravitemer/codecompanion-history.nvim", - "cairijun/codecompanion-agentskills.nvim", - "ttgrules/cc-adapter-copilot-cli-acp", - }, - event = "VeryLazy", - keys = { - { "rct", "CodeCompanionChat Toggle", mode = {'n', 'v'}, { noremap = true, silent = true }, desc = "CC Toggle" }, - { "rca", "CodeCompanionActions", mode = { 'n', 'v' }, { noremap = true, silent = true }, desc = "CC Action" }, - { "rce", "CodeCompanion Explain", mode = { 'n' }, desc = "CC Explain" }, - { "rcf", "CodeCompanion Fix code", mode = { 'n' }, desc = "CC fix" }, - { "rcc", "CodeCompanionChat Add", mode = { 'v' }, { noremap = true, silent = true }, desc = "CC Add" }, - { 'rcr', 'CodeCompanion Code Review', mode = { 'v' }, desc = 'Code Review' }, - { 'rco', 'CodeCompanion Optimize Performance', mode = { 'v' }, desc = 'Optimize Code' }, - { 'rce', 'CodeCompanion Explain Code', mode = { 'v' }, desc = 'Explain Code' }, - { 'rcg', 'CodeCompanion Generate Tests', mode = { 'v' }, desc = 'Generate Tests' }, - { 'rcd', 'CodeCompanion Debug Analysis', mode = { 'v' }, desc = 'Debug Analysis' }, - }, - config = function() - local function get_abacus_key() - local handle = io.popen("pass show abacus.ai-api") - if not handle then return "" end - local result = handle:read("*a") - handle:close() - -- Remove trailing newline that 'pass' often adds - return result:gsub("%s+", "") - end - - local codecompanion = require("codecompanion") - codecompanion.setup({ - adapters = { - http = { - opts = { - show_presets = true, - show_model_choices = true, - }, - -- openai = function() - -- return require("codecompanion.adapters").extend("openai", { - -- env = { api_key = "cmd:pass show api.openai.com" } - -- }) - -- end, - openrouter = function() - return require("codecompanion.adapters").extend("openai_compatible", { - env = { - url = "https://openrouter.ai/api", - api_key = "OPENROUTER_API_KEY", - chat_url = "/v1/chat/completions", - }, - schema = { - model = { - default = "anthropic/claude-3.7-sonnet", - }, - }, - }) - end, - abacus = function() - return require("codecompanion.adapters").extend("openai_compatible", { - name = "abacus", - formatted_name = "Abacus.AI", - env = { - url = "https://routellm.abacus.ai/v1", - -- IMPORTANT: include /v1 in the base url - api_key = get_abacus_key(), - chat_url = "/chat/completions" - }, - headers = { - ["Content-Type"] = "application/json", - ["Authorization"] = "Bearer ${api_key}", - }, - schema = { - model = { - order = 1, - mapping = "parameters", - type = "enum", - desc = "The model to use for chat completions.", - default = "route-llm", - choices = { - -- Routing Model - ["route-llm"] = { opts = { desc = "Intelligent routing to best model" } }, - - -- OpenAI Models - ["gpt-5.2"] = { opts = { has_vision = true } }, - ["gpt-5.1"] = { opts = { has_vision = true } }, - ["gpt-5.1-chat-latest"] = { opts = { has_vision = true } }, - ["gpt-5"] = { opts = { has_vision = true } }, - ["gpt-5-mini"] = { opts = { has_vision = true } }, - ["gpt-5-nano"] = { opts = { has_vision = true } }, - ["gpt-4o"] = { opts = { has_vision = true } }, - ["gpt-4o-mini"] = { opts = { has_vision = true } }, - ["o4-mini"] = { opts = { can_reason = true } }, - ["o3"] = { opts = { can_reason = true } }, - ["o3-pro"] = { opts = { can_reason = true } }, - - -- Anthropic Models - ["claude-4-5-sonnet"] = { opts = { has_vision = true } }, - ["claude-4-5-haiku"] = { opts = { has_vision = true } }, - ["claude-4-5-opus"] = { opts = { has_vision = true } }, - ["claude-3-opus"] = { opts = { has_vision = true } }, - - -- Google Models - ["gemini-3-pro"] = { opts = { has_vision = true } }, - ["gemini-3-flash"] = { opts = { has_vision = true } }, - ["gemini-2.5-pro"] = { opts = { has_vision = true } }, - ["gemini-2.5-flash"] = { opts = { has_vision = true } }, - - -- xAI Models - ["grok-4-1-fast"] = {}, - ["grok-4"] = {}, - ["grok-code-fast-1"] = {}, - - -- Meta Models - ["llama-4-Maverick-17B"] = {}, - ["llama-3.1-405B"] = {}, - ["llama-3.1-70B"] = {}, - - -- DeepSeek Models - ["deepseek-v3.2"] = {}, - ["deepseek-v3.1-Terminus"] = {}, - ["deepseek-R1"] = { opts = { can_reason = true } }, - - -- Qwen Models - ["qwen-3-Max"] = {}, - ["qwen3-coder-480b-a35b-instruct"] = {}, - ["qwen-3-32B"] = {}, - ["qwq-32B"] = { opts = { can_reason = true } }, - }, - }, - temperature = { - order = 2, - mapping = "parameters", - type = "number", - optional = true, - default = 1.0, - desc = "Controls randomness of output (0-2).", - validate = function(n) - return n >= 0 and n <= 2, "Must be between 0 and 2" - end, - }, - max_tokens = { - order = 3, - mapping = "parameters", - type = "integer", - optional = true, - default = nil, - desc = "Maximum tokens to generate.", - validate = function(n) - return n > 0, "Must be greater than 0" - end, - }, - top_p = { - order = 4, - mapping = "parameters", - type = "number", - optional = true, - default = 1.0, - desc = "Nucleus sampling parameter (0-1).", - validate = function(n) - return n >= 0 and n <= 1, "Must be between 0 and 1" - end, - }, - }, - }) - end, - ollama = function() - return require("codecompanion.adapters").extend("ollama", { - env = { - url = "http://129.100.33.66:11434", - }, - schema = { - model = { - default = "qwen3.5", -- change to whatever you pulled - }, - }, - }) - end, - copilot = function() - return require("codecompanion.adapters").extend("copilot", { - schema = { - model = { - default = "gpt-5-mini", -- Consistent model choice - }, - max_tokens = { - default = 16284, - } - } - }) - end, - }, - acp = { - opts = { - show_presets = true, - }, - copilot_cli = function() - return require("codecompanion.adapters").extend("copilot_cli", {}) - end, - codex = function() - return require("codecompanion.adapters").extend("codex", { - commands = { - default = { "codex-acp" }, - }, - schema = { - model = { - default = "github-copilot/gpt-5.2-codex", - }, - }, - defaults = { - timeout = 20000, - auth_method = "chatgpt", -- "openai-api-key"|"codex-api-key"|"chatgpt" - }, - }) - end, - opencode = function() - return require("codecompanion.adapters").extend("codex", { - commands = { - default = { "opencode", "acp" }, - }, - schema = { - model = { - default = "github-copilot/gpt-5.2-codex", - }, - }, - defaults = { - timeout = 20000, - auth_method = "chatgpt", -- "openai-api-key"|"codex-api-key"|"chatgpt" - }, - }) - end, - }, - }, - rules = { - opts = { - chat = { - enabled = true, - autoload = { "default" } - }, - }, - }, - opts = { - send_code = true, - log_level = "WARN", -- Change to DEBUG for troubleshooting - language = "English", - -- NEW: Performance improvements - job_start_delay = 500, -- Reduced from default 1500ms - submit_delay = 1000, -- Reduced from default 2000ms - }, - extensions = { - spinner = {}, - -- ddgr_search = { - -- opts = { - -- require_approval_before = false, - -- }, - -- }, - agentskills = { - opts = { - { "~/Documents/ai-skills", recursive = true }, - }, - }, - -- vectorcode = { lazy = true }, - history = { - lazy = true, - enabled = true, - opts = { - keymap = "ghf", - save_chat_keymap = "ghs", - picker = "snacks", - dir_to_save = vim.env.HOME .. "/Documents/ai-history", - title_generation_opts = { - adapter = "copilot", - model = "gpt-5-mini", - }, - summary = { - create_summary_keymap = "ghc", - browse_summaries_keymap = "ghb", - }, - }, - }, - -- mcphub = { - -- callback = "mcphub.extensions.codecompanion", - -- opts = { - -- make_vars = true, - -- make_slash_commands = true, - -- show_result_in_chat = true, - -- }, - -- }, - }, - interactions = { - chat = { - variables = { - project = { - callback = function() - -- Get project files structure - local files = vim.fn.systemlist("fd . -type f") - return table.concat(files, "\n") - end, - description = "Share project structure" - } - }, - tools = { - opts = { - auto_submit_errors = true, -- Send any errors to the LLM automatically? - auto_submit_success = true, -- Send any successful output to the LLM automatically? - system_prompt = { - enabled = true, - replace_main_system_prompt = false, - }, - default_tools = { - "file_search", - "read_file", - "cmd_runner", - -- "ddgr_search", - }, - }, - ["fetch_enhanced"] = { - callback = function(url, options) - options = options or {} - local max_length = options.max_length or 200000 -- 200KB default - local timeout = options.timeout or 60 - - -- Use curl for better control - local cmd = string.format( - 'curl -L -s --max-time %d --user-agent "CodeCompanion-Neovim" "%s"', - timeout, - url - ) - - local handle = io.popen(cmd) - if not handle then - return nil, "Failed to execute curl" - end - - local result = handle:read("*a") - local success = handle:close() - - if not success then - return nil, "Curl command failed" - end - - -- Truncate if too long - if #result > max_length then - result = result:sub(1, max_length) .. "\n[... truncated at " .. max_length .. " characters ...]" - end - - return result - end, - opts = { - requires_approval = false, - } - }, - ["fetch_unlimited"] = { - description = "Fetch a data from the web", - callback = function(url, options) - options = options or {} - - -- Use a local proxy service or direct system calls - local temp_file = vim.fn.tempname() - local cmd = string.format( - 'wget --timeout=60 --tries=3 --output-document="%s" "%s" 2>/dev/null && cat "%s" && rm "%s"', - temp_file, url, temp_file, temp_file - ) - - local handle = io.popen(cmd) - if not handle then - return nil, "Failed to fetch URL" - end - - local result = handle:read("*a") - handle:close() - - -- Optional: Process and clean the content - -- Remove excessive whitespace, clean HTML if needed - -- result = result:gsub("%s+", " "):gsub("^\s+", ""):gsub("%s+$", "") - - return result - end, - opts = { - requires_approval = false, - description = "Fetch web content with unlimited size" - } - }, - ["fetch"] = { - description = "Fetch a webpage in a markdown format", - callback = function(url, options) - local cmd = string.format( - 'reader -o -i none %s 2>/dev/null', - url - ) - local handle = io.popen(cmd) - if not handle then - return nil, "Failed to fetch URL" - end - - local result = handle:read("*a") - handle:close() - - return result - end, - }, - -- ["mcp"] = { -- Name this tool whatever you like - -- -- Callback provides the necessary functions to CodeCompanion - -- callback = function() - -- return require("mcphub.extensions.codecompanion") - -- end, - -- opts = { - -- -- If true, CodeCompanion will ask for approval before executing the MCP tool call - -- requires_approval = true, - -- -- Optional: Pass parameters like temperature to the underlying LLM if the chat strategy supports it - -- temperature = 0.7 - -- } - -- }, - groups = { - ['plan'] = { - description = "Planning my project and codes with enhanced web access", - prompt = "Using all the ${tools} at your disposal including enhanced web fetching. Analyze the codes and use it to help me with my query. You have access to unlimited web content fetching.", - tools = { - "fetch", -- Backup unlimited fetch - "file_search", - "grep_search", - "list_code_usages", - "next_edit_suggestion", - "read_file", - "cmd_runner", - }, - opts = { - collapse_tools = true, - -- Override default fetch behavior for this group - tool_config = { - fetch_enhanced = { - max_length = 500000, -- 500KB for planning tasks - chunk_processing = true, - }, - }, - }, - }, - ['research'] = { - description = "Deep research with unlimited web access", - prompt = "You are a research assistant with unlimited web access. Using the ${tools} fetch and analyze large documents, research papers, and comprehensive web content.", - tools = { - "fetch", - "fetch_enhanced", - "file_search", - "read_file", - }, - opts = { - collapse_tools = false, - }, - }, - -- NEW: Add development group for coding tasks - ['dev'] = { - description = "Full-stack development with all necessary tools", - prompt = "You are an expert full-stack developer. Use ${tools} to understand, modify, and test code. Always gather context before making changes.", - tools = { - "file_search", - "grep_search", - "fetch", - "list_code_usages", - "read_file", - "insert_edit_into_file", - "cmd_runner", - "next_edit_suggestion", - }, - opts = { - collapse_tools = true, - }, - }, - }, - }, - slash_commands = { - ["buffer"] = { opts = { provider = "snacks" } }, -- snacks - ["file"] = { opts = { provider = "snacks" } }, -- snackes - ['git_files'] = { - description = 'List git files', - ---@param chat CodeCompanion.Chat - callback = function(chat) - local handle = io.popen 'git ls-files' - if handle ~= nil then - local result = handle:read '*a' - handle:close() - chat:add_reference({ content = result }, 'git', '') - return vim.notify('Git files added to the chat.') - else - return vim.notify('No git files available', vim.log.levels.INFO, { title = 'CodeCompanion' }) - end - end, - opts = { - contains_code = false, - }, - }, - -- NEW: Add helpful workspace command - ["workspace"] = { - description = "Add workspace context", - callback = function(chat) - local cwd = vim.fn.getcwd() - local workspace_info = string.format("Working directory: %s", cwd) - - -- Get project type - local files = vim.fn.glob(cwd .. "/*", false, true) - for _, file in ipairs(files) do - local basename = vim.fn.fnamemodify(file, ":t") - if basename == "package.json" then - workspace_info = workspace_info .. "\nProject type: Node.js/JavaScript" - break - elseif basename == "Cargo.toml" then - workspace_info = workspace_info .. "\nProject type: Rust" - break - elseif basename == "go.mod" then - workspace_info = workspace_info .. "\nProject type: Go" - break - end - end - - chat:add_reference({ content = workspace_info }, 'workspace', '') - return vim.notify('Workspace context added.') - end, - opts = { - contains_code = false, - }, - }, - }, - -- adapter = { name = "abacus", model = "route-llm" }, - -- adapter = { name = "opencode", model = "github-copilot/gpt-5.2-codex" }, - adapter = { name = "copilot", model = "gpt-5-mini" }, - }, - inline = { - -- adapter = { name = "abacus", model = "route-llm" }, - adapter = { name = "copilot", model = "gpt-5.1-codex-mini" }, - }, - cmd = { - adapter = { name = "copilot", model = "gpt-5-mini" }, - }, - background = { - adapter = { name = "copilot", model = "gpt-5-mini" }, - }, - }, - prompt_library = { - markdown = { - dirs = { - vim.fn.getcwd() .. "/.prompts", - "~/.agents/prompts", - }, - }, - ["Code Review"] = { - interaction = "chat", - description = "Review the selected code for improvements", - opts = { - mapping = "rpc", - modes = { "v" }, - adapter = { - name = "copilot", - model = "chatgpt-5.1-codex", - }, - }, - prompts = { - { - role = "system", - content = "You are an expert code reviewer. Analyze the code for: 1) Logic errors 2) Performance issues 3) Security vulnerabilities 4) Best practices 5) Code clarity and maintainability. Provide specific, actionable feedback.", - }, - { - role = "user", - content = function(context) - local code = require("codecompanion.helpers.actions").get_code(context.start_line, context.end_line) - return "Please review this code:\n\n```" .. context.filetype .. "\n" .. code .. "\n```" - end, - }, - }, - cc_keywords = { "review", "critique", "smell", "security", "vulnerability", "best practice", "maintainab" }, - cc_threshold = 2, - }, - ["Optimize Performance"] = { - interaction = "chat", - description = "Get performance optimization suggestions", - opts = { - mapping = "rpo", - modes = { "v" }, - adapter = { - name = "copilot", - model = "chatgpt-5.2-codex", - }, - }, - prompts = { - { - role = "system", - content = "You are a performance optimization expert. Focus on: 1) Time complexity improvements 2) Space efficiency 3) Algorithm optimization 4) Framework-specific optimizations 5) Caching strategies.", - }, - { - role = "user", - content = function(context) - local code = require("codecompanion.helpers.actions").get_code(context.start_line, context.end_line) - return "How can I optimize the performance of this code?\n\n```" .. context.filetype .. "\n" .. code .. "\n```" - end, - }, - }, - cc_keywords = { "optimize", "performance", "slow", "latency", "throughput", "memory", "alloc" }, - }, - ["Debug Analysis"] = { - interaction = "chat", - description = "Analyze and debug problematic code", - opts = { - mapping = "rpd", - modes = { "v" }, - - adapter = { - name = "copilot", - model = "chatgpt-5.2-codex", - }, - }, - prompts = { - { - role = "system", - content = [[You are a debugging expert. Analyze code for: - 1. Potential bugs and issues - 2. Logic errors - 3. Runtime errors - 4. Common pitfalls - 5. Debugging strategies. - 6. Provide specific solutions.]], - }, - { - role = "user", - content = function(context) - local code = require("codecompanion.helpers.actions").get_code(context.start_line, context.end_line) - return fmt( - [[Help me debug this code from buffer %d and identify potential issues: - - ```%s - %s - ```]], - context.bufnr, - context.filetype, - code - ) - end, - opts = { - contains_code = true, - } - }, - }, - cc_keyword = { "bug", "debug", "error", "exception", "crash", "stacktrace", "broken", "issue" }, - }, - ["Architecture Review"] = { - interaction = "chat", - description = "Review architectural patterns and design", - opts = { - mapping = "rpa", - modes = { "v" }, - - adapter = { - name = "copilot", - model = "chatgpt-5.2-codex", - }, - }, - prompts = { - { - role = "system", - content = "You are a software architect. Review code for: 1) Design patterns usage 2) SOLID principles 3) Separation of concerns 4) Scalability considerations 5) Maintainability. Suggest architectural improvements.", - }, - { - role = "user", - content = function(context) - local code = require("codecompanion.helpers.actions").get_code(context.start_line, context.end_line) - return fmt( - [[Please review the architecture and design of this code from buffer %d: - - ```%s - %s - ```]], - context.bufnr, - context.filetype, - code - ) - end, - opts = { - contains_code = true, - } - }, - }, - cc_keywords = { "architecture", "design", "pattern", "solid", "scalab", "maintainab", "refactor" }, - }, - }, - display = { - action_palette = { - provider = "snacks", - opts = { - show_default_actions = true, - show_default_prompt_library = true, - } - }, - chat = { - show_settings = false, - render_headers = false, - icons = { - chat_context = "📎️", - }, - fold_context = true, - -- NEW: Better chat window configuration - window = { - layout = "vertical", - width = 0.45, - height = 0.8, - border = "rounded", -- Better visual - }, - auto_scroll = false, - start_in_insert_mode = false, -- More convenient - } - } - }) - end - }, - { - "carlos-algms/agentic.nvim", - opts = { - -- Available by default: "claude-agent-acp" | "gemini-acp" | "codex-acp" | "opencode-acp" | "cursor-acp" | "auggie-acp" | "mistral-vibe-acp" - provider = "opencode-acp", -- setting the name here is all you need to get started - keymaps = { - -- Keybindings for ALL buffers in the widget (chat, prompt, code, files) - widget = { - close = "q", -- String for a single keybinding - change_mode = { - { - "", - mode = { "i", "n", "v" }, -- Specify modes for this keybinding - }, - }, - switch_provider = "ras", -- Switch ACP provider - switch_model = "ram", -- Switch model - }, - - -- Keybindings for the prompt buffer only - prompt = { - submit = { - "", -- Normal mode, just Enter - { - "", - mode = { "n", "v", "i" }, - }, - }, - - paste_image = { - { - "p", - mode = { "n" }, - }, - { - "", -- Same as Claude-code in insert mode - mode = { "i" }, - } - }, - }, - - -- Keybindings for diff preview navigation - diff_preview = { - next_hunk = "]c", - prev_hunk = "[c", - }, - }, - }, - -- these are just suggested keymaps; customize as desired - keys = { - { - "rat", - function() require("agentic").toggle() end, - mode = { "n", "v", "i" }, - desc = "Toggle Agentic Chat" - }, - { - "", - function() require("agentic").add_selection_or_file_to_context() end, - mode = { "n", "v" }, - desc = "Add file or selection to Agentic to Context" - }, - { - "ran", - function() require("agentic").new_session() end, - mode = { "n", "v", "i" }, - desc = "New Agentic Session" - }, - { - "r", -- ai Restore - function() - require("agentic").restore_session() - end, - desc = "Agentic Restore session", - silent = true, - mode = { "n", "v", "i" }, - }, - { - "rad", -- ai Diagnostics - function() - require("agentic").add_current_line_diagnostics() - end, - desc = "Add current line diagnostic to Agentic", - mode = { "n" }, - }, - { - "raD", -- ai all Diagnostics - function() - require("agentic").add_buffer_diagnostics() - end, - desc = "Add all buffer diagnostics to Agentic", - mode = { "n" }, - }, - }, - }, - { - "zbirenbaum/copilot.lua", - dependencies = { - "copilotlsp-nvim/copilot-lsp", - config = function() - vim.g.copilot_nes_debounce = 500 - end, - }, - cmd = "Copilot", - event = "InsertEnter", - config = function() - require('copilot').setup({ - nes = { - enabled = false, - keymap = { - accept_and_goto = "", - accept = false, - dismiss = "", - }, - }, - panel = { - enabled = false, - }, - }) - end, - }, - { - "PhantomYdn/fabric-ai.nvim", - cmd = { "Fabric" }, - opts = { - -- Default configuration (all optional) - fabric_path = "fabric-ai", -- Path to Fabric CLI - patterns_path = nil, -- Custom patterns dir (auto-detect if nil) - timeout = 300000, -- Command timeout in ms (5 minutes) - window = { - width = 0.8, -- 80% of editor width - height = 0.8, -- 80% of editor height - border = "rounded", - }, - }, - keys = { - -- fabric-ai.nvim doesn't have default keymappings - { "fa", ":'<,'>Fabric", mode = "v", desc = "Fabric AI" }, - { "fa", ":Fabric", mode = "n", desc = "Fabric AI" }, - { "fu", ":Fabric url", mode = "n", desc = "Fabric URL" }, - }, - }, -} diff --git a/config/nvim-old/lua/plugins/ft.lua b/config/nvim-old/lua/plugins/ft.lua deleted file mode 100644 index 52b7e16..0000000 --- a/config/nvim-old/lua/plugins/ft.lua +++ /dev/null @@ -1,283 +0,0 @@ -return { - { - "mfussenegger/nvim-ansible", - lazy = true, - keys = function() - vim.keymap.set('v', 'te', function() require('ansible').run() end, { buffer = true, silent = true }) - vim.keymap.set('n', 'te', ":w :lua require('ansible').run()", { buffer = true, silent = true }) - end, - }, - { - "hat0uma/csvview.nvim", - opts = { - parser = { comments = { "#", "//" } }, - keymaps = { - textobject_field_inner = { "if", mode = { "o", "x" } }, - textobject_field_outer = { "af", mode = { "o", "x" } }, - jump_next_field_end = { "", mode = { "n", "v" } }, - jump_prev_field_end = { "", mode = { "n", "v" } }, - jump_next_row = { "", mode = { "n", "v" } }, - jump_prev_row = { "", mode = { "n", "v" } }, - }, - }, - cmd = { "CsvViewEnable", "CsvViewDisable", "CsvViewToggle" }, - }, - { - "obsidian-nvim/obsidian.nvim", - lazy = false, - ft = "markdown", - keys = { - { "kx", "Obsidian extract_note", desc = "Extract Note", mode = "v" }, - - { "knn", "Obsidian new", desc = "New Obsidian note", mode = "n" }, - { "knt", "Obsidian new_from_template", desc = "New from template", mode = "n" }, - - { "ksq", "Obsidian quick_switch", desc = "Quick Switch", mode = "n" }, - { "kss", "Obsidian search", desc = "Search Obsidian notes", mode = "n" }, - - { "kdt", "Obsidian today", desc = "Daily Today", mode = "n" }, - { "kdy", "Obsidian yesterday", desc = "Daily Yesterday", mode = "n" }, - { "kdw", "Obsidian tomorrow", desc = "Daily Tomorrow", mode = "n" }, - { "kdd", "Obsidian dailies", desc = "Dailies", mode = "n" }, - { "kw", "Obsidian workspace", desc = "Change Workspace", mode = "n" }, - - }, - config = function() - require("obsidian").setup({ - legacy_commands = false, - picker = { - name = "snacks.pick", - }, - ui = { - enable = true, - }, - workspaces = { - { - name = "NCA notes", - path = vim.fn.expand "~" .. "/Documents/nca-notes/", - }, - }, - notes_subdir = "Inbox", - daily_notes = { - folder = "Dailies", - date_format = "%Y-%m-%d-%a", - alias_fomat = "%B %-d, %Y", - default_tags = { "daily-notes" }, - }, - new_notes_location = "notes_subdir", - templates = { - subdir = "Templates", - date_format = "%Y-%m-%d-%a", - time_format = "%H:%M", - tags = "", - }, - completion = { - nvim_cmp = false, - blink = true, - min_chars = 2, - }, - link = { - style = "wiki", - }, - note_id_func = function(title) - local suffix = "" - if title ~= nil then - suffix = title:gsub(" ", "-"):gsub("[^A-Za-z0-9-]", ""):lower() - else - for _ = 1, 4 do - suffix = suffix .. string.char(math.random(65, 90)) - suffix = tostring(os.time()) .. "-" .. suffix - end - end - return suffix - end, - - callbacks = { - enter_note = function(note) - vim.keymap.set('n', 'k.', 'Obsidian toggle_checkbox', { desc = 'toggle checkbox', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'kp', 'Obsidian paste_img', { desc = 'paste img', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'kt', 'Obsidian tags', { desc = 'tags', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'k`', 'Obsidian backlinks', { desc = 'backlinks', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'kx', 'Obsidian follow_link', { desc = 'follow link', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'ksl', 'Obsidian links', { desc = 'links', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'kr', 'Obsidian rename', { desc = 'rename', buffer = note.bufnr, silent = true }) - vim.keymap.set('n', 'ksc', 'Obsidian toc', { desc = 'toc', buffer = note.bufnr, silent = true }) - vim.keymap.set('v', 'kx', 'Obsidian link', { desc = 'links', buffer = note.bufnr, silent = true }) - vim.keymap.set('v', 'kl', 'Obsidian link_new', { desc = 'links', buffer = note.bufnr, silent = true }) - end, - }, - }) - end, - }, - { - "salkin-mada/openscad.nvim", - lazy = true, - config = function() - vim.g.openscad_load_snippets = true - require("openscad").setup({}) - end, - dependencies = { "L3MON4D3/LuaSnip", "junegunn/fzf.vim" }, - }, - { - -- 'nvim-orgmode/orgmode', - 'SjB/orgmode', - branch = 'sjb-wip', - event = 'VeryLazy', - ft = { 'org' }, - config = function() - -- Setup orgmode - local org = require('orgmode') - -- org.setup_ts_grammar() - org.setup({ - ui = { - input = { - use_vim_ui = true - } - }, - org_agenda_files = {'~/Documents/notes/*project*org', '~/Documents/notes/Inbox*org', '~/Documents/journals/*.org'}, - org_default_notes_file = "~/Documents/notes/Inbox.org", - org_todo_keywords = { 'TODO(t)', 'NEXT(n)', '|', 'DONE(d)', 'DELEGATED(a)' }, - mappings = { - capture = { - org_capture_refile = 'R', - } - }, - hyperlinks = { - sources = { - -- require("denote.extensions.orgmode"):new({ - -- files = _G.denote.config.directory, - -- }), - }, - }, - org_capture_templates = { - t = { - description = "Todo item", - template = "* TODO %?\n SCHEDULED: %t\n DEADLINE: %T\n", -- Template content - headline = "Tasks", - }, - j = { - description = "Journal entry", - target = "~/Documents/notes/journals/%<%Y-%m-%d>.org", - template = "* %<%Y-%m-%d %H:%M> %?\n", - }, - }, - - }) - end, - }, - { - "akinsho/org-bullets.nvim", - config = function() - require("org-bullets").setup { - concealcursor = false, -- If false then when the cursor is on a line underlying characters are visible - symbols = { - -- list symbol - list = "•", - -- headlines can be a list - headlines = { "◉", "○", "✸", "✿" }, - -- or a function that receives the defaults and returns a list - headlines = function(default_list) - table.insert(default_list, "♥") - return default_list - end, - -- or false to disable the symbol. Works for all symbols - headlines = false, - -- or a table of tables that provide a name - -- and (optional) highlight group for each headline level - headlines = { - { "◉", "MyBulletL1" }, - { "○", "MyBulletL2" }, - { "✸", "MyBulletL3" }, - { "✿", "MyBulletL4" }, - }, - checkboxes = { - half = { "", "@org.checkbox.halfchecked" }, - done = { "✓", "@org.keyword.done" }, - todo = { "˟", "@org.keyword.todo" }, - }, - } - } - end - }, - { - "chipsenkbeil/org-roam.nvim", - lazy = true, - ft = { 'org' }, - opts = { - bindings = { - prefix = "oO", - }, - directory = "~/Documents/notes", - extensions = { - dailies = { - directory = "journals" - }, - }, - }, - }, - { - "iamcco/markdown-preview.nvim", - cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" }, - ft = { "markdown" }, - init = function() - vim.g.mkdp_filetypes = { "markdown" } - end, - keys = function() - vim.keymap.set("n", "xmp", "MarkdownPreview", { desc ="Markdown Preview" }) - vim.keymap.set("n", "xms", "MarkdownPreviewStop", { desc ="Markdown Preview Stop" }) - end, - build = function() vim.fn["mkdp#util#install"]() end, - --build = "cd app && npm install", - }, - { - "lervag/vimtex", - ft = "tex", -- Load only for .tex files - config = function() - vim.g.tex_flavor = "latex" - vim.g.vimtex_view_method = "zathura" -- Change to your preferred PDF viewer - vim.g.vimtex_quickfix_mode = 0 -- Disable quickfix window - -- vim.opt.conceallevel = 2 -- Enable concealment for nicer inline math display - vim.g.tex_conceal = "abdmg" -- Conceal accents, bold, delimiters, math, Greek - end, - }, - { - 'MeanderingProgrammer/render-markdown.nvim', - after = { 'nvim-treesitter' }, - requires = { 'nvim-tree/nvim-web-devicons', opt = true }, - ft = { 'markdown', 'codecompanion', 'copilot-chat' }, - config = function() - require('render-markdown').setup({ - completions = { lsp = { enabled = true } }, - -- render_modes = { 'n', 'v' }, - render_modes = true, - enabled = true, - anti_conceal = { - enabled = false, - }, - quote = { repeat_linebreak = true }, - checkbox = { - -- unchecked = { icon = '✘ ' }, - checked = { icon = '✔ ', scope_highlight = '@markup.strikethrough' }, - custom = { - todo = { raw = '[-]', rendered = '󰥔 ', highlight = 'RenderMarkdownTodo', scope_highlight = nil }, - important = { raw = '[~]', rendered = '󰓎 ', highlight = 'DiagnosticWarn', }, - }, - }, - latex = { - enabled = false, - converter = "latex2text", - }, - win_options = { - conceallevel = { - default = 0, - rendered = 2, -- Conceal level 2: hide LaTeX code fully - }, - concealcursor = { - default = "", - rendered = "n", -- Conceal only in normal mode - }, - } - }) - end, - }, -} diff --git a/config/nvim-old/lua/plugins/ide.lua b/config/nvim-old/lua/plugins/ide.lua deleted file mode 100644 index a813e85..0000000 --- a/config/nvim-old/lua/plugins/ide.lua +++ /dev/null @@ -1,1329 +0,0 @@ -return { - { - "folke/snacks.nvim", - priority = 1000, - lazy = false, - ---@type snacks.Config - opts = { - animate = { - enabled = false, - duration = { step = 1, total = 1 }, - easing = "linear", - }, - bigfile = { enabled = true }, - dashboard = { enabled = false }, - explorer = { enabled = false }, - image = { - enabled = true, - inline = false, - scale = 3, -- nil | 1 (default) | 2 | 3 | ... - doc = { - inline = true, - enabled = true, - max_width = nil, - max_height = nil, - conceal = true, - }, - math = { - enabled = true, - } - }, - terminal = { - bo = { - filetype = "snacks_terminal", - }, - win = { style = "terminal" }, - wo = {}, - keys = { - q = "hide", - gf = function(self) - local f = vim.fn.findfile(vim.fn.expand(""), "**") - if f == "" then - Snacks.notify.warn("No file under cursor") - else - self:hide() - vim.schedule(function() - vim.cmd("e " .. f) - end) - end - end, - term_normal = { - "", - function(self) - self.esc_timer = self.esc_timer or (vim.uv or vim.loop).new_timer() - if self.esc_timer:is_active() then - self.esc_timer:stop() - vim.cmd("stopinsert") - else - self.esc_timer:start(250, 0, function() end) - return "" - end - end, - mode = "t", - expr = true, - desc = "Double escape to normal mode", - }, - }, - }, - indent = { enabled = false }, - notifier = { - enabled = true, - timeout = 1000, - }, - picker = { - enabled = true, - layout = { preset = "ivy", layout = { position = "bottom" } }, - frecency = true, - history_bonus = true, - projects = { - dev = { "~/Projects", }, - }, - win = { - input = { - keys = { - [''] = { 'layout_right', mode = { 'i', 'n' } }, - }, - }, - }, - sources = { - files = { - -- add a custom action - actions = { - create_if_missing = function(picker, item) - -- When typing in the input, item may be nil. - -- We'll use the input text as the intended file path. - local input = picker.input and picker.input:get() or "" - if input == "" then return end - - -- Make it relative to picker cwd if it’s not absolute - local cwd = picker.opts.cwd or vim.loop.cwd() - local path = input - if not path:match("^/") and not path:match("^%a:[/\\]") then - path = cwd .. "/" .. path - end - - -- Normalize path (optional) - path = vim.fn.fnamemodify(path, ":p") - - -- If file exists, just open it - if vim.loop.fs_stat(path) then - picker:close() - vim.cmd.edit(path) - return - end - - -- Ensure parent dirs exist (optional but nice) - vim.fn.mkdir(vim.fn.fnamemodify(path, ":h"), "p") - - -- Open a new buffer at that path (creates buffer even if file missing) - picker:close() - vim.cmd.edit(path) - -- At this point buffer is new + unnamed-on-disk until you :w - end, - }, - - -- bind the action to a key in the picker UI - win = { - input = { - keys = { - [""] = { "create_if_missing", mode = { "i", "n" }, desc = "Create file from input" }, - }, - }, - list = { - keys = { - [""] = { "create_if_missing", mode = { "n" }, desc = "Create file from input" }, - }, - }, - }, - }, - }, - }, - scope = { enabled = false }, - scratch = { - ft = "markdown", - }, - statuscolumn = { enabled = true }, - styles = { - notification = { - -- wo = { wrap = true } -- Wrap notifications - } - } - }, - keys = { - -- Org Search - { "o/", function() Snacks.picker.grep({dirs = { os.getenv("HOME") .. "/Documents/notes" }}) end, desc = "Search Org Files" }, - -- { "o/", function() Snacks.picker.files({ cwd = os.getenv("HOME") .. "/Documents/notes" }) end, desc = "Find Document" }, - -- Top Pickers & Explorer - { "", function() Snacks.picker.smart() end, desc = "Smart Find Files" }, - { "j", function() Snacks.picker.files({args = { "--no-require-git" }}) end, desc = "Find Files" }, - { ",", function() Snacks.picker.buffers() end, desc = "Buffers" }, - { "/", function() Snacks.picker.grep() end, desc = "Grep" }, - { ":", function() Snacks.picker.command_history() end, desc = "Command History" }, - { "n", function() Snacks.picker.notifications() end, desc = "Notification History" }, - { "i", function() Snacks.picker.lsp_symbols() end, desc = "Symbols" }, - { "I", function() Snacks.picker.lsp_workspace_symbols() end, desc = "LSP Workspace Symbols" }, - -- { "e", function() Snacks.explorer() end, desc = "File Explorer" }, - -- find - { "fb", function() Snacks.picker.buffers() end, desc = "Buffers" }, - { "fc", function() Snacks.picker.files({ cwd = vim.fn.stdpath("config") }) end, desc = "Find Config File" }, - { "ff", function() Snacks.picker.files() end, desc = "Find Files" }, - { "fg", function() Snacks.picker.git_files() end, desc = "Find Git Files" }, - { "fp", function() Snacks.picker.projects() end, desc = "Projects" }, - { "fr", function() Snacks.picker.recent() end, desc = "Recent" }, - -- git - { "gb", function() Snacks.picker.git_branches() end, desc = "Git Branches" }, - { "gl", function() Snacks.picker.git_log() end, desc = "Git Log" }, - { "gL", function() Snacks.picker.git_log_line() end, desc = "Git Log Line" }, - { "gs", function() Snacks.picker.git_status() end, desc = "Git Status" }, - { "gS", function() Snacks.picker.git_stash() end, desc = "Git Stash" }, - { "gd", function() Snacks.picker.git_diff() end, desc = "Git Diff (Hunks)" }, - { "gf", function() Snacks.picker.git_log_file() end, desc = "Git Log File" }, - -- Grep - { "sb", function() Snacks.picker.lines() end, desc = "Buffer Lines" }, - { "sB", function() Snacks.picker.grep_buffers() end, desc = "Grep Open Buffers" }, - { "sg", function() Snacks.picker.grep() end, desc = "Grep" }, - { "sw", function() Snacks.picker.grep_word() end, desc = "Visual selection or word", mode = { "n", "x" } }, - -- search - { 's"', function() Snacks.picker.registers() end, desc = "Registers" }, - { 's/', function() Snacks.picker.search_history() end, desc = "Search History" }, - { "sa", function() Snacks.picker.autocmds() end, desc = "Autocmds" }, - { "sb", function() Snacks.picker.lines() end, desc = "Buffer Lines" }, - { "sc", function() Snacks.picker.command_history() end, desc = "Command History" }, - { "sC", function() Snacks.picker.commands() end, desc = "Commands" }, - { "sd", function() Snacks.picker.diagnostics() end, desc = "Diagnostics" }, - { "sD", function() Snacks.picker.diagnostics_buffer() end, desc = "Buffer Diagnostics" }, - { "sh", function() Snacks.picker.help() end, desc = "Help Pages" }, - { "sH", function() Snacks.picker.highlights() end, desc = "Highlights" }, - { "si", function() Snacks.picker.icons() end, desc = "Icons" }, - { "sj", function() Snacks.picker.jumps() end, desc = "Jumps" }, - { "sk", function() Snacks.picker.keymaps() end, desc = "Keymaps" }, - { "sl", function() Snacks.picker.loclist() end, desc = "Location List" }, - { "sm", function() Snacks.picker.marks() end, desc = "Marks" }, - { "sM", function() Snacks.picker.man() end, desc = "Man Pages" }, - { "sp", function() Snacks.picker.lazy() end, desc = "Search for Plugin Spec" }, - { "sq", function() Snacks.picker.qflist() end, desc = "Quickfix List" }, - { "sR", function() Snacks.picker.resume() end, desc = "Resume" }, - { "su", function() Snacks.picker.undo() end, desc = "Undo History" }, - { "sz", function() Snacks.picker.zoxide() end, desc = "Zoxide" }, - { "uC", function() Snacks.picker.colorschemes() end, desc = "Colorschemes" }, - -- LSP - { "gd", function() Snacks.picker.lsp_definitions() end, desc = "Goto Definition" }, - { "gD", function() Snacks.picker.lsp_declarations() end, desc = "Goto Declaration" }, - { "grr", function() Snacks.picker.lsp_references() end, nowait = true, desc = "References" }, - { "gri", function() Snacks.picker.lsp_implementations() end, desc = "Goto Implementation" }, - { "gy", function() Snacks.picker.lsp_type_definitions() end, desc = "Goto T[y]pe Definition" }, - { "ss", function() Snacks.picker.lsp_symbols() end, desc = "LSP Symbols" }, - { "sS", function() Snacks.picker.lsp_workspace_symbols() end, desc = "LSP Workspace Symbols" }, - -- Other - { "Z", function() Snacks.zen() end, desc = "Toggle Zen Mode" }, - { "z", function() Snacks.zen.zoom() end, desc = "Toggle Zoom" }, - { ".", function() Snacks.scratch() end, desc = "Toggle Scratch Buffer" }, - { "S", function() Snacks.scratch.select() end, desc = "Select Scratch Buffer" }, - -- { "n", function() Snacks.notifier.show_history() end, desc = "Notification History" }, - { "bd", function() Snacks.bufdelete() end, desc = "Delete Buffer" }, - { "bR", function() Snacks.rename.rename_file() end, desc = "Rename File" }, - { "gB", function() Snacks.gitbrowse() end, desc = "Git Browse", mode = { "n", "v" } }, - { "gg", function() Snacks.lazygit() end, desc = "Lazygit" }, - { "un", function() Snacks.notifier.hide() end, desc = "Dismiss All Notifications" }, - { "", function() Snacks.terminal.toggle() end, desc = "Toggle Terminal", mode = { "n", "t" } }, - -- { "", "", desc = "Exit Terminal Mode", mode = { "t" } }, - { "]]", function() Snacks.words.jump(vim.v.count1) end, desc = "Next Reference", mode = { "n", "t" } }, - { "[[", function() Snacks.words.jump(-vim.v.count1) end, desc = "Prev Reference", mode = { "n", "t" } }, - { - "xN", - desc = "Neovim News", - function() - Snacks.win({ - file = vim.api.nvim_get_runtime_file("doc/news.txt", false)[1], - width = 0.6, - height = 0.6, - wo = { - spell = false, - wrap = false, - signcolumn = "yes", - statuscolumn = " ", - conceallevel = 3, - }, - }) - end, - } - }, - init = function() - vim.api.nvim_create_autocmd("User", { - pattern = "VeryLazy", - callback = function() - -- Setup some globals for debugging (lazy-loaded) - _G.dd = function(...) - Snacks.debug.inspect(...) - end - _G.bt = function() - Snacks.debug.backtrace() - end - vim.print = _G.dd -- Override print to use snacks for `:=` command - - -- Create some toggle mappings - Snacks.toggle.option("spell", { name = "Spelling" }):map("us") - Snacks.toggle.option("wrap", { name = "Wrap" }):map("uw") - Snacks.toggle.option("relativenumber", { name = "Relative Number" }):map("uL") - Snacks.toggle.diagnostics():map("ud") - Snacks.toggle.line_number():map("ul") - Snacks.toggle.option("conceallevel", { off = 0, on = vim.o.conceallevel > 0 and vim.o.conceallevel or 2 }):map("uc") - Snacks.toggle.treesitter():map("uT") - Snacks.toggle.option("background", { off = "light", on = "dark", name = "Dark Background" }):map("ub") - Snacks.toggle.inlay_hints():map("uh") - Snacks.toggle.indent():map("ug") - Snacks.toggle.dim():map("uD") - end, - }) - end, - }, - { - "folke/todo-comments.nvim", - lazy = true, - keys = { - { "st", function() Snacks.picker.todo_comments() end, desc = "Todo" }, - { "sT", function() Snacks.picker.todo_comments({ keywords = { "TODO", "FIX", "FIXME", "NOTE" } }) end, desc = "Todo/Fix/Fixme/Note" }, - }, - opts = {}, - }, - { - 'L3MON4D3/LuaSnip', - dependencies = { - 'rafamadriz/friendly-snippets', - }, - version = "v2.*", - build = "make install_jsregexp", - config = function() - require('luasnip.loaders.from_vscode').lazy_load() - require('luasnip.loaders.from_vscode').lazy_load({ paths = "./json_snippets" }) - local luasnip = require("luasnip") - luasnip.add_snippets("zig", require("snippets.zig")) - end, - }, - { - 'saghen/blink.cmp', - lazy = false, -- lazy loading handled internally - -- optional: provides snippets for the snippet source - dependencies = { - 'L3MON4D3/LuaSnip', - 'moyiz/blink-emoji.nvim', - 'MeanderingProgrammer/render-markdown.nvim', - 'fang2hou/blink-copilot', - --'giuxtaposition/blink-cmp-copilot', - }, - version = '1.*', - config = function() - -- NOTE: Specify the trigger character(s) used for luasnip - -- local trigger_text = ";" - require('blink.cmp').setup({ - enabled = function() - local filetype = vim.bo[0].filetype - if filetype == "TelescopePrompt" or filetype == "minifiles" or filetype == "snacks_picker_input" then - return false - end - return true - end, - snippets = { preset = 'luasnip' }, - completion = { - -- keyword = { - -- -- 'prefix' will fuzzy match on the text before the cursor - -- -- 'full' will fuzzy match on the text before *and* after the cursor - -- -- example: 'foo_|_bar' will match 'foo_' for 'prefix' and 'foo__bar' for 'full' - -- range = "full", - -- }, - menu = { - draw = { - treesitter = { 'lsp' } - } - -- border = "single", - }, - list = { - selection = { - preselect = false, - auto_insert = false, - } - }, - documentation = { - auto_show = true, - auto_show_delay_ms = 500, - -- window = { - -- border = "single", - -- }, - }, - ghost_text = { enabled = false }, - }, - cmdline = { - enabled = true, - }, - signature = { enabled = true }, - sources = { - per_filetype = { - org = {'orgmode'} - }, - default = { 'orgmode', 'lsp', 'copilot', 'snippets', 'path', 'omni', 'buffer', 'codecompanion', 'markdown' }, - providers = { - codecompanion = { - name = "CodeCompanion" , - module = "codecompanion.providers.completion.blink", - enabled = true, - }, - orgmode = { - name = 'Orgmode', - module = 'orgmode.org.autocompletion.blink', - fallbacks = { 'buffer' }, - }, - copilot = { - name = 'copilot', - module = 'blink-copilot', - score_offset = 100, - async = true, - }, - markdown = { - name = 'RenderMarkdown', - module = 'render-markdown.integ.blink', - score_offset = 80, - }, - lsp = { - name = 'lsp', -- IMPORTANT: use the same name as you would for nvim-cmp - enabled = true, - module = 'blink.cmp.sources.lsp', - -- fallbacks = { 'snippets', 'buffer', 'path' }, - score_offset = 100, - }, - path = { - name = 'path', -- IMPORTANT: use the same name as you would for nvim-cmp - module = 'blink.cmp.sources.path', - score_offset = 50, - fallbacks = { 'snippets', 'buffer' }, - opts = { - trailing_slash = false, - label_trailing_slash = true, - get_cwd = function(context) - return vim.fn.expand(("#%d:p:h"):format(context.bufnr)) - end, - show_hidden_files_by_default = true, - }, - }, - buffer = { - name = "Buffer", - enabled = true, - max_items = 3, - module = "blink.cmp.sources.buffer", - min_keyword_length = 4, - score_offset = 15, -- the higher the number, the higher the priority - }, - snippets = { - name = "snippets", - enabled = true, - max_items = 15, - min_keyword_length = 2, - module = "blink.cmp.sources.snippets", - score_offset = 90, -- the higher the number, the higher the priority - }, - emoji = { - module = "blink-emoji", - name = "Emoji", - score_offset = 0, -- the higher the number, the higher the priority - opts = { insert = true }, -- Insert emoji (default) or complete its name - }, - }, - }, - appearance = { - -- Blink does not expose its default kind icons so you must copy them all (or set your custom ones) and add Copilot - kind_icons = { - Copilot = "", - Text = '󰉿', - Method = '󰊕', - Function = '󰊕', - Constructor = '󰒓', - - Field = '󰜢', - Variable = '󰆦', - Property = '󰖷', - - Class = '󱡠', - Interface = '󱡠', - Struct = '󱡠', - Module = '󰅩', - - Unit = '󰪚', - Value = '󰦨', - Enum = '󰦨', - EnumMember = '󰦨', - - Keyword = '󰻾', - Constant = '󰏿', - - Snippet = '󱄽', - Color = '󰏘', - File = '󰈔', - Reference = '󰬲', - Folder = '󰉋', - Event = '󱐋', - Operator = '󰪚', - TypeParameter = '󰬛', - }, - }, - }) - end - }, - { - 'stevearc/conform.nvim', - event = { 'BufWritePre' }, - cmd = { 'ConformInfo' }, - keys = { - { - 'bf', - function() - require('conform').format { async = true, lsp_format = 'fallback' } - end, - mode = { 'n', 'v' }, - desc = 'Format buffer', - }, - }, - opts = { - notify_on_error = false, - formatters = { - shfmt = { - prepend_args = { "-i", "2", "-ci" }, - }, - dprint = { - condition = function(ctx) - return vim.fs.find({ "dprint.json" }, { path = ctx.filename, upward = true })[1] - end, - }, - }, - formatters_by_ft = { - c = { "clang_format" }, - cpp = { "clang_format" }, - lua = { 'stylua' }, - go = { "goimports", "gofmt" }, - rust = { "dprint", "rustfmt", lsp_format = "fallback" }, - python = { "isort", "black", stop_after_first = true }, - javascript = { "dprint", "prettier", stop_after_first = true }, - markdown = { "dprint", "prettier", stop_after_first = true }, - javascriptreact = { "dprint", "prettier", stop_after_first = true }, - typescript = { "dprint", "prettier", stop_after_first = true }, - typescriptreact = { "dprint", "prettier", stop_after_first = true }, - svelte = { "dprint", "prettier", stop_after_first = true }, - html = { "dprint", "prettier", stop_after_first = true }, - }, - }, - }, - { - 'lewis6991/gitsigns.nvim', - event = "VimEnter", - keys = { - { 'uG', "Gitsigns toggle_signs", mode = { 'n' }, desc = 'Gitsigns toggle', }, - }, - opts = { - auto_attach = true, - signs_staged_enable = true, - signcolumn = true, - current_line_blame_opts = { - delay = 50 - }, - on_attach = function(bufnr) - local gitsigns = require('gitsigns') - - local function map(mode, l, r, opts) - opts = opts or {} - opts.buffer = bufnr - vim.keymap.set(mode, l, r, opts) - end - - -- Actions - -- visual mode - map('v', 'vs', function() - gitsigns.stage_hunk { vim.fn.line '.', vim.fn.line 'v' } - end, { desc = 'stage git hunk' }) - - map('v', 'vr', function() - gitsigns.reset_hunk { vim.fn.line '.', vim.fn.line 'v' } - end, { desc = 'reset git hunk' }) - - -- normal mode - - map('n', '[v', function() gitsigns.nav_hunk 'prev' end, { desc = 'git previous hunk' }) - map('n', ']v', function() gitsigns.nav_hunk 'next' end, { desc = 'git next hunk' }) - map('n', 'vs', gitsigns.stage_hunk, { desc = 'git stage hunk' }) - map('n', 'vr', gitsigns.reset_hunk, { desc = 'git reset hunk' }) - map('n', 'vS', gitsigns.stage_buffer, { desc = 'git stage buffer' }) - map('n', 'vu', gitsigns.undo_stage_hunk, { desc = 'git undo stage hunk' }) - map('n', 'vR', gitsigns.reset_buffer, { desc = 'git reset buffer' }) - map('n', 'vP', gitsigns.preview_hunk, { desc = 'git preview hunk' }) - map('n', 'vb', gitsigns.blame_line, { desc = 'git blame line' }) - map('n', 'vP', gitsigns.diffthis, { desc = 'git diff against index' }) - map('n', 'vD', function() - gitsigns.diffthis '@' - end, { desc = 'git [D]iff against last commit' }) - -- Toggles - map('n', 'uvb', gitsigns.toggle_current_line_blame, { desc = '[T]oggle git show [b]lame line' }) - map('n', 'uvd', gitsigns.toggle_deleted, { desc = '[T]oggle git show [D]eleted' }) - end, - } - }, - { - "dlyongemallo/diffview.nvim", - --"sindrets/diffview.nvim", - }, - { - "NicolasGB/jj.nvim", - version = "*", -- Use latest stable release - -- Or from the main branch (uncomment the branch line and comment the version line) - -- branch = "main", - keys = function() - local cmd = require("jj.cmd") - local annotate = require("jj.annotate") - - vim.keymap.set("n", "va", annotate.file, { desc = "JJ annotate file" }) - vim.keymap.set("n", "vA", annotate.line, { desc = "JJ annotate line" }) - vim.keymap.set("n", "vbc", cmd.bookmark_create, { desc = "JJ bookmark create" }) - vim.keymap.set("n", "vbd", cmd.bookmark_delete, { desc = "JJ bookmark delete" }) - vim.keymap.set("n", "vbm", cmd.bookmark_move, { desc = "JJ bookmark move" }) - vim.keymap.set("n", "vd", cmd.describe, { desc = "JJ describe" }) - vim.keymap.set("n", "vl", cmd.log, { desc = "JJ log" }) - vim.keymap.set("n", "ve", cmd.edit, { desc = "JJ edit" }) - vim.keymap.set("n", "vn", cmd.new, { desc = "JJ new" }) - vim.keymap.set("n", "vs", cmd.status, { desc = "JJ status" }) - vim.keymap.set("n", "vS", cmd.squash, { desc = "JJ squash" }) - vim.keymap.set("n", "vju", cmd.undo, { desc = "JJ undo" }) - vim.keymap.set("n", "vjr", cmd.redo, { desc = "JJ redo" }) - vim.keymap.set("n", "vr", cmd.rebase, { desc = "JJ rebase" }) - vim.keymap.set("n", "vf", cmd.fetch, { desc = "JJ fetch" }) - vim.keymap.set("n", "vx", cmd.abandon, { desc = "JJ abandon" }) - vim.keymap.set("n", "vp", cmd.push, { desc = "JJ push" }) - vim.keymap.set("n", "vpr", cmd.open_pr, { desc = "JJ open PR from bookmark in current revision or parent" }) - vim.keymap.set("n", "vpl", function() - cmd.open_pr { list_bookmarks = true } - end, { desc = "JJ open PR listing available bookmarks" }) - - - -- Diff commands - local diff = require("jj.diff") - vim.keymap.set("n", "vjd", function() diff.open_vdiff() end, { desc = "JJ diff current buffer" }) - vim.keymap.set("n", "vjD", function() diff.open_hsplit() end, { desc = "JJ hdiff current buffer" }) - - -- Pickers - local picker = require("jj.picker") - vim.keymap.set("n", "vjs", function() picker.status() end, { desc = "JJ Picker status" }) - vim.keymap.set("n", "vjh", function() picker.file_history() end, { desc = "JJ Picker history" }) - - -- Some functions like `log` can take parameters - vim.keymap.set("n", "vL", function() - cmd.log { - revisions = "all()", -- equivalent to jj log -r :: - } - end, { desc = "JJ log all" }) - - - -- This is an alias i use for moving bookmarks its so good - vim.keymap.set("n", "vt", function() - cmd.j "tug" - cmd.log {} - end, { desc = "JJ tug" }) - - end, - config = function() - require("jj").setup({ - diff = { - backend = "native", - }, - cmd = { - describe = { - editor = { - type = "buffer", - } - } - }, - describe = { - editor = { - type = "buffer", - } - } - }) - end, - }, - { - "julienvincent/hunk.nvim", - cmd = { "DiffEditor" }, - config = function() - require("hunk").setup() - end, - }, - { - -- "PrayagS/jj-diffconflicts", - -- branch = 'fix-for-jj-v0_37_0', - "rafikdraoui/jj-diffconflicts" - }, - { - 'Glhou/jjsigns.nvim', - branch = 'fix/skip-extra-lines', - config = function() - require('jjsigns').setup({ - enabled = true, - attach = { - auto = false, - } - }) - end, - }, - { 'williamboman/mason.nvim', lazy = true, opts = {} }, - { 'williamboman/mason-lspconfig.nvim', lazy = true }, - { 'WhoIsSethDaniel/mason-tool-installer.nvim', lazy = true }, - { - 'neovim/nvim-lspconfig', - lazy = false, - dependencies = { - { 'SmiteshP/nvim-navic', lazy = true }, - }, - keys = function() - vim.keymap.set("i", "", function() - if not vim.lsp.inline_completion.get() then - return "" - end - end, { expr = true, desc = "Accept the current inline completion" }) - end, - config = function() - - vim.api.nvim_create_autocmd('LspAttach', { - group = vim.api.nvim_create_augroup('kickstart-lsp-attach', { clear = true }), - callback = function(event) - local function client_supports_method(client, method, bufnr) - return client:supports_method(method, bufnr) - end - - local client = vim.lsp.get_client_by_id(event.data.client_id) - if client and client:supports_method(vim.lsp.protocol.Methods.textDocument_completion, event.buf) then - vim.lsp.completion.enable(true, client.id, event.buf, { autotrigger = true }) - end - end, - }) - - -- Diagnostic Config - -- See :help vim.diagnostic.Opts - vim.diagnostic.config({ - severity_sort = true, - float = { border = 'rounded', source = 'if_many' }, - underline = { severity = vim.diagnostic.severity.ERROR }, - signs = vim.g.have_nerd_font and { - text = { - [vim.diagnostic.severity.ERROR] = '󰅚 ', - [vim.diagnostic.severity.WARN] = '󰀪 ', - [vim.diagnostic.severity.INFO] = '󰋽 ', - [vim.diagnostic.severity.HINT] = '󰌶 ', - }, - } or {}, - virtual_text = { - source = 'if_many', - spacing = 2, - format = function(diagnostic) - local diagnostic_message = { - [vim.diagnostic.severity.ERROR] = diagnostic.message, - [vim.diagnostic.severity.WARN] = diagnostic.message, - [vim.diagnostic.severity.INFO] = diagnostic.message, - [vim.diagnostic.severity.HINT] = diagnostic.message, - } - return diagnostic_message[diagnostic.severity] - end, - }, - }) - - - local servers = { - lua_ls = { - settings = { - Lua = { - runtime = { - version = 'LuaJIT', - }, - workspace = { - library = vim.api.nvim_get_runtime_file("", true), - checkThirdParty = false, - }, - completion = { - callSnippet = "Replace", - }, - diagnostics = { - disable = { 'missing-fields' }, - globals = { 'vim', 'require' }, - }, - - }, - } - }, - gopls = { - settings = { - gopls = { - experimentalPostfixCompletions = true, - analyses = { - unusedparams = true, - shadow = true, - }, - staticcheck = true, - hints = { - enabled = true, - rangeVariableTypes = true, - prameterNames = true, - functionTypeParameters = true, - constantValues = true, - compositeLiteralTypes = true, - compositeLiteralFields = true, - assignVariableTypes = true, - }, - }, - }, - }, - harper_ls = { - settings = { - ["harper-ls"] = { - linters = { - SentenceCapitalization = true, - SpellCheck = true - }, - dialect = "Canadian" - } - } - }, - -- csharp_ls = {}, - zls = {}, - clangd = { - settings = { - ["clang"] = { - cmd = { "clangd", "--background-index", "--compile-commands-dir=" .. vim.loop.cwd() .. "/build" }, - } - } - }, - rust_analyzer= { - settings = { - ['rust-analyzer'] = { - cargo = { - allFeatures = true, - }, - checkOnSave = true, - check = { - command = "clippy", - }, - procMacro = { - enable = true, - }, - lens = { - debug = { enable = true }, - enable = true, - implementations = { enable = true }, - references = { - adt = { enable = true }, - enumVariant = { enable = true }, - method = { enable = true }, - trait = { enable = true }, - }, - run = { enable = true }, - updateTest = { enable = true }, - }, - }, - } - }, - ts_ls= {}, - html= {}, - eslint= {}, - jsonls= {}, - jdtls= {}, - copilot = { - -- settings = { - -- ['copilot'] = { - -- cmd = { "copilot-language-server", "--stdio" }, - -- init_options = { - -- name = "Neovim", - -- version = tostring(vim.version()), - -- }, - -- editorPluginInfo = { - -- name = "Neovim", - -- version = tostring(vim.version()), - -- }, - -- }, - -- }, - }, - } - - local ensure_installed = vim.tbl_keys(servers or {}) - require('mason-tool-installer').setup ({ ensure_installed = ensure_installed }) - - local capabilities = vim.lsp.protocol.make_client_capabilities() - capabilities = vim.tbl_deep_extend('force', capabilities, require('blink.cmp').get_lsp_capabilities({}, false)) - capabilities = vim.tbl_deep_extend('force', capabilities, { - general = { - -- dynamicRegistration = false, - positionEncodings = { "utf-16" }, - }, - textDocument = { - foldingRange = { - dynamicRegistration = false, - lineFoldingOnly = true - } - } - }) - - for server, cfg in pairs(servers) do - cfg.capabilities = vim.tbl_deep_extend('force', {}, capabilities, cfg.capabilities or {}) - vim.lsp.config(server, cfg) - vim.lsp.enable(server) - end - vim.lsp.inline_completion.enable(); - -- vim.lsp.enable("rust-analyzer", false) - - - end - }, - { - "rcarriga/nvim-dap-ui", - dependencies = { - "mfussenegger/nvim-dap", - "nvim-neotest/nvim-nio" - }, - config = function() - local dapui = require("dapui") - local dap = require("dap") - dapui.setup() - vim.fn.sign_define("DapBreakpoint", { text = "🐞" }) - - dap.listeners.before.attach.dapui_config = function() - dapui.open() - end - dap.listeners.before.launch.dapui_config = function() - dapui.open() - end - dap.listeners.before.event_terminated.dapui_config = function() - dapui.close() - end - dap.listeners.before.event_exited.dapui_config = function() - dapui.close() - end - end - }, - { - "jay-babu/mason-nvim-dap.nvim", - config = function() - require ('mason-nvim-dap').setup({ - handlers = { - function(config) - -- all sources with no handler get passed here - -- Keep original functionality - require('mason-nvim-dap').default_setup(config) - end, - }, - }) - end, - }, - { - "Saecki/crates.nvim", - lazy = true, - keys = function() - local crates = require("crates") - local opts = { silent = true } - - vim.keymap.set("n", "cct", crates.toggle, { desc = 'toggle' }) - vim.keymap.set("n", "ccr", crates.reload, { desc = 'reload' }) - vim.keymap.set("n", "ccv", crates.show_versions_popup, { desc = 'show versions' }) - vim.keymap.set("n", "ccf", crates.show_features_popup, { desc = 'show features' }) - vim.keymap.set("n", "ccd", crates.show_dependencies_popup, { desc = 'show dependencies' }) - vim.keymap.set("n", "ccu", crates.update_crate, { desc = 'update' }) - vim.keymap.set("v", "ccu", crates.update_crates, { desc = 'update' }) - vim.keymap.set("n", "cca", crates.update_all_crates, { desc = 'update all' }) - vim.keymap.set("n", "ccU", crates.upgrade_crate, { desc = 'upgrade' }) - vim.keymap.set("v", "ccU", crates.upgrade_crates, { desc = 'upgrade' }) - vim.keymap.set("n", "ccA", crates.upgrade_all_crates, { desc = 'upgrade all' }) - vim.keymap.set("n", "ccx", crates.expand_plain_crate_to_inline_table, { desc = 'expand' }) - vim.keymap.set("n", "ccX", crates.extract_crate_into_table, { desc = 'extract' }) - vim.keymap.set("n", "ccH", crates.open_homepage, { desc = 'open homepage' }) - vim.keymap.set("n", "ccR", crates.open_repository, { desc = 'open repository' }) - vim.keymap.set("n", "ccD", crates.open_documentation, { desc = 'open documents' }) - vim.keymap.set("n", "ccC", crates.open_crates_io, { desc = 'open crates.io' }) - vim.keymap.set("n", "ccL", crates.open_lib_rs, { desc = 'open lib.rs' }) - end, - opts = { - completion = { - crates = { - enabled = true, - }, - }, - lsp = { - enabled = true, - actions = true, - completion = true, - hover = true, - }, - }, - }, - -- { - -- 'mrcjkb/rustaceanvim', - -- -- version = '^6', -- Recommended - -- lazy = true, - -- ft = {'rust'}, - -- opts = { - -- server = { - -- default_settings = { - -- cargo = { - -- allFeatures = false, - -- loadOutDirsFromCheck = true, - -- buildScripts = { enable = true }, - -- }, - -- }, - -- on_attach = function(_, bufnr) - -- vim.keymap.set("n", "lr", function() - -- vim.cmd.RustLsp("codeAction") - -- end, { desc = "Code Action", buffer = bufnr }) - -- vim.keymap.set("n", "ld", function() - -- vim.cmd.RustLsp("debuggables") - -- end, { desc = "Rust Debuggables", buffer = bufnr }) - -- vim.keymap.set("n", "lD", function() - -- vim.cmd.RustLsp("openDocs") - -- end, { desc = "Open Documents", buffer = bufnr }) - -- vim.keymap.set("n", "lc", function() - -- vim.cmd.RustLsp("openCargo") - -- end, { desc = "Open Documents", buffer = bufnr }) - -- end, - -- }, - -- }, - -- config = function(_, opts) - -- vim.g.rustaceanvim = vim.tbl_deep_extend("keep", vim.g.rustaceanvim or {}, opts or {}) - -- end, - -- }, - { - -- Highlight, edit, and navigate code - 'nvim-treesitter/nvim-treesitter', - build = ':TSUpdate', - branch = 'main', - dependencies = { - -- 'p00f/nvim-ts-rainbow', - }, - config = function() - local ts_parsers = { - "bash", - "dockerfile", - "git_config", "git_rebase", "gitattributes", "gitcommit", "gitignore", - "go", "gomod", "gosum", - "json", "toml", "yaml", - "lua", - "make", - "markdown", - "python", - "terraform", - "vim", "vimdoc", - 'c', - "lua", - "markdown", - "markdown_inline", - "query", - "html", "xml", - "zig", - "typescript", "javascript", "svelte", - "regex", - "rust", - "http", - } - - local nts = require("nvim-treesitter") - nts.install(ts_parsers) - -- vim.api.nvim_create_autocmd('PackChanged', { - -- callback = function() - -- nts.update() - -- end - -- }) - - vim.api.nvim_create_autocmd("FileType", { -- enable treesitter highlighting and indents - callback = function(args) - local filetype = args.match - local lang = vim.treesitter.language.get_lang(filetype) - if vim.treesitter.language.add(lang) then - vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()" - vim.treesitter.start() - end - end - }) - - -- vim.api.nvim_create_autocmd('FileType', { - -- pattern = ts_parsers, - -- callback = function() - -- vim.treesitter.start() - -- end, - -- }) - end, - }, - { - 'nvim-treesitter/nvim-treesitter-textobjects', - branch = "main", - init = function() - vim.g.no_plugin_maps = true - end, - }, - { - 'JoosepAlviste/nvim-ts-context-commentstring', - lazy = true, - opts = { - enable_autocmd = false, - } - }, - { - 'nvim-treesitter/nvim-treesitter-context', - enabled = true, - config = function () - require("treesitter-context").setup({ - mode = "cursor", - max_lines = 3, - multiline_threshold = 1, - separator = '-', - min_window_height = 20, - line_numbers = true, - }) - end, - }, - { - "mbbill/undotree", - lazy = true, - keys = { - { 'uu', vim.cmd.UndotreeToggle, desc = 'Format buffer' } - }, - }, - { - 'Civitasv/cmake-tools.nvim', - lazy = true, - config = function () - local osys = require("cmake-tools.osys") - require("cmake-tools").setup { - cmake_command = "cmake", -- this is used to specify cmake command path - ctest_command = "ctest", -- this is used to specify ctest command path - cmake_use_preset = true, - cmake_regenerate_on_save = true, -- auto generate when save CMakeLists.txt - cmake_generate_options = { "-DCMAKE_EXPORT_COMPILE_COMMANDS=1" }, -- this will be passed when invoke `CMakeGenerate` - cmake_build_options = {}, -- this will be passed when invoke `CMakeBuild` - -- support macro expansion: - -- ${kit} - -- ${kitGenerator} - -- ${variant:xx} - cmake_build_directory = function() - if osys.iswin32 then - return "out\\${variant:buildType}" - end - return "out/${variant:buildType}" - end, -- this is used to specify generate directory for cmake, allows macro expansion, can be a string or a function returning the string, relative to cwd. - cmake_soft_link_compile_commands = true, -- this will automatically make a soft link from compile commands file to project root dir - cmake_compile_commands_from_lsp = false, -- this will automatically set compile commands file location using lsp, to use it, please set `cmake_soft_link_compile_commands` to false - cmake_kits_path = nil, -- this is used to specify global cmake kits path, see CMakeKits for detailed usage - cmake_variants_message = { - short = { show = true }, -- whether to show short message - long = { show = true, max_length = 40 }, -- whether to show long message - }, - cmake_dap_configuration = { -- debug settings for cmake - name = "cpp", - type = "codelldb", - request = "launch", - stopOnEntry = false, - runInTerminal = true, - console = "integratedTerminal", - }, - cmake_executor = { -- executor to use - name = "quickfix", -- name of the executor - opts = {}, -- the options the executor will get, possible values depend on the executor type. See `default_opts` for possible values. - default_opts = { -- a list of default and possible values for executors - quickfix = { - show = "always", -- "always", "only_on_error" - position = "belowright", -- "vertical", "horizontal", "leftabove", "aboveleft", "rightbelow", "belowright", "topleft", "botright", use `:h vertical` for example to see help on them - size = 10, - encoding = "utf-8", -- if encoding is not "utf-8", it will be converted to "utf-8" using `vim.fn.iconv` - auto_close_when_success = true, -- typically, you can use it with the "always" option; it will auto-close the quickfix buffer if the execution is successful. - }, - toggleterm = { - direction = "float", -- 'vertical' | 'horizontal' | 'tab' | 'float' - close_on_exit = false, -- whether close the terminal when exit - auto_scroll = true, -- whether auto scroll to the bottom - singleton = true, -- single instance, autocloses the opened one, if present - }, - overseer = { - new_task_opts = { - strategy = { - "toggleterm", - direction = "horizontal", - autos_croll = true, - quit_on_exit = "success" - } - }, -- options to pass into the `overseer.new_task` command - on_new_task = function(task) - require("overseer").open( - { enter = false, direction = "right" } - ) - end, -- a function that gets overseer.Task when it is created, before calling `task:start` - }, - terminal = { - name = "Main Terminal", - prefix_name = "[CMakeTools]: ", -- This must be included and must be unique, otherwise the terminals will not work. Do not use a simple spacebar " ", or any generic name - split_direction = "horizontal", -- "horizontal", "vertical" - split_size = 11, - - -- Window handling - single_terminal_per_instance = true, -- Single viewport, multiple windows - single_terminal_per_tab = true, -- Single viewport per tab - keep_terminal_static_location = true, -- Static location of the viewport if avialable - auto_resize = true, -- Resize the terminal if it already exists - - -- Running Tasks - start_insert = false, -- If you want to enter terminal with :startinsert upon using :CMakeRun - focus = false, -- Focus on terminal when cmake task is launched. - do_not_add_newline = false, -- Do not hit enter on the command inserted when using :CMakeRun, allowing a chance to review or modify the command before hitting enter. - }, -- terminal executor uses the values in cmake_terminal - }, - }, - cmake_runner = { -- runner to use - name = "terminal", -- name of the runner - opts = {}, -- the options the runner will get, possible values depend on the runner type. See `default_opts` for possible values. - default_opts = { -- a list of default and possible values for runners - quickfix = { - show = "always", -- "always", "only_on_error" - position = "belowright", -- "bottom", "top" - size = 10, - encoding = "utf-8", - auto_close_when_success = true, -- typically, you can use it with the "always" option; it will auto-close the quickfix buffer if the execution is successful. - }, - toggleterm = { - direction = "float", -- 'vertical' | 'horizontal' | 'tab' | 'float' - close_on_exit = false, -- whether close the terminal when exit - auto_scroll = true, -- whether auto scroll to the bottom - singleton = true, -- single instance, autocloses the opened one, if present - }, - overseer = { - new_task_opts = { - strategy = { - "toggleterm", - direction = "horizontal", - autos_croll = true, - quit_on_exit = "success" - } - }, -- options to pass into the `overseer.new_task` command - on_new_task = function(task) - end, -- a function that gets overseer.Task when it is created, before calling `task:start` - }, - terminal = { - name = "Main Terminal", - prefix_name = "[CMakeTools]: ", -- This must be included and must be unique, otherwise the terminals will not work. Do not use a simple spacebar " ", or any generic name - split_direction = "horizontal", -- "horizontal", "vertical" - split_size = 11, - - -- Window handling - single_terminal_per_instance = true, -- Single viewport, multiple windows - single_terminal_per_tab = true, -- Single viewport per tab - keep_terminal_static_location = true, -- Static location of the viewport if avialable - auto_resize = true, -- Resize the terminal if it already exists - - -- Running Tasks - start_insert = false, -- If you want to enter terminal with :startinsert upon using :CMakeRun - focus = false, -- Focus on terminal when cmake task is launched. - do_not_add_newline = false, -- Do not hit enter on the command inserted when using :CMakeRun, allowing a chance to review or modify the command before hitting enter. - }, - }, - }, - cmake_notifications = { - runner = { enabled = true }, - executor = { enabled = true }, - spinner = { "⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏" }, -- icons used for progress display - refresh_rate_ms = 100, -- how often to iterate icons - }, - cmake_virtual_text_support = true, -- Show the target related to current file using virtual text (at right corner) - } - end, - }, - { - "folke/persistence.nvim", - event = "BufReadPre", - opts = { options = { "buffers", "curdir", "tabpages", "winsize", "help", "globals", "skiprtp" } }, - -- stylua: ignore - keys = { - { "xr", function() require("persistence").load() end, desc = "Restore Session" }, - { "xs", function() require("persistence").save() end, desc = "Save Session" }, - { "xl", function() require("persistence").load({ last = true }) end, desc = "Restore Last Session" }, - { "xd", function() require("persistence").stop() end, desc = "Don't Save Current Session" }, - }, - }, - - { - "otavioschwanck/arrow.nvim", - dependencies = { - { - "nvim-tree/nvim-web-devicons" - }, - -- or if using `mini.icons` - -- { "echasnovski/mini.icons" }, - }, - opts = { - show_icons = true, - leader_key = ';', -- Recommended to be a single key - buffer_leader_key = ';', -- Per Buffer Mappings - } - }, - { - "nvim-pack/nvim-spectre", - lazy = true, - cmd = { "Spectre" }, - keys = { - { "sr", function() require("spectre").open() end, desc = "Replace in files (Spectre)" }, - }, - opts = { - open_cmd = "noswapfile vnew", - highlight = { - search = "SpectreSearch", - replace = "SpectreReplace", - }, - mapping = { - ["send_to_qf"] = { - map = "", - cmd = "lua require('spectre.actions').send_to_qf()", - desc = "send all items to quickfix", - }, - }, - } - }, - { - 'stevearc/overseer.nvim', - keys = { - { "xo", "OverseerOpen", desc = "Open Overseer" }, - { "to", "OverseerToggle", desc = "Overseer Toggle" }, - { "", "OverseerRun", desc = "Run Overseer" }, - { "", "OverseerToggle", desc = "Overseer Toggle" }, - }, - config = function() - require("overseer").setup({ - templates = { "builtin", "user" }, - component_aliases = { - default = { - { 'display_duration', detail_level = 2 }, - 'on_output_summarize', - 'on_exit_set_status', - 'on_result_diagnostics_quickfix', - 'on_complete_notify', - { "on_complete_dispose", require_view = { "SUCCESS", "FAILURE" } }, - }, - default_vscode = { - 'default', - 'on_result_diagnostics', - 'on_result_diagnostics_quickfix', - 'on_complete_notify', - }, - } - }) - -- local pm = require("overseer.template.vscode.problem_matcher") - -- pm.register_problem_matcher("$rustc", { - -- fileLocation = { "autoDetect", "${cwd}" }, - -- pattern = { - -- --regexp = "^(.*?)-->\\s+(.*?):(\\d+):(\\d+)$", - -- -- vim_regexp = "\\v^(.*?)-->\\s+(.*?):(\\d+):(\\d+)$", - -- regexp = "^\\s+-->\\s*([^:]*):(\\d+):(\\d+)$", - -- vim_regexp = "\\v^\\s+-->\\s*([^:]*):(\\d+):(\\d+)$", - -- file = 1, - -- line = 2, - -- column = 3, - -- } - -- }) - - end, - }, - -} - diff --git a/config/nvim-old/lua/plugins/init.lua b/config/nvim-old/lua/plugins/init.lua deleted file mode 100644 index 39aacf8..0000000 --- a/config/nvim-old/lua/plugins/init.lua +++ /dev/null @@ -1,134 +0,0 @@ -return { - { "nvim-lua/plenary.nvim", lazy = true }, - { "nvim-tree/nvim-web-devicons", lazy = true, opts = {} }, - { - 'nvim-mini/mini.extra', - lazy = true, - }, - { - 'nvim-mini/mini.ai', - lazy = false, - version = '*', - dependencies = { - 'nvim-treesitter/nvim-treesitter-textobjects', - }, - config = function() - local MiniExtra = require('mini.extra') - local ai = require('mini.ai') - local spec_treesitter = ai.gen_spec.treesitter - ai.setup({ - custom_textobjects = { - F = spec_treesitter({ a = '@function.outer', i = '@function.inner' }), - C = spec_treesitter({ a = '@comment.outer', i = '@comment.inner' }), - P = spec_treesitter({ a = '@parameter.outer', i = '@parameter.inner' }), - O = spec_treesitter({ a = '@block.outter', i = '@block.inner' }), - k = spec_treesitter({ a = '@class.outer', i = '@class.inner' }), - o = spec_treesitter({ - a = { '@conditional.outer', '@loop.outer' }, - i = { '@conditional.inner', '@loop.inner' }, - }) - } - }) - end - }, - { - 'nvim-mini/mini.move', - lazy = false, - version = '*', - opts = {} - }, - { 'nvim-mini/mini.align', lazy = false, version = '*', opts = {} }, - { 'nvim-mini/mini.bracketed', lazy = false, version = '*', opts = {} }, - { - 'nvim-mini/mini.operators', - lazy = false, - version = '*', - opts = { - evaluate = { prefix = 'g|', func = nil, }, - exchange = { prefix = 'g.', reindent_linewise = true, }, - multiply = { prefix = 'gm', func = nil, }, - replace = { prefix = 'gk', reindent_linewise = true, }, - sort = { prefix = 'gs', func = nil, } - } - }, - { - 'nvim-mini/mini.surround', - lazy = false, - version = '*', - opts = { - -- Add custom surroundings to be used on top of builtin ones. For more - -- information with examples, see `:h MiniSurround.config`. - -- custom_surroundings = { - -- s = { input = { '%[%[().-()%]%]' }, output = { left = '[[', right = ']]' } }, - -- }, - mappings = { - add = 'sa', -- Add surrounding in Normal and Visual modes - delete = 'sd', -- Delete surrounding - find = 'sf', -- Find surrounding (to the right) - find_left = 'sF', -- Find surrounding (to the left) - highlight = 'sh', -- Highlight surrounding - replace = 'sr', -- Replace surrounding - update_n_lines = 'sn', -- Update `n_lines` - - suffix_last = 'l', -- Suffix to search with "prev" method - suffix_next = 'n', -- Suffix to search with "next" method - }, - } - }, - { - 'nvim-mini/mini.splitjoin', - lazy = false, - version = false, - config = function() - require('mini.splitjoin').setup() - end, - }, - { - "nvim-mini/mini.hipatterns", - lazy = false, - event = "BufReadPre", - config = function() - local MiniExtra = require("mini.extra") - local hi_words = MiniExtra.gen_highlighter.words - require('mini.hipatterns').setup({ - highlighters = { - -- Highlight standalone 'FIXME', 'HACK', 'TODO', 'NOTE' - fixme = hi_words({ 'FIXME', 'Fixme', 'fixme' }, "MiniHipatternsFixme"), - hack = hi_words({ 'HACK', 'Hack', 'hack' }, "MiniHipatternsHack"), - todo = hi_words({ 'TODO', 'Todo', 'todo' }, "MiniHipatternsTodo"), - note = hi_words({ 'NOTE', 'Note', 'note' }, "MiniHipatternsNote"), - done = hi_words({ 'DONE', 'Done', 'done' }, "MiniHipatternsFixme"), - - -- Highlight hex color strings (`#rrggbb`) using that color - -- hex_color = hipatterns.gen_highlighter.hex_color(), - }, - }) - end, - }, - { - 'nvim-mini/mini.files', - event = 'VeryLazy', - version = '*', - keys = { - { "-", function() require("mini.files").open(vim.api.nvim_buf_get_name(0)) end, desc = "Open parent directory", mode = "n" }, - { "-", function() require("mini.files").open() end, desc = "File Explore", mode = "n" }, - }, - opts = { - mappings = { - go_in = "", -- Map both Enter and L to enter directories or open files - go_in_plus = "L", - go_out = "-", - go_out_plus = "H", - close = "", - }, - } - }, - { - 'nvim-mini/mini.sessions', - version = '*', - lazy = false, - config = function() - require('mini.sessions').setup() - end, - }, -} diff --git a/config/nvim-old/lua/plugins/tools.lua b/config/nvim-old/lua/plugins/tools.lua deleted file mode 100644 index cc91aa4..0000000 --- a/config/nvim-old/lua/plugins/tools.lua +++ /dev/null @@ -1,89 +0,0 @@ -return { - { - "al1-ce/just.nvim", - dependencies = { - 'nvim-lua/plenary.nvim', -- async jobs - 'j-hui/fidget.nvim', -- task progress (optional) - }, - config = true - }, - { - 'mistweaverco/kulala.nvim', - ft = {"http", "rest"}, - }, - { - "HakonHarnes/img-clip.nvim", - event = "VeryLazy", - opts = { - -- add options here - -- or leave it empty to use the default settings - }, - keys = { - -- suggested keymap - { "kp", "PasteImage", desc = "Paste image from system clipboard" }, - }, - }, - { - "uhs-robert/sshfs.nvim", - opts = { - mounts = { - base_dir = vim.fn.expand("$HOME") .. "/Public", -- where remote mounts are created - }, - -- Refer to the configuration section below - -- or leave empty for defaults - }, - }, - { - "esmuellert/codediff.nvim", - dependencies = { "MunifTanjim/nui.nvim" }, - cmd = "CodeDiff", - }, - { - "https://plugins.ejri.dev/mise.nvim", - keys = { - { "xm", "Lazy reload mise.nvim", desc = "Reload mise environment" } - }, - opts = { - unset_vars = true, - load_on_setup = true, - force_run = true, - } - }, - { - 'NeogitOrg/neogit', - dependencies = { - 'nvim-lua/plenary.nvim', -- required - 'sindrets/diffview.nvim', - }, - lazy = true, - keys = { - { 'gn', "Neogit kind=auto", desc = 'Neogit'}, - { 'gN', "Neogit kind=floating", desc = 'Neogit'} - }, - opts = { - -- disable_context_highlighting = true, - disable_commit_confirmation = true, - disable_insert_on_commit = false, - disable_signs = true, - integrations = { diffview = true, fz_lua = false }, - auto_refresh = false, - console_timeout = 5000, - auto_show_console = false, - sections = { - stashes = { - folded = false, - }, - recent = { folded = false }, - }, - } - }, - { - "thunder-coding/zincoxide", - opts = { - zincoxide_cmd = "zoxide", - complete = true, - behaviour = "tabs", - }, - cmd = { "Z", "Zg", "Zt", "Zw" }, - }, -} diff --git a/config/nvim-old/lua/plugins/ui.lua b/config/nvim-old/lua/plugins/ui.lua deleted file mode 100644 index c78f3da..0000000 --- a/config/nvim-old/lua/plugins/ui.lua +++ /dev/null @@ -1,308 +0,0 @@ -return { - { 'j-hui/fidget.nvim', lazy = true }, - { - "utilyre/barbecue.nvim", - dependencies = { - { 'SmiteshP/nvim-navic', lazy = true }, - }, - event = "VeryLazy", - opts = {}, - }, - { - "folke/flash.nvim", - event = "VeryLazy", - ---@type Flash.Config - opts = { - modes = { - char = { - jump_labels = true, - search = { wrap = true }, - highlight = { backdrop = false }, - }, - search = { - -- when `true`, flash will be activated during regular search by default. - -- You can always toggle when searching with `require("flash").toggle()` - enabled = true, - highlight = { backdrop = false }, - jump = { history = true, register = true, nohlsearch = true, autojump = true }, - search = { - wrap = true, - -- `forward` will be automatically set to the search direction - -- `mode` is always set to `search` - -- `incremental` is set to `true` when `incsearch` is enabled - }, - }, - treesitter = { - search = { wrap = true }, - } - }, - }, - -- stylua: ignore - keys = { - { "/", mode = { "n" }, function() require("flash").treesitter() end, desc = "Flash Treesitter" }, - { "s", mode = { "x", "o" }, function() require("flash").treesitter() end, desc = "Flash Treesitter" }, - { "r", mode = "o", function() require("flash").remote() end, desc = "Remote Flash" }, - { "R", mode = { "o", "x" }, function() require("flash").treesitter_search() end, desc = "Treesitter Search" }, - { "", mode = { "c" }, function() require("flash").toggle() end, desc = "Toggle Flash Search" }, - }, - }, - { - "folke/snacks.nvim", - opts = { - notifier = { - timeout = 4000, - }, - picker = { - win = { - input = { - keys = { - [""] = { "flash", mode = { "n", "i" } }, - ["s"] = { "flash" }, - }, - }, - }, - actions = { - flash = function(picker) - require("flash").jump({ - pattern = "^", - label = { after = { 0, 0 } }, - search = { - mode = "search", - exclude = { - function(win) - return vim.bo[vim.api.nvim_win_get_buf(win)].filetype ~= "snacks_picker_list" - end, - }, - }, - action = function(match) - local idx = picker.list:row2idx(match.pos[1]) - picker.list:_move(idx, true, true) - end, - }) - end, - }, - }, - }, - }, - { - 'nvim-lualine/lualine.nvim', - event = "VeryLazy", - config = function() - local function truncate_branch_name(branch) - if not branch or branch == "" then - return "" - end - - -- Match the branch name to the specified format - local _, _, ticket_number = string.find(branch, "skdillon/sko%-(%d+)%-") - - -- If the branch name matches the format, display sko-{ticket_number}, otherwise display the full branch name - if ticket_number then - return "sko-" .. ticket_number - else - return branch - end - end - - require("lualine").setup({ - options = { - -- theme = "rose-pine", - globalstatus = true, - -- component_separators = { left = "", right = "" }, - -- section_separators = { left = "█", right = "█" }, - icons_enabled = true, - component_separators = { left = '', right = ''}, - section_separators = { left = '', right = ''}, - tabline = { - lualine_a = {}, - lualine_b = {'branch'}, - lualine_c = {'filename'}, - lualine_x = {}, - lualine_y = {}, - lualine_z = {} - }, - }, - sections = { - lualine_b = { - { "branch", icon = "", fmt = truncate_branch_name }, - "diff", - "diagnostics", - }, - lualine_c = { - { 'lsp_progress' }, - { - 'buffers', - show_filename_only = true, -- Shows shortened relative path when set to false. - hide_filename_extension = false, -- Hide filename extension when set to true. - show_modified_status = true, -- Shows indicator when the buffer is modified. - mode = 0, - max_length = vim.o.columns * 2 / 3, - filetype_names = { - TelescopePrompt = ' ', - }, - -- it can also be a function that returns - -- the value of `max_length` dynamically. - use_mode_colors = false, - symbols = { - modified = ' ●', -- Text to show when the buffer is modified - alternate_file = '#', -- Text to show to identify the alternate file - directory = '', -- Text to show when the buffer is a directory - }, - }, - }, - lualine_x = { - "windows", - "fileformat", - "filetype", - }, - }, - }) - end, - }, - { - "hedyhli/outline.nvim", - lazy = true, - cmd = { "Outline", "OutlineOpen" }, - keys = { -- Example mapping to toggle outline - { "so", "Outline", desc = "Toggle outline" }, - }, - opts = { - symbol_folding = { - -- Unfold entire symbol tree by default with false, otherwise enter a - -- number starting from 1 - autofold_depth = false, - -- autofold_depth = 1, - }, - }, - }, - { - 'stevearc/quicker.nvim', - ft = "qf", - opts = {}, - }, - { - "christoomey/vim-tmux-navigator", - cmd = { - "TmuxNavigateLeft", - "TmuxNavigateDown", - "TmuxNavigateUp", - "TmuxNavigateRight", - "TmuxNavigatePrevious", - }, - keys = { - { "", "TmuxNavigateLeft" }, - { "", "TmuxNavigateDown" }, - { "", "TmuxNavigateUp" }, - { "", "TmuxNavigateRight" }, - -- { "", "TmuxNavigatePrevious" }, - }, - }, - { - 'akinsho/toggleterm.nvim', - lazy = false, - config = function() - require("toggleterm").setup({ - -- highlights = require("rose-pine.plugins.toggleterm"), - size = 20, - open_mapping = [[]], - hide_numbers = true, - shade_terminals = true, - shading_factor = 2, - start_in_insert = true, - insert_mappings = true, - persiste_size = true, - direction = 'horizontal', - close_on_exit = true, - float_opts = { - border = "curved", - } - }) - end, - keys = { - { "", "", desc = "Escape input", mode = { "t" } } - }, - }, - { - 'ten3roberts/window-picker.nvim', - opts = { - -- Default keys to annotate, keys will be used in order. The default uses the - -- most accessible keys from the home row and then top row. - keys = 'alskdjfhgwoeiruty', - -- Swap windows by holding shift + letter - swap_shift = true, - -- Windows containing filetype to exclude - exclude = { qf = true, NvimTree = true, aerial = true }, - -- Flash the cursor line of the newly focused window for 300ms. - -- Set to 0 or false to disable. - flash_duration = 300, - }, - keys = { - { "a", "WindowPick", desc = "Windows Pick"}, - { "a", "WindowPick", desc = "Windows Pick"}, - { "D", "WindowZap", desc = "Windows Delete"}, - { "S", "WindowSwap", desc = "Windows Swap"}, - }, - }, - { - "folke/which-key.nvim", - event = "VimEnter", - opts = { - icons = { - -- set icon mappings to true if you have a Nerd Font - mappings = vim.g.have_nerd_font, - -- If you are using a Nerd Font: set icons.keys to an empty table which will use the - -- default whick-key.nvim defined Nerd Font icons, otherwise define a string table - keys = vim.g.have_nerd_font and {} or { - Up = ' ', - Down = ' ', - Left = ' ', - Right = ' ', - C = ' ', - M = ' ', - D = ' ', - S = ' ', - CR = ' ', - Esc = ' ', - ScrollWheelDown = ' ', - ScrollWheelUp = ' ', - NL = ' ', - BS = ' ', - Space = ' ', - Tab = ' ', - F1 = '', - F2 = '', - F3 = '', - F4 = '', - F5 = '', - F6 = '', - F7 = '', - F8 = '', - F9 = '', - F10 = '', - F11 = '', - F12 = '', - }, - }, - spec = { - { "g", group = "+goto" }, - { "]", group = "+next" }, - { "[", group = "+prev" }, - { "c", group = "+code", mode = { 'n', 'x' } }, - { "b", group = "+buffer" }, - { "f", group = "+find" }, - { "g", group = "+goto" }, - { "k", group = "+obsidian" }, - { "l", group = "+lsp" }, - { "m", group = "+bookmark" }, - { "o", group = "+notes" }, - { "r", group = "+ai" }, - { "s", group = "+search" }, - { "t", group = "+trouble" }, - { "v", group = "+vcs", mode = { 'n', 'v' } }, - { "w", group = "+workspace" }, - { "x", group = "+extra" }, - { "u", group = "+toggle" }, - }, - }, - }, -} diff --git a/config/nvim-old/lua/snippets/zig.lua b/config/nvim-old/lua/snippets/zig.lua deleted file mode 100644 index dcc9d2f..0000000 --- a/config/nvim-old/lua/snippets/zig.lua +++ /dev/null @@ -1,16 +0,0 @@ -local ls = require("luasnip") - local s = ls.snippet - local t = ls.text_node - local i = ls.insert_node - -- local f = ls.function_node - return { - s({ trig = "fn", name = "Function", dscr = "Function" }, { - t("fn "), - i(1), - t("() "), - t("{\n"), - t("\t"), - i(0), - t("\n}\n"), - }) - } \ No newline at end of file diff --git a/config/nvim-old/lua/tasks.lua b/config/nvim-old/lua/tasks.lua deleted file mode 100644 index 1b370c3..0000000 --- a/config/nvim-old/lua/tasks.lua +++ /dev/null @@ -1,92 +0,0 @@ -local M = {} - -local function get_current_time() - return os.date("%H:%M") -end - -local function get_active_task_line() - local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) - local active_lines = {} - for i, line in ipairs(lines) do - if line:match("#status/in%-progress") then - table.insert(active_lines, {line = line, lnum = i}) - end - end - - if #active_lines == 0 then - print("No active task found (#status/in-progress).") - return nil, "no_active" - elseif #active_lines > 1 then - print("Multiple active tasks found. Please ensure only one task is #status/in-progress.") - return nil, "multiple_active" - else - return active_lines[1].line, active_lines[1].lnum - end -end - -function M.create_new_task() - local desc = vim.fn.input("Task Description: ") - if desc == '' then return end - - local project = vim.fn.input("Project (leave empty if none, e.g., '[[Project Name]]'): ") - local priority_options = {"high", "medium", "low"} - local priority_idx = vim.fn.inputlist("Priority:", priority_options) - local priority = priority_options[tonumber(priority_idx)] or "medium" - - local category_options = {"work", "meeting", "learning", "journal", "focused-work", "break"} - local category_idx = vim.fn.inputlist("Category:", category_options) - local category = category_options[tonumber(category_idx)] or "work" - - local new_task_line = string.format("- [ ] %s %s #status/todo #priority/%s #%s", - desc, project, priority, category) - - vim.api.nvim_put({new_task_line}, "l", true, true) - print("New task created: " .. new_task_line) -end - -function M.start_task() - local current_line, lnum = get_active_task_line() - if not current_line then return end - - local new_line = current_line - local current_time = get_current_time() - - if new_line:match("start:: %d%d:%d%d") then - print("Task already has a start time. Updating to current time.") - new_line = new_line:gsub("start:: %d%d:%d%d", "start:: " .. current_time) - else - new_line = new_line .. " start:: " .. current_time - end - - -- Clear end time if present when starting a task again - new_line = new_line:gsub(" end:: %d%d:%d%d", "") - - vim.api.nvim_buf_set_lines(0, lnum - 1, lnum, false, {new_line}) - print("Task started/resumed: " .. current_time) -end - -function M.stop_task() - local current_line, lnum = get_active_task_line() - if not current_line then return end - - local new_line = current_line - local current_time = get_current_time() - - if new_line:match("end:: %d%d:%d%d") then - print("Task already has an end time. Updating to current time.") - new_line = new_line:gsub("end:: %d%d:%d%d", "end:: " .. current_time) - else - new_line = new_line .. " end:: " .. current_time - end - - -- Option to change status to done - local change_status = vim.fn.confirm("Change status to #status/done?", "&Yes\n&No", 2) - if change_status == 1 then -- Yes - new_line = new_line:gsub("#status/in%-progress", "#status/done") - end - - vim.api.nvim_buf_set_lines(0, lnum - 1, lnum, false, {new_line}) - print("Task stopped: " .. current_time) -end - -return M diff --git a/config/omarchy/default/alacritty.toml b/config/omarchy/default/alacritty.toml new file mode 100644 index 0000000..d43f3af --- /dev/null +++ b/config/omarchy/default/alacritty.toml @@ -0,0 +1,47 @@ +[colors.primary] +background = "#1a1b26" +foreground = "#a9b1d6" + +[colors.cursor] +text = "#1a1b26" +cursor = "#c0caf5" + +[colors.vi_mode_cursor] +text = "#1a1b26" +cursor = "#c0caf5" + +[colors.search.matches] +foreground = "#1a1b26" +background = "#e0af68" + +[colors.search.focused_match] +foreground = "#1a1b26" +background = "#f7768e" + +[colors.footer_bar] +foreground = "#1a1b26" +background = "#a9b1d6" + +[colors.selection] +text = "#c0caf5" +background = "#7aa2f7" + +[colors.normal] +black = "#32344a" +red = "#f7768e" +green = "#9ece6a" +yellow = "#e0af68" +blue = "#7aa2f7" +magenta = "#ad8ee6" +cyan = "#449dab" +white = "#787c99" + +[colors.bright] +black = "#444b6a" +red = "#ff7a93" +green = "#b9f27c" +yellow = "#ff9e64" +blue = "#7da6ff" +magenta = "#bb9af7" +cyan = "#0db9d7" +white = "#acb0d0" diff --git a/config/omarchy/default/backgrounds/0-swirl-buck.jpg b/config/omarchy/default/backgrounds/0-swirl-buck.jpg new file mode 100644 index 0000000..504f3db Binary files /dev/null and b/config/omarchy/default/backgrounds/0-swirl-buck.jpg differ diff --git a/config/omarchy/default/backgrounds/1-scenery-pink-lakeside-sunset-lake-landscape-scenic-panorama-7680x3215-144.png b/config/omarchy/default/backgrounds/1-scenery-pink-lakeside-sunset-lake-landscape-scenic-panorama-7680x3215-144.png new file mode 100644 index 0000000..d806728 Binary files /dev/null and b/config/omarchy/default/backgrounds/1-scenery-pink-lakeside-sunset-lake-landscape-scenic-panorama-7680x3215-144.png differ diff --git a/config/omarchy/default/backgrounds/1-sunset-lake.png b/config/omarchy/default/backgrounds/1-sunset-lake.png new file mode 100644 index 0000000..d806728 Binary files /dev/null and b/config/omarchy/default/backgrounds/1-sunset-lake.png differ diff --git a/config/omarchy/default/backgrounds/2-Pawel-Czerwinski-Abstract-Purple-Blue.jpg b/config/omarchy/default/backgrounds/2-Pawel-Czerwinski-Abstract-Purple-Blue.jpg new file mode 100644 index 0000000..2767138 Binary files /dev/null and b/config/omarchy/default/backgrounds/2-Pawel-Czerwinski-Abstract-Purple-Blue.jpg differ diff --git a/config/omarchy/default/backgrounds/2-pawel-czerwinski.jpg b/config/omarchy/default/backgrounds/2-pawel-czerwinski.jpg new file mode 100644 index 0000000..2767138 Binary files /dev/null and b/config/omarchy/default/backgrounds/2-pawel-czerwinski.jpg differ diff --git a/config/omarchy/default/backgrounds/3-Milad-Fakurian-Abstract-Purple-Blue.jpg b/config/omarchy/default/backgrounds/3-Milad-Fakurian-Abstract-Purple-Blue.jpg new file mode 100644 index 0000000..b9663ff Binary files /dev/null and b/config/omarchy/default/backgrounds/3-Milad-Fakurian-Abstract-Purple-Blue.jpg differ diff --git a/config/omarchy/default/backgrounds/3-milad-fakurian.jpg b/config/omarchy/default/backgrounds/3-milad-fakurian.jpg new file mode 100644 index 0000000..b9663ff Binary files /dev/null and b/config/omarchy/default/backgrounds/3-milad-fakurian.jpg differ diff --git a/config/omarchy/default/backgrounds/4-oma-cityscape.jpg b/config/omarchy/default/backgrounds/4-oma-cityscape.jpg new file mode 100644 index 0000000..f57916b Binary files /dev/null and b/config/omarchy/default/backgrounds/4-oma-cityscape.jpg differ diff --git a/config/omarchy/default/backgrounds/5-oma.jpg b/config/omarchy/default/backgrounds/5-oma.jpg new file mode 100644 index 0000000..3b85cd0 Binary files /dev/null and b/config/omarchy/default/backgrounds/5-oma.jpg differ diff --git a/config/omarchy/default/backgrounds/omarchy.png b/config/omarchy/default/backgrounds/omarchy.png new file mode 100644 index 0000000..0f52090 Binary files /dev/null and b/config/omarchy/default/backgrounds/omarchy.png differ diff --git a/config/omarchy/default/btop.theme b/config/omarchy/default/btop.theme new file mode 100644 index 0000000..290a3c7 --- /dev/null +++ b/config/omarchy/default/btop.theme @@ -0,0 +1,82 @@ +# Theme: tokyo-night +# By: Pascal Jaeger + +# Main bg +theme[main_bg]="#1a1b26" + +# Main text color +theme[main_fg]="#cfc9c2" + +# Title color for boxes +theme[title]="#cfc9c2" + +# Highlight color for keyboard shortcuts +theme[hi_fg]="#7dcfff" + +# Background color of selected item in processes box +theme[selected_bg]="#414868" + +# Foreground color of selected item in processes box +theme[selected_fg]="#cfc9c2" + +# Color of inactive/disabled text +theme[inactive_fg]="#565f89" + +# Misc colors for processes box including mini cpu graphs, details memory graph and details status text +theme[proc_misc]="#7dcfff" + +# Cpu box outline color +theme[cpu_box]="#565f89" + +# Memory/disks box outline color +theme[mem_box]="#565f89" + +# Net up/down box outline color +theme[net_box]="#565f89" + +# Processes box outline color +theme[proc_box]="#565f89" + +# Box divider line and small boxes line color +theme[div_line]="#565f89" + +# Temperature graph colors +theme[temp_start]="#9ece6a" +theme[temp_mid]="#e0af68" +theme[temp_end]="#f7768e" + +# CPU graph colors +theme[cpu_start]="#9ece6a" +theme[cpu_mid]="#e0af68" +theme[cpu_end]="#f7768e" + +# Mem/Disk free meter +theme[free_start]="#9ece6a" +theme[free_mid]="#e0af68" +theme[free_end]="#f7768e" + +# Mem/Disk cached meter +theme[cached_start]="#9ece6a" +theme[cached_mid]="#e0af68" +theme[cached_end]="#f7768e" + +# Mem/Disk available meter +theme[available_start]="#9ece6a" +theme[available_mid]="#e0af68" +theme[available_end]="#f7768e" + +# Mem/Disk used meter +theme[used_start]="#9ece6a" +theme[used_mid]="#e0af68" +theme[used_end]="#f7768e" + +# Download graph colors +theme[download_start]="#9ece6a" +theme[download_mid]="#e0af68" +theme[download_end]="#f7768e" + +# Upload graph colors +theme[upload_start]="#9ece6a" +theme[upload_mid]="#e0af68" +theme[upload_end]="#f7768e" + diff --git a/config/omarchy/default/chromium.theme b/config/omarchy/default/chromium.theme new file mode 100644 index 0000000..bf2774d --- /dev/null +++ b/config/omarchy/default/chromium.theme @@ -0,0 +1 @@ +26,27,38 diff --git a/config/omarchy/default/colors.toml b/config/omarchy/default/colors.toml new file mode 100644 index 0000000..fe51dd0 --- /dev/null +++ b/config/omarchy/default/colors.toml @@ -0,0 +1,23 @@ +accent = "#7aa2f7" +cursor = "#c0caf5" +foreground = "#a9b1d6" +background = "#1a1b26" +selection_foreground = "#c0caf5" +selection_background = "#7aa2f7" + +color0 = "#32344a" +color1 = "#f7768e" +color2 = "#9ece6a" +color3 = "#e0af68" +color4 = "#7aa2f7" +color5 = "#ad8ee6" +color6 = "#449dab" +color7 = "#787c99" +color8 = "#444b6a" +color9 = "#ff7a93" +color10 = "#b9f27c" +color11 = "#ff9e64" +color12 = "#7da6ff" +color13 = "#bb9af7" +color14 = "#0db9d7" +color15 = "#acb0d0" diff --git a/config/omarchy/default/foot.ini b/config/omarchy/default/foot.ini new file mode 100644 index 0000000..ee94dc4 --- /dev/null +++ b/config/omarchy/default/foot.ini @@ -0,0 +1,25 @@ +[colors-dark] +foreground=a9b1d6 +background=1a1b26 +selection-foreground=c0caf5 +selection-background=7aa2f7 + +cursor=1a1b26 c0caf5 + +regular0=32344a +regular1=f7768e +regular2=9ece6a +regular3=e0af68 +regular4=7aa2f7 +regular5=ad8ee6 +regular6=449dab +regular7=787c99 + +bright0=444b6a +bright1=ff7a93 +bright2=b9f27c +bright3=ff9e64 +bright4=7da6ff +bright5=bb9af7 +bright6=0db9d7 +bright7=acb0d0 diff --git a/config/omarchy/default/ghostty.conf b/config/omarchy/default/ghostty.conf new file mode 100644 index 0000000..505513f --- /dev/null +++ b/config/omarchy/default/ghostty.conf @@ -0,0 +1,22 @@ +background = #1a1b26 +foreground = #a9b1d6 +cursor-color = #c0caf5 +selection-background = #7aa2f7 +selection-foreground = #c0caf5 + +palette = 0=#32344a +palette = 1=#f7768e +palette = 2=#9ece6a +palette = 3=#e0af68 +palette = 4=#7aa2f7 +palette = 5=#ad8ee6 +palette = 6=#449dab +palette = 7=#787c99 +palette = 8=#444b6a +palette = 9=#ff7a93 +palette = 10=#b9f27c +palette = 11=#ff9e64 +palette = 12=#7da6ff +palette = 13=#bb9af7 +palette = 14=#0db9d7 +palette = 15=#acb0d0 diff --git a/config/omarchy/default/gum.env.conf b/config/omarchy/default/gum.env.conf new file mode 100644 index 0000000..88eeb89 --- /dev/null +++ b/config/omarchy/default/gum.env.conf @@ -0,0 +1,137 @@ +# Gum Style (generic) Variables +env = FOREGROUND,##a9b1d6 +env = BACKGROUND,##1a1b26 +env = BORDER_FOREGROUND,##7aa2f7 +env = BORDER_BACKGROUND,##1a1b26 + +# Gum Confirm Style Variables +env = GUM_CONFIRM_PROMPT_FOREGROUND,##7aa2f7 +env = GUM_CONFIRM_PROMPT_BACKGROUND,##1a1b26 +env = GUM_CONFIRM_SELECTED_FOREGROUND,##c0caf5 +env = GUM_CONFIRM_SELECTED_BACKGROUND,##7aa2f7 +env = GUM_CONFIRM_UNSELECTED_FOREGROUND,##a9b1d6 +env = GUM_CONFIRM_UNSELECTED_BACKGROUND,##1a1b26 + +# Gum Input Style Variables +env = GUM_INPUT_PROMPT_FOREGROUND,##7aa2f7 +env = GUM_INPUT_PROMPT_BACKGROUND,##1a1b26 +env = GUM_INPUT_PLACEHOLDER_FOREGROUND,##444b6a +env = GUM_INPUT_PLACEHOLDER_BACKGROUND,##1a1b26 +env = GUM_INPUT_CURSOR_FOREGROUND,##c0caf5 +env = GUM_INPUT_CURSOR_BACKGROUND,##1a1b26 +env = GUM_INPUT_HEADER_FOREGROUND,##a9b1d6 +env = GUM_INPUT_HEADER_BACKGROUND,##1a1b26 + +# Gum Choose Style Variables +env = GUM_CHOOSE_CURSOR_FOREGROUND,##7aa2f7 +env = GUM_CHOOSE_CURSOR_BACKGROUND,##1a1b26 +env = GUM_CHOOSE_HEADER_FOREGROUND,##a9b1d6 +env = GUM_CHOOSE_HEADER_BACKGROUND,##1a1b26 +env = GUM_CHOOSE_ITEM_FOREGROUND,##a9b1d6 +env = GUM_CHOOSE_ITEM_BACKGROUND,##1a1b26 +env = GUM_CHOOSE_SELECTED_FOREGROUND,##c0caf5 +env = GUM_CHOOSE_SELECTED_BACKGROUND,##7aa2f7 + +# Gum Filter Style Variables +env = GUM_FILTER_PROMPT_FOREGROUND,##7aa2f7 +env = GUM_FILTER_PROMPT_BACKGROUND,##1a1b26 +env = GUM_FILTER_TEXT_FOREGROUND,##a9b1d6 +env = GUM_FILTER_TEXT_BACKGROUND,##1a1b26 +env = GUM_FILTER_MATCH_FOREGROUND,##7aa2f7 +env = GUM_FILTER_CURSOR_TEXT_FOREGROUND,##c0caf5 +env = GUM_FILTER_CURSOR_TEXT_BACKGROUND,##1a1b26 +env = GUM_FILTER_SELECTED_FOREGROUND,##c0caf5 +env = GUM_FILTER_SELECTED_BACKGROUND,##7aa2f7 +env = GUM_FILTER_INDICATOR_FOREGROUND,##7aa2f7 +env = GUM_FILTER_HEADER_FOREGROUND,##a9b1d6 +env = GUM_FILTER_MATCH_BACKGROUND,##1a1b26 +env = GUM_FILTER_HEADER_BACKGROUND,##1a1b26 +env = GUM_FILTER_PLACEHOLDER_FOREGROUND,##444b6a +env = GUM_FILTER_PLACEHOLDER_BACKGROUND,##1a1b26 +env = GUM_FILTER_INDICATOR_BACKGROUND,##1a1b26 +env = GUM_FILTER_SELECTED_PREFIX_FOREGROUND,##c0caf5 +env = GUM_FILTER_SELECTED_PREFIX_BACKGROUND,##7aa2f7 +env = GUM_FILTER_UNSELECTED_PREFIX_FOREGROUND,##444b6a +env = GUM_FILTER_UNSELECTED_PREFIX_BACKGROUND,##1a1b26 + +# Gum Table Style Variables +env = GUM_TABLE_HEADER_FOREGROUND,##a9b1d6 +env = GUM_TABLE_HEADER_BACKGROUND,##1a1b26 +env = GUM_TABLE_CELL_FOREGROUND,##a9b1d6 +env = GUM_TABLE_CELL_BACKGROUND,##1a1b26 +env = GUM_TABLE_BORDER_FOREGROUND,##444b6a +env = GUM_TABLE_BORDER_BACKGROUND,##1a1b26 +env = GUM_TABLE_SELECTED_FOREGROUND,##c0caf5 +env = GUM_TABLE_SELECTED_BACKGROUND,##7aa2f7 + +# Gum Spin Style Variables +env = GUM_SPIN_SPINNER_FOREGROUND,##7aa2f7 +env = GUM_SPIN_SPINNER_BACKGROUND,##1a1b26 +env = GUM_SPIN_TITLE_FOREGROUND,##a9b1d6 +env = GUM_SPIN_TITLE_BACKGROUND,##1a1b26 + +# Gum File Style Variables +env = GUM_FILE_CURSOR_FOREGROUND,##c0caf5 +env = GUM_FILE_CURSOR_BACKGROUND,##1a1b26 +env = GUM_FILE_SYMLINK_FOREGROUND,##a9b1d6 +env = GUM_FILE_SYMLINK_BACKGROUND,##1a1b26 +env = GUM_FILE_DIRECTORY_FOREGROUND,##a9b1d6 +env = GUM_FILE_DIRECTORY_BACKGROUND,##1a1b26 +env = GUM_FILE_FILE_FOREGROUND,##a9b1d6 +env = GUM_FILE_FILE_BACKGROUND,##1a1b26 +env = GUM_FILE_PERMISSIONS_FOREGROUND,##444b6a +env = GUM_FILE_PERMISSIONS_BACKGROUND,##1a1b26 +env = GUM_FILE_SELECTED_FOREGROUND,##c0caf5 +env = GUM_FILE_SELECTED_BACKGROUND,##7aa2f7 +env = GUM_FILE_FILE_SIZE_FOREGROUND,##444b6a +env = GUM_FILE_FILE_SIZE_BACKGROUND,##1a1b26 +env = GUM_FILE_HEADER_FOREGROUND,##a9b1d6 +env = GUM_FILE_HEADER_BACKGROUND,##1a1b26 + +# Gum Pager Style Variables +env = GUM_PAGER_FOREGROUND,##a9b1d6 +env = GUM_PAGER_BACKGROUND,##1a1b26 +env = GUM_PAGER_LINE_NUMBER_FOREGROUND,##444b6a +env = GUM_PAGER_LINE_NUMBER_BACKGROUND,##1a1b26 +env = GUM_PAGER_MATCH_FOREGROUND,##7aa2f7 +env = GUM_PAGER_MATCH_BACKGROUND,##1a1b26 +env = GUM_PAGER_MATCH_HIGH_FOREGROUND,##7aa2f7 +env = GUM_PAGER_MATCH_HIGH_BACKGROUND,##1a1b26 +env = GUM_PAGER_HELP_FOREGROUND,##444b6a +env = GUM_PAGER_HELP_BACKGROUND,##1a1b26 + +# Gum Write Style Variables +env = GUM_WRITE_BASE_FOREGROUND,##a9b1d6 +env = GUM_WRITE_BASE_BACKGROUND,##1a1b26 +env = GUM_WRITE_CURSOR_LINE_NUMBER_FOREGROUND,##444b6a +env = GUM_WRITE_CURSOR_LINE_NUMBER_BACKGROUND,##1a1b26 +env = GUM_WRITE_CURSOR_LINE_FOREGROUND,##a9b1d6 +env = GUM_WRITE_CURSOR_LINE_BACKGROUND,##7aa2f7 +env = GUM_WRITE_CURSOR_FOREGROUND,##c0caf5 +env = GUM_WRITE_CURSOR_BACKGROUND,##1a1b26 +env = GUM_WRITE_END_OF_BUFFER_FOREGROUND,##444b6a +env = GUM_WRITE_END_OF_BUFFER_BACKGROUND,##1a1b26 +env = GUM_WRITE_LINE_NUMBER_FOREGROUND,##444b6a +env = GUM_WRITE_LINE_NUMBER_BACKGROUND,##1a1b26 +env = GUM_WRITE_HEADER_FOREGROUND,##a9b1d6 +env = GUM_WRITE_HEADER_BACKGROUND,##1a1b26 +env = GUM_WRITE_PLACEHOLDER_FOREGROUND,##444b6a +env = GUM_WRITE_PLACEHOLDER_BACKGROUND,##1a1b26 +env = GUM_WRITE_PROMPT_FOREGROUND,##a9b1d6 +env = GUM_WRITE_PROMPT_BACKGROUND,##1a1b26 + +# Gum Log Style Variables +env = GUM_LOG_LEVEL_FOREGROUND,##7aa2f7 +env = GUM_LOG_LEVEL_BACKGROUND,##1a1b26 +env = GUM_LOG_TIME_FOREGROUND,##444b6a +env = GUM_LOG_TIME_BACKGROUND,##1a1b26 +env = GUM_LOG_PREFIX_FOREGROUND,##a9b1d6 +env = GUM_LOG_PREFIX_BACKGROUND,##1a1b26 +env = GUM_LOG_MESSAGE_FOREGROUND,##a9b1d6 +env = GUM_LOG_MESSAGE_BACKGROUND,##1a1b26 +env = GUM_LOG_KEY_FOREGROUND,##a9b1d6 +env = GUM_LOG_KEY_BACKGROUND,##1a1b26 +env = GUM_LOG_VALUE_FOREGROUND,##a9b1d6 +env = GUM_LOG_VALUE_BACKGROUND,##1a1b26 +env = GUM_LOG_SEPARATOR_FOREGROUND,##444b6a +env = GUM_LOG_SEPARATOR_BACKGROUND,##1a1b26 \ No newline at end of file diff --git a/config/omarchy/default/helix.toml b/config/omarchy/default/helix.toml new file mode 100644 index 0000000..ac60283 --- /dev/null +++ b/config/omarchy/default/helix.toml @@ -0,0 +1,132 @@ +# Syntax +"keyword" = "color5" +"keyword.control" = { fg = "color5", modifiers = ["italic"] } +"function" = "color4" +"function.builtin" = "color4" +"function.macro" = "color5" +"type" = "color3" +"type.builtin" = "color5" +"type.enum.variant" = "color6" +"constructor" = "color4" +"constant" = "color3" +"constant.builtin" = "color3" +"constant.numeric" = "color3" +"constant.character" = "color6" +"constant.character.escape" = "color5" +"string" = "color2" +"string.regexp" = "color5" +"string.special" = "color4" +"comment" = { fg = "color8", modifiers = ["italic"] } +"variable" = "foreground" +"variable.parameter" = { fg = "color5", modifiers = ["italic"] } +"variable.builtin" = "color1" +"variable.other.member" = "color4" +"label" = "color4" +"punctuation" = "color8" +"punctuation.special" = "color6" +"operator" = "color6" +"tag" = "color4" +"namespace" = { fg = "color3", modifiers = ["italic"] } +"special" = "color5" +"attribute" = "color3" + +# Markup +"markup.heading.1" = "color1" +"markup.heading.2" = "color3" +"markup.heading.3" = "color3" +"markup.heading.4" = "color2" +"markup.heading.5" = "color4" +"markup.heading.6" = "color5" +"markup.list" = "color6" +"markup.list.unchecked" = "color8" +"markup.list.checked" = "color2" +"markup.bold" = { fg = "color1", modifiers = ["bold"] } +"markup.italic" = { fg = "color1", modifiers = ["italic"] } +"markup.strikethrough" = { modifiers = ["crossed_out"] } +"markup.link.url" = { fg = "color4", modifiers = ["italic", "underlined"] } +"markup.link.text" = "color5" +"markup.link.label" = "color4" +"markup.raw" = "color2" +"markup.quote" = "color5" + +# Diff +"diff.plus" = "color2" +"diff.minus" = "color1" +"diff.delta" = "color4" + +# Leave the editor background transparent so the terminal background shows through +"ui.background" = { } + +"ui.linenr" = { fg = "color8" } +"ui.linenr.selected" = { fg = "foreground" } + +# Statusline uses an inverted band (background-color text on foreground-color +# background) to guarantee contrast across both light and dark Omarchy themes. +"ui.statusline" = { fg = "background", bg = "foreground" } +"ui.statusline.inactive" = { fg = "background", bg = "color8" } +"ui.statusline.normal" = { fg = "background", bg = "color4", modifiers = ["bold"] } +"ui.statusline.insert" = { fg = "background", bg = "color2", modifiers = ["bold"] } +"ui.statusline.select" = { fg = "background", bg = "color5", modifiers = ["bold"] } + +"ui.popup" = { fg = "foreground", bg = "background" } +"ui.window" = { fg = "color8" } +"ui.help" = { fg = "foreground", bg = "background" } + +"ui.bufferline" = { fg = "color8", bg = "background" } +"ui.bufferline.active" = { fg = "foreground", bg = "background", underline = { color = "color5", style = "line" } } + +"ui.text" = "foreground" +"ui.text.focus" = { fg = "foreground", bg = "color0", modifiers = ["bold"] } +"ui.text.inactive" = { fg = "color8" } +"ui.text.directory" = { fg = "color4" } + +"ui.virtual" = "color8" +"ui.virtual.ruler" = { bg = "color0" } +"ui.virtual.indent-guide" = "color8" +"ui.virtual.inlay-hint" = { fg = "color8" } +"ui.virtual.jump-label" = { fg = "color1", modifiers = ["bold"] } +"ui.virtual.whitespace" = "color8" + +"ui.selection" = { bg = "selection_background", fg = "selection_foreground" } + +"ui.cursor" = { fg = "background", bg = "cursor" } +"ui.cursor.primary" = { fg = "background", bg = "cursor" } +"ui.cursor.match" = { fg = "color3", modifiers = ["bold"] } +"ui.cursor.primary.normal" = { fg = "background", bg = "cursor" } +"ui.cursor.primary.insert" = { fg = "background", bg = "color2" } +"ui.cursor.primary.select" = { fg = "background", bg = "color5" } + +"ui.cursorline.primary" = { bg = "color0" } + +"ui.highlight" = { bg = "color0", modifiers = ["bold"] } + +"ui.menu" = { fg = "foreground", bg = "background" } +"ui.menu.selected" = { fg = "background", bg = "foreground", modifiers = ["bold"] } + +"diagnostic.error" = { underline = { color = "color1", style = "curl" } } +"diagnostic.warning" = { underline = { color = "color3", style = "curl" } } +"diagnostic.info" = { underline = { color = "color4", style = "curl" } } +"diagnostic.hint" = { underline = { color = "color6", style = "curl" } } +"diagnostic.unnecessary" = { modifiers = ["dim"] } +"diagnostic.deprecated" = { modifiers = ["crossed_out"] } + +error = "color1" +warning = "color3" +info = "color4" +hint = "color6" + +[palette] +background = "#1a1b26" +foreground = "#a9b1d6" +cursor = "#c0caf5" +selection_background = "#7aa2f7" +selection_foreground = "#c0caf5" +color0 = "#32344a" +color1 = "#f7768e" +color2 = "#9ece6a" +color3 = "#e0af68" +color4 = "#7aa2f7" +color5 = "#ad8ee6" +color6 = "#449dab" +color7 = "#787c99" +color8 = "#444b6a" diff --git a/config/omarchy/default/hyprland-preview-share-picker.css b/config/omarchy/default/hyprland-preview-share-picker.css new file mode 100644 index 0000000..394d96d --- /dev/null +++ b/config/omarchy/default/hyprland-preview-share-picker.css @@ -0,0 +1,94 @@ +@define-color foreground #a9b1d6; +@define-color background #1a1b26; +@define-color accent #7aa2f7; +@define-color muted #444b6a; +@define-color card_bg #32344a; +@define-color text_dark #1a1b26; +@define-color accent_hover #7da6ff; +@define-color selected_tab #7aa2f7; +@define-color text #a9b1d6; + +* { + all: unset; + font-family: JetBrains Mono NF; + color: @foreground; + font-weight: bold; + font-size: 16px; +} + +.window { + background: alpha(@background, 0.95); + border: solid 2px @accent; + margin: 4px; + padding: 18px; +} + +tabs { + padding: 0.5rem 1rem; +} + +tabs > tab { + margin-right: 1rem; +} + +.tab-label { + color: @text; + transition: all 0.2s ease; +} + +tabs > tab:checked > .tab-label, tabs > tab:active > .tab-label { + text-decoration: underline currentColor; + color: @selected_tab; +} + +tabs > tab:focus > .tab-label { + color: @foreground; +} + +.page { + padding: 1rem; +} + +.image-label { + font-size: 12px; + padding: 0.25rem; +} + +flowboxchild > .card, button > .card { + transition: all 0.2s ease; + border: solid 2px transparent; + border-color: @background; + border-radius: 5px; + background-color: @card_bg; + padding: 5px; +} + +flowboxchild:hover > .card, button:hover > .card, flowboxchild:active > .card, flowboxchild:selected > .card, button:active > .card, button:selected > .card, button:focus > .card { + border: solid 2px @accent; +} + +.image { + border-radius: 5px; +} + +.region-button { + padding: 0.5rem 1rem; + border-radius: 5px; + background-color: @accent; + color: @text_dark; + transition: all 0.2s ease; +} + +.region-button > label { + color: @text_dark; +} + +.region-button:not(:disabled):hover, .region-button:not(:disabled):focus { + background-color: @accent_hover; + color: @text_dark; +} + +.region-button:disabled { + background-color: @muted; + color: @background; +} diff --git a/config/omarchy/default/hyprland.conf b/config/omarchy/default/hyprland.conf new file mode 100644 index 0000000..21b1afd --- /dev/null +++ b/config/omarchy/default/hyprland.conf @@ -0,0 +1,9 @@ +$activeBorderColor = rgb(7aa2f7) + +general { + col.active_border = $activeBorderColor +} + +group { + col.border_active = $activeBorderColor +} diff --git a/config/omarchy/default/hyprland.lua b/config/omarchy/default/hyprland.lua new file mode 100644 index 0000000..f791b1e --- /dev/null +++ b/config/omarchy/default/hyprland.lua @@ -0,0 +1,14 @@ +hl.config({ + general = { + col = { + active_border = { colors = {"rgb(7aa2f7)", "rgb(f7768e)" }, angle = 45 }, + inactive_border = { colors = {"rgb(9ece6a)", "rgb(9ece6a)" }, angle = 45 } + } + }, + group = { + col = { + border_active = { colors = {"rgb(7aa2f7)", "rgb(f7768e)" }, angle = 45 }, + border_inactive = { colors = {"rgb(9ece6a)", "rgb(9ece6a)" }, angle = 45 } + } + } +}) diff --git a/config/omarchy/default/hyprlock.conf b/config/omarchy/default/hyprlock.conf new file mode 100644 index 0000000..8de6ee7 --- /dev/null +++ b/config/omarchy/default/hyprlock.conf @@ -0,0 +1,5 @@ +$color = rgba(26,27,38, 1.0) +$inner_color = rgba(26,27,38, 0.8) +$outer_color = rgba(169,177,214, 1.0) +$font_color = rgba(169,177,214, 1.0) +$check_color = rgba(122,162,247, 1.0) diff --git a/config/omarchy/default/icons.theme b/config/omarchy/default/icons.theme new file mode 100644 index 0000000..5d00638 --- /dev/null +++ b/config/omarchy/default/icons.theme @@ -0,0 +1 @@ +Yaru-magenta diff --git a/config/omarchy/default/keyboard.rgb b/config/omarchy/default/keyboard.rgb new file mode 100644 index 0000000..c9f4a7c --- /dev/null +++ b/config/omarchy/default/keyboard.rgb @@ -0,0 +1 @@ +ff00ff diff --git a/config/omarchy/default/kitty.conf b/config/omarchy/default/kitty.conf new file mode 100644 index 0000000..2865cc4 --- /dev/null +++ b/config/omarchy/default/kitty.conf @@ -0,0 +1,27 @@ +foreground #a9b1d6 +background #1a1b26 +selection_foreground #c0caf5 +selection_background #7aa2f7 + +cursor #c0caf5 +cursor_text_color #1a1b26 + +active_border_color #7aa2f7 +active_tab_background #7aa2f7 + +color0 #32344a +color1 #f7768e +color2 #9ece6a +color3 #e0af68 +color4 #7aa2f7 +color5 #ad8ee6 +color6 #449dab +color7 #787c99 +color8 #444b6a +color9 #ff7a93 +color10 #b9f27c +color11 #ff9e64 +color12 #7da6ff +color13 #bb9af7 +color14 #0db9d7 +color15 #acb0d0 diff --git a/config/omarchy/default/mako.ini b/config/omarchy/default/mako.ini new file mode 100644 index 0000000..2045168 --- /dev/null +++ b/config/omarchy/default/mako.ini @@ -0,0 +1,40 @@ +text-color=#a9b1d6 +border-color=#7aa2f7 +background-color=#1a1b26 + +anchor=top-right +group-by=app-name,summary,body +default-timeout=5000 +width=420 +outer-margin=20 +padding=10,15 +border-size=2 +max-icon-size=32 +font=sans-serif 14px + +[app-name=Spotify] +invisible=1 + +[mode=do-not-disturb] +invisible=true + +[mode=do-not-disturb app-name=notify-send] +invisible=false + +[urgency=critical] +default-timeout=0 +layer=overlay + +[summary~="Setup Wi-Fi"] +on-button-left=exec sh -c 'omarchy-notification-dismiss "Setup Wi-Fi"; omarchy-launch-wifi' + +[summary~="Update System"] +on-button-left=exec sh -c 'omarchy-notification-dismiss "Update System"; omarchy-launch-floating-terminal-with-presentation omarchy-update' + +[summary~="Install Dictation with Voxtype"] +on-button-left=exec sh -c 'omarchy-notification-dismiss "Install Dictation with Voxtype"; omarchy-launch-floating-terminal-with-presentation omarchy-voxtype-install' + +[summary~="Screenshot copied & saved"] +max-icon-size=80 +format=%s\n%b + diff --git a/config/omarchy/default/neovim-vimpack.lua b/config/omarchy/default/neovim-vimpack.lua new file mode 100644 index 0000000..8b1a426 --- /dev/null +++ b/config/omarchy/default/neovim-vimpack.lua @@ -0,0 +1,12 @@ +vim.pack.add({{ src = 'https://github.com/folke/tokyonight.nvim' }}) +require("tokyonight").setup({ + style = "night", + transparent = true, + terminal_colors = true, + styles = { + sidebars = "transparent", + floats = "transparent", + }, +}) + +vim.cmd("colorscheme tokyonight") diff --git a/config/omarchy/default/neovim.lua b/config/omarchy/default/neovim.lua new file mode 100644 index 0000000..39327c9 --- /dev/null +++ b/config/omarchy/default/neovim.lua @@ -0,0 +1,12 @@ +return { + { + "folke/tokyonight.nvim", + priority = 1000, + }, + { + "LazyVim/LazyVim", + opts = { + colorscheme = "tokyonight-night", + }, + }, +} diff --git a/config/omarchy/default/obsidian.css b/config/omarchy/default/obsidian.css new file mode 100644 index 0000000..fea05b6 --- /dev/null +++ b/config/omarchy/default/obsidian.css @@ -0,0 +1,99 @@ +/* Omarchy Theme for Obsidian */ + +.theme-dark, .theme-light { + /* Core colors */ + --background-primary: #1a1b26; + --background-primary-alt: #1a1b26; + --background-secondary: #1a1b26; + --background-secondary-alt: #1a1b26; + --text-normal: #a9b1d6; + + /* Selection colors */ + --text-selection: #7aa2f7; + + /* Border color */ + --background-modifier-border: #444b6a; + + /* Semantic heading colors */ + --text-title-h1: #f7768e; + --text-title-h2: #9ece6a; + --text-title-h3: #e0af68; + --text-title-h4: #7aa2f7; + --text-title-h5: #ad8ee6; + --text-title-h6: #ad8ee6; + + /* Links and accents */ + --text-link: #7aa2f7; + --text-accent: #7aa2f7; + --text-accent-hover: #7aa2f7; + --interactive-accent: #7aa2f7; + --interactive-accent-hover: #7aa2f7; + + /* Muted text */ + --text-muted: color-mix(in srgb, #a9b1d6 70%, transparent); + --text-faint: color-mix(in srgb, #a9b1d6 55%, transparent); + + /* Code */ + --code-normal: #449dab; + + /* Errors and success */ + --text-error: #f7768e; + --text-error-hover: #f7768e; + --text-success: #9ece6a; + + /* Tags */ + --tag-color: #449dab; + --tag-background: #444b6a; + + /* Graph */ + --graph-line: #444b6a; + --graph-node: #7aa2f7; + --graph-node-focused: #7aa2f7; + --graph-node-tag: #449dab; + --graph-node-attachment: #9ece6a; +} + +/* Headers */ +.cm-header-1, .markdown-rendered h1 { color: var(--text-title-h1); } +.cm-header-2, .markdown-rendered h2 { color: var(--text-title-h2); } +.cm-header-3, .markdown-rendered h3 { color: var(--text-title-h3); } +.cm-header-4, .markdown-rendered h4 { color: var(--text-title-h4); } +.cm-header-5, .markdown-rendered h5 { color: var(--text-title-h5); } +.cm-header-6, .markdown-rendered h6 { color: var(--text-title-h6); } + +/* Code blocks */ +.markdown-rendered code { + color: #449dab; +} + +/* Syntax highlighting */ +.cm-s-obsidian span.cm-keyword { color: #f7768e; } +.cm-s-obsidian span.cm-string { color: #9ece6a; } +.cm-s-obsidian span.cm-number { color: #e0af68; } +.cm-s-obsidian span.cm-comment { color: #444b6a; } +.cm-s-obsidian span.cm-operator { color: #7aa2f7; } +.cm-s-obsidian span.cm-def { color: #7aa2f7; } + +/* Links */ +.markdown-rendered a { + color: var(--text-link); +} + +/* Blockquotes */ +.markdown-rendered blockquote { + border-left-color: #7aa2f7; +} + +/* Active elements */ +.workspace-leaf.mod-active .workspace-leaf-header-title { + color: var(--interactive-accent); +} + +.nav-file-title.is-active { + color: var(--interactive-accent); +} + +/* Search results */ +.search-result-file-title { + color: var(--interactive-accent); +} diff --git a/config/omarchy/default/preview-unlock.png b/config/omarchy/default/preview-unlock.png new file mode 100644 index 0000000..bb4897a Binary files /dev/null and b/config/omarchy/default/preview-unlock.png differ diff --git a/config/omarchy/default/preview.png b/config/omarchy/default/preview.png new file mode 100644 index 0000000..8f5f7e3 Binary files /dev/null and b/config/omarchy/default/preview.png differ diff --git a/config/omarchy/default/rofi.rasi b/config/omarchy/default/rofi.rasi new file mode 100644 index 0000000..632eb2e --- /dev/null +++ b/config/omarchy/default/rofi.rasi @@ -0,0 +1,26 @@ +* { + background: #1a1b26; + foreground: #a9b1d6; + active-background: #9ece6a; + urgent-background: #f7768e; + + normal-foreground: #e0af68; + normal-background: #1a1b26; + + selected-foreground: #c0caf5; + selected-background: #7aa2f7; + + seperator-color: #1a1b26; + border-color: #32344a; + + prompt-color: #7aa2f7; + prompt-background-color: #32344a; + + window-border-size: 1px; + window-border-radius: 8px; + + background-color: @background; + text-color: @foreground; +} + + diff --git a/config/omarchy/default/swayosd.css b/config/omarchy/default/swayosd.css new file mode 100644 index 0000000..9f62747 --- /dev/null +++ b/config/omarchy/default/swayosd.css @@ -0,0 +1,5 @@ +@define-color background-color #1a1b26; +@define-color border-color #a9b1d6; +@define-color label #a9b1d6; +@define-color image #a9b1d6; +@define-color progress #7aa2f7; diff --git a/config/omarchy/default/tmux b/config/omarchy/default/tmux new file mode 100644 index 0000000..28c7776 --- /dev/null +++ b/config/omarchy/default/tmux @@ -0,0 +1,63 @@ +color_bg0="#1a1b26" +color_bg1="#32344a" +color_bg2="#787c99" +color_fg0="#a9b1d6" +color_fg1="#e0af68" + +color_status_fg="#7aa2f7" +color_status_bg="#32344a" + +color_selected_fg="#c0caf5" +color_selected_bg="#7aa2f7" + +color_highlight_fg="#9ece6a" +color_highlight_bg="#1a1b26" + +color_current_fg="#f7768e" +color_current_bg="#1a1b26" + +color_check_fg="#ad8ee6" + +pane_border_fg="#a9b1d6" +pane_border_selected_fg="#9ece6a" + +set -g @prefix_highlight_fg "${color_highlight_fg}" +set -g @prefix_highlight_bg "${color_highlight_bg}" + +# Status bar settings +set -g status-style "bg=${color_bg0},fg=${color_fg0}" +set -g status "on" +set -g status-bg "${color_bg0}" +set -g status-justify "left" +#set -g status-left-length "100" +set -g status-right-length "100" + +# Messages +set -g message-style "fg=${color_selected_fg},bg=${color_selected_bg}" +set -g message-command-style "fg=${color_selected_fg},bg=${color_selected_bg}" + +# Panes +set -g pane-border-style "fg=${pane_border_fg}" +set -g pane-active-border-style "fg=${pane_border_selected_fg}" + +# Windows +set -g window-status-activity-style "fg=${color_fg0},bg=${color_bg0},none" +set -g window-status-separator "" +set -g window-status-style "fg=${color_fg0},bg=${color_bg0},none" + +# Statusline - current window +set -g window-status-current-format "#[fg=${color_current_fg},bg=${color_current_bg}]#I: #[fg=${color_check_fg},bg=${color_current_bg}](✓) #[fg=${color_current_fg},bg=${color_current_bg}]#W " + +# Statusline - other windows +set -g window-status-format "#[fg=${color_highlight_fg},bg=${color_highlight_bg}]#I: #[fg=${color_fg0},bg=${color_highlight_bg}]#W " + +# Statusline - right side +set -g status-right "#[fg=${color_fg1},bg=${color_bg0},nobold,nounderscore,noitalics]%Y-%m-%d %H:%M #[fg=${color_fg0},bg=${color_highlight_fg},nobold,nounderscore,noitalics] #[fg=${color_fg0},bg=${color_bg1}] #(echo '#{pane_current_path}' | rev | cut -d'/' -f-2 | rev) #[fg=${color_fg0},bg=${color_current_fg},nobold,nounderscore,noitalics] #[fg=${color_fg0},bg=${color_bg1}] #S " + +# Modes +set -g clock-mode-colour "${color_status_fg}" +set -g mode-style "fg=${color_highlight_fg} bg=${color_bg1} bold" + +# Statusline - left side (empty) +set -g status-left "" + diff --git a/config/omarchy/default/unlock.png b/config/omarchy/default/unlock.png new file mode 100644 index 0000000..f554441 Binary files /dev/null and b/config/omarchy/default/unlock.png differ diff --git a/config/omarchy/default/vscode.json b/config/omarchy/default/vscode.json new file mode 100644 index 0000000..89af98c --- /dev/null +++ b/config/omarchy/default/vscode.json @@ -0,0 +1,4 @@ +{ + "name": "Tokyo Night", + "extension": "enkia.tokyo-night" +} diff --git a/config/omarchy/default/walker.css b/config/omarchy/default/walker.css new file mode 100644 index 0000000..4f117d7 --- /dev/null +++ b/config/omarchy/default/walker.css @@ -0,0 +1,6 @@ +@define-color selected-text #7aa2f7; +@define-color text #a9b1d6; +@define-color base #1a1b26; +@define-color border #a9b1d6; +@define-color foreground #a9b1d6; +@define-color background #1a1b26; diff --git a/config/omarchy/default/waybar.css b/config/omarchy/default/waybar.css new file mode 100644 index 0000000..e2bc015 --- /dev/null +++ b/config/omarchy/default/waybar.css @@ -0,0 +1,2 @@ +@define-color foreground #a9b1d6; +@define-color background #1a1b26; diff --git a/config/omarchy/theme.name b/config/omarchy/theme.name new file mode 100644 index 0000000..4ad96d5 --- /dev/null +++ b/config/omarchy/theme.name @@ -0,0 +1 @@ +default diff --git a/config/pi/agent/settings.json b/config/pi/agent/settings.json index f46b888..e9348c2 100644 --- a/config/pi/agent/settings.json +++ b/config/pi/agent/settings.json @@ -1,5 +1,5 @@ { - "lastChangelogVersion": "0.80.2", + "lastChangelogVersion": "0.80.10", "theme": "light/dark", "defaultProvider": "opencode-go", "defaultModel": "deepseek-v4-flash", @@ -8,5 +8,12 @@ "compaction": { "enabled": true }, - "enableInstallTelemetry": false + "enableInstallTelemetry": false, + "packages": [ + "npm:pi-lens", + "npm:pi-native-search", + "npm:@tintinweb/pi-subagents", + "npm:context-mode", + "npm:@gotgenes/pi-permission-system" + ] } \ No newline at end of file diff --git a/config/ssh/config b/config/ssh/config index 27b8dc0..5ea5de8 100644 --- a/config/ssh/config +++ b/config/ssh/config @@ -1,27 +1,2 @@ -SetEnv TERM=xterm-256color +Include config.d/* -Host dupont - HostName 172.25.11.30 - user sjb - ForwardAgent yes - RemoteForward /run/user/1000/gnupg/S.gpg-agent /run/user/1000/gnupg/S.gpg-agent.extra - StreamLocalBindUnlink yes - RequestTTY yes - -Host haddock-tmux - User sjb - Hostname 129.100.33.96 - ForwardAgent yes - RemoteForward /run/user/1000/gnupg/S.gpg-agent /run/user/1000/gnupg/S.gpg-agent.extra - StreamLocalBindUnlink yes - RequestTTY yes - RemoteCommand tmux -l new -A - -Host risc-v - User sjb - Hostname 172.25.11.31 - ForwardAgent yes - RemoteForward /run/user/1001/gnupg/S.gpg-agent /run/user/1000/gnupg/S.gpg-agent.extra - StreamLocalBindUnlink yes - RequestTTY yes - \ No newline at end of file diff --git a/config/ssh/config.d/default b/config/ssh/config.d/default new file mode 100644 index 0000000..64727bd --- /dev/null +++ b/config/ssh/config.d/default @@ -0,0 +1,3 @@ +SetEnv TERM=xterm-256color + + diff --git a/installer/00-install-networkmanager.sh b/installer/00-install-networkmanager.sh index a516875..8dec507 100755 --- a/installer/00-install-networkmanager.sh +++ b/installer/00-install-networkmanager.sh @@ -1,6 +1,6 @@ #!/bin/sh -e -pacman -Sy --noconfirm networkmanager +sudo pacman -Sy --noconfirm networkmanager if [[ -x "$(command -v systemctl)" ]]; then sudo systemctl enable --now NetworkManager.service diff --git a/installer/01-install-cachy.sh b/installer/01-install-cachy.sh index 0604b88..684f4bb 100755 --- a/installer/01-install-cachy.sh +++ b/installer/01-install-cachy.sh @@ -2,14 +2,12 @@ # SjB TODO: # - install public keys -sudo pacman -Syu --noconfirm - if [[ "$(uname -m)" == "x86_64" ]]; then if ! pacman-key --list-keys 882DCFE48E2051D48E2562ABF3B607488DB35A47 >/dev/null 2>&1; then sudo pacman-key --recv-key 882DCFE48E2051D48E2562ABF3B607488DB35A47 && sudo pacman-key --lsign-key 882DCFE48E2051D48E2562ABF3B607488DB35A47 fi - if sudo pacman -U --noconfirm https://cdn77.cachyos.org/repo/x86_64/cachyos/archlinux-keyring-20260420-2-any.pkg.tar.zst && + if sudo pacman -U --noconfirm https://cdn77.cachyos.org/repo/x86_64/cachyos/archlinux-keyring-20260707.1-1-any.pkg.tar.zst && sudo pacman -U --noconfirm https://cdn77.cachyos.org/repo/x86_64/cachyos/cachyos-mirrorlist-27-1-any.pkg.tar.zst; then if ! grep -q "^\[cachyos\]" /etc/pacman.conf; then diff --git a/installer/02-install-base.sh b/installer/02-install-base.sh index ef6037b..9a53284 100755 --- a/installer/02-install-base.sh +++ b/installer/02-install-base.sh @@ -17,4 +17,4 @@ if [[ -f "/etc/sdboot-manage.conf" ]]; then sudo sed -i '/^LINUX_OPTIONS=/ s/splash\"/splash quiet\"/' /etc/sdboot-manage.conf fi -/usr/bin/sdboot-manage gen +sudo /usr/bin/sdboot-manage gen diff --git a/installer/03-install-swap.sh b/installer/03-install-swap.sh index cc3837c..e7b6e80 100755 --- a/installer/03-install-swap.sh +++ b/installer/03-install-swap.sh @@ -1,4 +1,4 @@ -#!/bin/sh -e +#!/usr/bin/sudo /bin/sh if [[ $UID != 0 ]]; then echo "need to be root" diff --git a/installer/30-printer.sh b/installer/30-printer.sh index 963f31a..6700239 100755 --- a/installer/30-printer.sh +++ b/installer/30-printer.sh @@ -8,7 +8,6 @@ paru --noconfirm --needed -Sy \ cups \ cups-filters \ cups-pdf \ - cups-browsed \ system-config-printer \ avahi \ nss-mdns \ @@ -37,6 +36,3 @@ if ! grep -q '^CreateRemotePrinters Yes' /etc/cups/cups-browsed.conf; then echo 'CreateRemotePrinters Yes' | sudo tee -a /etc/cups/cups-browsed.conf fi -if [[ -x "$(command -v systemctl)" ]]; then - sudo systemctl enable --now cups-browsed.service -fi diff --git a/installer/btop.sh b/installer/btop.sh deleted file mode 100755 index cb8b7c4..0000000 --- a/installer/btop.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh -e - -${DOTFILES_DIR}/sync-config config/btop -THEME_DIR="${HOME}/.config/omarchy/current/theme" - -# theme link -mkdir -p ~/.config/btop/themes -ln -snf ${THEME_DIR}/btop.theme ${HOME}/.config/btop/themes/current.theme - diff --git a/installer/desktop.sh b/installer/desktop.sh deleted file mode 100755 index 19b3b5c..0000000 --- a/installer/desktop.sh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -e - -if [[ -x "$(command -v systemctl)" ]]; then - systemctl --user enable --now syncthing -fi - -THEME_DIR="${HOME}/.config/omarchy/current/theme" - -${DOTFILES_DIR}/sync-config config/hypr - -${DOTFILES_DIR}/sync-script script/hyprland-activeworkspace -${DOTFILES_DIR}/sync-script script/hyprland-keybindings -${DOTFILES_DIR}/sync-script script/hyprland-fetch-client -${DOTFILES_DIR}/sync-script script/hyprland-focus-client -${DOTFILES_DIR}/sync-script script/rofi-pass - -sjb-script-installer ${SJB_CONF_DIR}/bin/bing-wallpaper - -${DOTFILES_DIR}/sync-script script/bing-wallpaper - -if [[ ! -x "$(command -v gsettings)" ]]; then - gsettings set org.gnome.desktop.interface gtk-enable-primary-paste true -fi -${DOTFILES_DIR}/sync-config config/rofi - -${DOTFILES_DIR}/sync-config config/mako -ln -snf ${THEME_DIR}/current/theme/mako.ini ${HOME}/.config/mako/config - - -${DOTFILES_DIR}/sync-config config/ghostty -ln -snf ${THEME_DIR}/current/theme/ghostty ${HOME}/.config/ghostty/theme - - -${DOTFILES_DIR}/sync-config config/chromium-flags.conf - -xdg-settings set default-web-browser firefox.desktop - -if [[ -x "$(command -v systemctl)" ]]; then - ${DOTFILES_DIR}/sync-config config/systemd - systemctl --user enable mako.service - systemctl --user enable hypridle.service - systemctl --user enable awww-daemon.service - systemctl --user enable gnome-keyring-daemon.service - systemctl --user enable hyprpolkitagent.service - systemctl --user enable wallpaper.timer -fi - - diff --git a/installer/emacs.sh b/installer/emacs.sh deleted file mode 100755 index 5413918..0000000 --- a/installer/emacs.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -e - -${DOTFILES_DIR}/sync-config config/emacs - diff --git a/installer/environment.sh b/installer/environment.sh deleted file mode 100755 index 0b6ec69..0000000 --- a/installer/environment.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -e - -mkdir -p ${HOME}/.config/environment.d - -${DOTFILES_DIR}/sync-config config/environment.d/ -echo "DOTFILES_DIR=${DOTFILES_DIR}" | tee -a ${HOME}/.config/environment.d/dotfiles.conf diff --git a/installer/fish.sh b/installer/fish.sh deleted file mode 100755 index 401b707..0000000 --- a/installer/fish.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v fish)" ]]; then - paru -Sy --needed --noconfirm fish fisher -fi - -${DOTFILES_DIR}/sync-config config/fish - -if [[ -x /usr/bin/fisher ]]; then - fisher install franciscolourenco/done - fisher install kidonng/zoxide.fish - fisher install PatrickF1/fzf.fish -fi - -chsh -s /bin/fish $USER diff --git a/installer/fonts.sh b/installer/fonts.sh deleted file mode 100755 index 481462f..0000000 --- a/installer/fonts.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh -e - -${DOTFILES_DIR}/sync-config config/fontconfig - -rsync -av ${DOTFILES_DIR}/fonts/ ${HOME}/.local/share/fonts/ - -fc-cache diff --git a/installer/git.sh b/installer/git.sh deleted file mode 100755 index f521d80..0000000 --- a/installer/git.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v git)" ]]; then - paru -Sy --needed --noconfirm git -fi - -${DOTFILES_DIR}/sync-config config/git - -GIT_CONFIG="${HOME}/.config/git/local" - -# Set identification from install inputs -if [[ -n "${SJB_USER_NAME//[[:space:]]/}" ]]; then - git config -f ${GIT_CONFIG} user.name "$SJB_USER_NAME" -fi - -if [[ -n "${SJB_USER_EMAIL//[[:space:]]/}" ]]; then - git config -f ${GIT_CONFIG} user.email "$SJB_USER_EMAIL" -fi diff --git a/installer/goose-desktop.sh b/installer/goose-desktop.sh deleted file mode 100755 index 86d8845..0000000 --- a/installer/goose-desktop.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v goose-desktop)" ]]; then - paru -Sy --needed --noconfirm goose-desktop-bin -fi - -${DOTFILES_DIR}/sync-config config/goose diff --git a/installer/goose.sh b/installer/goose.sh deleted file mode 100755 index 289dd98..0000000 --- a/installer/goose.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v goose)" ]]; then - paru -Sy --needed --noconfirm codename-goose-bin -fi - -${DOTFILES_DIR}/sync-config config/goose diff --git a/installer/jj.sh b/installer/jj.sh deleted file mode 100755 index bdaa5cf..0000000 --- a/installer/jj.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v jj)" ]]; then - paru -Sy --needed --noconfirm jj -fi - -${DOTFILES_DIR}/sync-config config/jj - -JJ_CONFIG="${HOME}/.config/jj/conf.d/local.toml" - -mkdir -p "$(dirname ${JJ_CONFIG})" -cp ${DOTFILES_DIR}/installer/templates/local.toml.tmpl ${JJ_CONFIG} - -if [[ -n "${SJB_USER_NAME//[[:space:]]/}" ]]; then - sed -i "s/NAME_PLACEHOLDER/${SJB_USER_NAME}/g" ${JJ_CONFIG} -fi - -if [[ -n "${SJB_USER_EMAIL//[[:space:]]/}" ]]; then - sed -i "s/EMAIL_PLACEHOLDER/${SJB_USER_EMAIL}/g" ${JJ_CONFIG} -fi - diff --git a/installer/nvim.sh b/installer/nvim.sh deleted file mode 100755 index ee8aa92..0000000 --- a/installer/nvim.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v nvim)" ]]; then - paru -Sy --noconfirm neovim harper tree-sitter-cli -fi - -${DOTFILES_DIR}/sync-config config/nvim - -# Set specific app links for current theme -PLUGINS_DIR="${HOME}/.config/nvim/plugin" -THEME_DIR="${HOME}/.config/omarchy/current/theme" - -mkdir -p ${PLUGINS_DIR} -ln -snf ${THEME_DIR}/current/theme/neovim-vimpack.lua ${PLUGINS_DIR}/theme.lua - -uv tool install vectorcode - -npm_config_prefix="$HOME/.local" npm install -g mcp-hub@latest diff --git a/installer/obsidian.sh b/installer/obsidian.sh deleted file mode 100755 index 8ecf833..0000000 --- a/installer/obsidian.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v obsidian)" ]]; then - paru -Sy --needed --noconfirm obsidian -fi - -xdg-mime default obsidian.desktop x-scheme-handler/obsidian -xdg-settings set default-url-scheme-handler obsidian obsidian.desktop diff --git a/installer/opencode.sh b/installer/opencode.sh deleted file mode 100755 index e0d41c7..0000000 --- a/installer/opencode.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v opencode)" ]]; then - paru -Sy --needed --noconfirm opencode-bin -fi - -${DOTFILES_DIR}/sync-config config/opencode -ln -snf ${HOME}/.agents/prompts ${HOME}/.config/opencode/agents diff --git a/installer/pi-agent.sh b/installer/pi-agent.sh deleted file mode 100755 index e794036..0000000 --- a/installer/pi-agent.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v pi)" ]]; then - node -v || paru -Sy --noconfirm nodejs npm - npm install -g --ignore-scripts @earendil-works/pi-coding-agent - npm install -g pi-acp -fi - -mkdir ~/.pi -ln -snf ~/.pi ~/.config/pi -ln -snf ~/.agents/.agents/AGENTS.md ~/.pi/agent/AGENTS.md -${DOTFILES_DIR}/sync-config config/pi - -if [[ -x "$(command -v pass)" ]]; then - pass show agent/pi/agent/auth.json > ~/.pi/agent/auth.json -fi - -pi install npm:pi-lens -pi install npm:@gotgenes/pi-permission-system -pi install npm:pi-native-search -pi install npm:pi-subagents -pi install npm:context-mode - diff --git a/installer/templates/local.toml.tmpl b/installer/templates/local.toml.tmpl deleted file mode 100644 index ae4568e..0000000 --- a/installer/templates/local.toml.tmpl +++ /dev/null @@ -1,4 +0,0 @@ -[user] -name = "NAME_PLACEHOLDER" -email = "EMAIL_PLACEHOLDER" - diff --git a/installer/theme.sh b/installer/theme.sh deleted file mode 100755 index 5485797..0000000 --- a/installer/theme.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -e - -# Use dark mode for QT apps too (like kdenlive) -# Allow icons to match the theme -# Prefer dark mode everything -if [[ ! -x "$(command -v paru)" ]]; then - paru -Sy --needed --noconfirm kvantum-qt5 gnome-themes-extra yaru-icon-theme -fi - -if [[ ! -x "$(command -v gsettings)" ]]; then - gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark" - gsettings set org.gnome.desktop.interface color-scheme "prefer-dark" - gsettings set org.gnome.desktop.interface icon-theme "Yaru-blue" -fi - -${DOTFILES_DIR}/sync-script script/omarchy-theme-bg-next -${DOTFILES_DIR}/sync-script script/omarchy-theme-list -${DOTFILES_DIR}/sync-script script/omarchy-theme-set - -# Set initial theme -THEME_DIR="${HOME}/.config/omarchy/current/theme" -mkdir -p ${THEME_DIR} -omarchy-theme-set "tokyo-night" - diff --git a/installer/tmux.sh b/installer/tmux.sh deleted file mode 100755 index 04eb9ec..0000000 --- a/installer/tmux.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v tmux)" ]]; then - paru -Sy --needed --noconfirm tmux git zoxide fzf -fi - -${DOTFILES_DIR}/sync-config config/tmux -THEME_DIR="${HOME}/.config/omarchy/current/theme" - -ln -snf ${THEME_DIR}/tmux ${HOME}/.config/tmux/theme - -# setup tmux -if [[ ! -d ~/.config/tmux/plugins/tpm ]]; then - git clone https://github.com/tmux-plugins/tpm ${HOME}/.config/tmux/plugins/tpm - tmux run-shell ~/.config/tmux/plugins/tpm/bindings/install_plugins -fi - diff --git a/installer/webapp.sh b/installer/webapp.sh deleted file mode 100755 index fc87b2a..0000000 --- a/installer/webapp.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -e - -if [[ ! -x "$(command -v paru)" ]]; then - paru -Sy --needed --noconfirm chromium -fi - -${DOTFILES_DIR}/sync-script script/sjb-webapp-installer - -sjb-webapp-installer "WhatsApp" https://web.whatsapp.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/whatsapp.png -sjb-webapp-installer "Google Photos" https://photos.google.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-photos.png -sjb-webapp-installer "Google Contacts" https://contacts.google.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-contacts.png -sjb-webapp-installer "Google Messages" https://messages.google.com/web/conversations https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-messages.png -sjb-webapp-installer "ChatGPT" https://chatgpt.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/chatgpt.png -sjb-webapp-installer "YouTube" https://youtube.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/youtube.png -sjb-webapp-installer "GitHub" https://github.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/github-light.png -sjb-webapp-installer "Figma" https://figma.com/ https://www.veryicon.com/download/png/application/app-icon-7/figma-1?s=256 -sjb-webapp-installer "Discord" https://discord.com/channels/@me https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/discord.png -sjb-webapp-installer "Twitch" https://twitch.tv/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/twitch.png -sjb-webapp-installer "Team" https://teams.microsoft.com/v2/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-teams.svg -sjb-webapp-installer "Outlook" https://outlook.office.com/mail/inbox/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-outlook.svg -sjb-webapp-installer "Slack" https://app.slack.com/client/T09M8T3BB1N/C09KZ5N0ZK9 https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/slack.svg -sjb-webapp-installer "Copilot" https://m365.cloud.microsoft https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-copilot.svg -sjb-webapp-installer "Augureal" https://chat.augureai.ca/chat https://www.svgrepo.com/download/375527/ai-platform.svg - diff --git a/mise.toml b/mise.toml index 153a79c..5dab48f 100644 --- a/mise.toml +++ b/mise.toml @@ -1,2 +1,177 @@ -[env] +[vars] +USER_FULLNAME = "Steve Beaulac" +USER_EMAIL = "steve@beaulac.me" DOTFILES_DIR = "{{config_root}}" +THEME_DIR = "~/.config/omarchy/current/theme" + +[settings] +dotfiles.root = "{{config_root}}" +dotfiles.default_mode = "symlink-each" + +[dotfiles] +"~/.config/omarchy/current/theme" = { source = "config/omarchy/default", mode = "copy" } +"~/.config/omarchy/current/background" = { source = "config/omarchy/default/backgrounds/omarchy.png", mode = "symlink" } +"~/.config/omarchy/current/theme.name" = { source = "config/omarchy/theme.name", mode = "copy" } +"~/.config/btop" = "config/btop" +"~/.config/btop/themes/current.theme" = { source = "~/.config/omarchy/current/theme/btop.theme", mode = "symlink" } +"~/.config/emacs" = "config/emacs" +"~/.config/environment.d" = "config/environment.d" +"~/.config/environment.d/dotfiles.conf" = { source = "templates/dofiles.conf.tmpl", template = "tera", mode = "template" } +"~/.config/fish" = "config/fish" # check if we really need the fisher plugins +"~/.config/gdb" = "config/gdb" +"~/.config/ghostty" = "config/ghostty" +"~/.config/ghostty/theme" = { source = "~/.config/omarchy/current/theme/ghostty.conf", mode = "symlink" } +"~/.config/git" = "config/git" +"~/.config/git/local" = { source = "templates/git-local.tmpl", mode = "template", template = "tera" } +"~/.config/fontconfig" = { source = "config/fontconfig", mode = "copy" } +"~/.config/foot" = "config/foot" +"~/.config/hypr" = "config/hypr" +"~/.config/hypr/theme.lua" = { source = "~/.config/omarchy/current/theme/hyprland.lua", mode = "symlink" } +"~/.config/jj" = "config/jj" +"~/.config/jj/conf.d/local.toml" = { source = "templates/git-local.tmpl", mode = "template", template = "tera" } +"~/.config/kitty" = "config/kitty" +"~/.config/mako/config" = { source = "~/.config/omarchy/current/theme/mako.ini", mode = "symlink" } +"~/.config/mini.nvim" = "config/mini.nvim" +"~/.config/mise/config.toml" = { source = "config/mise/config.toml", mode = "symlink" } +"~/.config/opencode" = "config/opencode" +"~/.agents" = { source = "config/agents", mode = "symlink-each" } +"~/.config/opencode/agents" = { source = "config/agents/prompts", mode = "symlink" } +"~/.pi" = "config/pi" +"~/.pi/agent/AGENTS.md" = { source = "config/agents/AGENTS.md", mode = "symlink" } +"~/.config/rofi" = "config/rofi" +"~/.config/rofi/theme.rasi" = { source = "~/.config/omarchy/current/theme/rofi.rasi", mode = "symlink" } +"~/.ssh" = "config/ssh" +"~/.config/systemd" = { source="config/systemd", mode = "copy" } +"~/.config/tmux" = "config/tmux" +"~/.config/tmux/theme" = { source = "~/.config/omarchy/current/theme/tmux", mode = "symlink" } +"~/.config/uwsm" = "config/uwsm" +"~/.config/worktrunck" = "config/worktrunk" +"~/.config/chromium-flags.conf" = { source = "config/chromium-flags.conf", mode = "symlink" } +"~/.profile" = { source = "config/profile", mode = "symlink" } + +"~/.local/share/fonts/" = { source = "fonts", mode = "copy" } + +# scripts. +"~/.local/bin/hyprland-activeworkspace" = { source = "script/hyprland-activeworkspace", mode = "symlink" } +"~/.local/bin/hyprland-keybindings" = { source = "script/hyprland-keybindings", mode = "symlink" } +"~/.local/bin/hyprland-fetch-client" = { source = "script/hyprland-fetch-client", mode = "symlink" } +"~/.local/bin/hyprland-focus-client" = { source = "script/hyprland-focus-client", mode = "symlink" } + +"~/.local/bin/active-workspace" = { source = "script/active-workspace", mode = "symlink" } +"~/.local/bin/avr-flash" = { source = "script/avr-flash", mode = "symlink" } +"~/.local/bin/dfu-flash" = { source = "script/dfu-flash", mode = "symlink" } +"~/.local/bin/git-bare-clone" = { source = "script/git-bare-clone", mode = "symlink" } +"~/.local/bin/git-churn" = { source = "script/git-churn", mode = "symlink" } +"~/.local/bin/hyprland-tmux-session" = { source = "script/hyprland-tmux-session", mode = "symlink" } +"~/.local/bin/hyprland-toggle-monitor" = { source = "script/hyprland-toggle-monitor", mode = "symlink" } +"~/.local/bin/ci" = { source = "script/ci", mode = "symlink" } +"~/.local/bin/rofi-pass" = { source = "script/rofi-pass", mode = "symlink" } +"~/.local/bin/sharehome" = { source = "script/sharehome", mode = "symlink" } +"~/.local/bin/sjb-orgmode-installer" = { source = "script/sjb-orgmode-installer", mode = "symlink" } +"~/.local/bin/sjb-script-installer" = { source = "script/sjb-script-installer", mode = "symlink" } +"~/.local/bin/sjb-update-config" = { source = "script/sjb-update-config", mode = "symlink" } +"~/.local/bin/sjb-webapp-installer" = { source = "script/sjb-webapp-installer", mode = "symlink" } +"~/.local/bin/sysinfo" = { source = "script/sysinfo", mode = "symlink" } +"~/.local/bin/s" = { source = "script/s", mode = "symlink" } +"~/.local/bin/t" = { source = "script/t", mode = "symlink" } +"~/.local/bin/n" = { source = "script/n", mode = "symlink" } +"~/.local/bin/ykswap" = { source = "script/ykswap", mode = "symlink" } + +"~/.local/bin/bing-wallpaper" = { source = "script/bing-wallpaper", mode = "symlink" } + +"~/.local/bin/omarchy-cmd-missing" = { source = "script/omarchy-cmd-missing", mode = "symlink" } +"~/.local/bin/omarchy-cmd-present" = { source = "script/omarchy-cmd-present", mode = "symlink" } +"~/.local/bin/omarchy-hook" = { source = "script/omarchy-hook", mode = "symlink" } +"~/.local/bin/omarchy-restart-btop" = { source = "script/omarchy-restart-btop", mode = "symlink" } +"~/.local/bin/omarchy-restart-hyprctl" = { source = "script/omarchy-restart-hyprctl", mode = "symlink" } +"~/.local/bin/omarchy-restart-hypridle" = { source = "script/omarchy-restart-hypridle", mode = "symlink" } +"~/.local/bin/omarchy-restart-mako" = { source = "script/omarchy-restart-mako", mode = "symlink" } +"~/.local/bin/omarchy-restart-tmux" = { source = "script/omarchy-restart-tmux", mode = "symlink" } +"~/.local/bin/omarchy-theme-bg-next" = { source = "script/omarchy-theme-bg-next", mode = "symlink" } +"~/.local/bin/omarchy-theme-bg-set" = { source = "script/omarchy-theme-bg-set", mode = "symlink" } +"~/.local/bin/omarchy-theme-colors-from-alacritty" = { source = "script/omarchy-theme-colors-from-alacritty", mode = "symlink" } +"~/.local/bin/omarchy-theme-current" = { source = "script/omarchy-theme-current", mode = "symlink" } +"~/.local/bin/omarchy-theme-install" = { source = "script/omarchy-theme-install", mode = "symlink" } +"~/.local/bin/omarchy-theme-list" = { source = "script/omarchy-theme-list", mode = "symlink" } +"~/.local/bin/omarchy-theme-refresh" = { source = "script/omarchy-theme-refresh", mode = "symlink" } +"~/.local/bin/omarchy-theme-remove" = { source = "script/omarchy-theme-remove", mode = "symlink" } +"~/.local/bin/omarchy-theme-set" = { source = "script/omarchy-theme-set", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-browser" = { source = "script/omarchy-theme-set-browser", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-foot" = { source = "script/omarchy-theme-set-foot", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-gnome" = { source = "script/omarchy-theme-set-gnome", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-keyboard" = { source = "script/omarchy-theme-set-keyboard", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-keyboard-asus-rog" = { source = "script/omarchy-theme-set-keyboard-asus-rog", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-keyboard-f16" = { source = "script/omarchy-theme-set-keyboard-f16", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-obsidian" = { source = "script/omarchy-theme-set-obsidian", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-templates" = { source = "script/omarchy-theme-set-templates", mode = "symlink" } +"~/.local/bin/omarchy-theme-set-vscode" = { source = "script/omarchy-theme-set-vscode", mode = "symlink" } +"~/.local/bin/omarchy-theme-update" = { source = "script/omarchy-theme-update", mode = "symlink" } + +[bootstrap.user] +login_shell = "/usr/bin/fish" + +[bootstrap.packages] +"pacman:zoxide" = "latest" +"pacman:git" = "latest" +"pacman:tmux" = "latest" +"pacman:fzf" = "latest" +"pacman:neovim" = "latest" +"pacman:harper" = "latest" +"pacman:tree-sitter-cli" = "latest" + +[tasks.shells] +description = "Script to setup some cli environment" +run = [ + 'fish -c "fisher install franciscolourenco/done"', + 'test -d ~/.config/tmux/plugins/tpm || git clone https://github.com/tmux-plugins/tpm ~/.config/tmux/plugins/tpm', + 'tmux run-shell ~/.config/tmux/plugins/tpm/bindings/install_plugins', + 'fc-cache', +] + +[tasks.desktop] +description = "setup gui" +run = [ + 'xdg-settings set default-web-browser firefox.desktop', + 'gsettings set org.gnome.desktop.interface gtk-enable-primary-paste true', + 'systemctl --user enable --now syncthing', + 'systemctl --user enable mako.service', + 'systemctl --user enable hypridle.service', + 'systemctl --user enable awww-daemon.service', + 'systemctl --user enable gnome-keyring-daemon.service', + 'systemctl --user enable hyprpolkitagent.service', + 'systemctl --user enable wallpaper.timer', + 'xdg-mime default obsidian.desktop x-scheme-handler/obsidian', + 'xdg-settings set default-url-scheme-handler obsidian obsidian.desktop' +] + +[tasks.theme] +description = 'configure theme' +run = [ + 'gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark"', + 'gsettings set org.gnome.desktop.interface color-scheme "prefer-dark"', + 'gsettings set org.gnome.desktop.interface icon-theme "Yaru-blue"', + 'omarchy-theme-set "tokyo-night"' +] + +[tasks.webapps] +description = 'create all web application' +run = [ + 'sjb-webapp-installer "WhatsApp" https://web.whatsapp.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/whatsapp.png', + 'sjb-webapp-installer "Google Photos" https://photos.google.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-photos.png', + 'sjb-webapp-installer "Google Contacts" https://contacts.google.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-contacts.png', + 'sjb-webapp-installer "Google Messages" https://messages.google.com/web/conversations https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/google-messages.png', + 'sjb-webapp-installer "ChatGPT" https://chatgpt.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/chatgpt.png', + 'sjb-webapp-installer "YouTube" https://youtube.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/youtube.png', + 'sjb-webapp-installer "GitHub" https://github.com/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/github-light.png', + 'sjb-webapp-installer "Figma" https://figma.com/ https://www.veryicon.com/download/png/application/app-icon-7/figma-1?s=256', + 'sjb-webapp-installer "Discord" https://discord.com/channels/@me https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/discord.png', + 'sjb-webapp-installer "Twitch" https://twitch.tv/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/twitch.png', + 'sjb-webapp-installer "Team" https://teams.microsoft.com/v2/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-teams.svg', + 'sjb-webapp-installer "Outlook" https://outlook.office.com/mail/inbox/ https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-outlook.svg', + 'sjb-webapp-installer "Slack" https://app.slack.com/client/T09M8T3BB1N/C09KZ5N0ZK9 https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/slack.svg', + 'sjb-webapp-installer "Copilot" https://m365.cloud.microsoft https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/microsoft-copilot.svg', + 'sjb-webapp-installer "Augureal" https://chat.augureai.ca/chat https://www.svgrepo.com/download/375527/ai-platform.svg', +] + +[tasks.bootstrap] +depends = ['shells', 'desktop', 'theme', 'webapps'] diff --git a/packages/sjb-base.packages b/packages/sjb-base.packages index ee64403..63f4a88 100644 --- a/packages/sjb-base.packages +++ b/packages/sjb-base.packages @@ -94,7 +94,7 @@ pass-otp rclone gopass weechat -weechat-matrix-rs-git +#weechat-matrix-rs-git yt-dlp resvg diff --git a/packages/sjb-desktop.packages b/packages/sjb-desktop.packages index e458bbe..a7bedd9 100644 --- a/packages/sjb-desktop.packages +++ b/packages/sjb-desktop.packages @@ -98,6 +98,7 @@ xdg-desktop-portal-hyprland xdg-user-dirs xorg-xwayland xournalpp +yaru-icon-theme zathura zathura-pdf-poppler zed diff --git a/script/v b/script/n similarity index 100% rename from script/v rename to script/n diff --git a/script/sharehome.sh b/script/sharehome.sh deleted file mode 100755 index 8d53915..0000000 --- a/script/sharehome.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -/usr/bin/rclone serve sftp $HOME --addr :2022 \ No newline at end of file diff --git a/sync-config b/sync-config deleted file mode 100755 index dbfe7d7..0000000 --- a/sync-config +++ /dev/null @@ -1,271 +0,0 @@ -#!/usr/bin/env bash -set -euo pipefail - -script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) -src_dir="$script_dir/config" -dest_dir="${HOME}/.config" - - -dry_run=false -target_path="" - -usage() { - cat <<'EOF' -Usage: sync-config.sh [--dry-run] [path] - -path can be: - config (full config) - config/tmux (specific folder) - config/tmux/config (specific file) - .config (full config) - .config/tmux (specific folder) - .config/tmux/config (specific file) - tmux (folder under .config) - tmux/config (file under .config) -EOF -} - -for arg in "$@"; do - case "$arg" in - --dry-run) - dry_run=true - ;; - -h|--help) - usage - exit 0 - ;; - *) - if [[ -z "$target_path" ]]; then - target_path="$arg" - else - echo "Error: too many arguments." >&2 - usage >&2 - exit 1 - fi - ;; - esac -done - -hash_cmd="sha256sum" -if ! command -v "$hash_cmd" >/dev/null 2>&1; then - echo "Error: sha256sum not found. Install coreutils or adjust hash_cmd." >&2 - exit 1 -fi - -file_hash() { - "$hash_cmd" "$1" | awk '{print $1}' -} - -copy_file() { - local src="$1" - local dst="$2" - if $dry_run; then - echo "copy: $src -> $dst" - else - mkdir -p "$(dirname "$dst")" - cp -a "$src" "$dst" - echo "copied: $dst" - fi -} - -delete_file() { - local dst="$1" - if $dry_run; then - echo "delete: $dst" - else - rm -f "$dst" - echo "deleted: $dst" - fi -} - -delete_dir() { - local dst="$1" - if $dry_run; then - echo "delete dir: $dst" - else - rm -rf "$dst" - echo "deleted dir: $dst" - fi -} - -if [[ ! -d "$src_dir" ]]; then - echo "Error: source config directory not found: $src_dir" >&2 - exit 1 -fi - -mkdir -p "$dest_dir" - -target_rel="$target_path" -if [[ -n "$target_rel" ]]; then - if [[ "$target_rel" == "config" || "$target_rel" == ".config" ]]; then - target_rel="" - elif [[ "$target_rel" == config/* ]]; then - target_rel=${target_rel#config/} - elif [[ "$target_rel" == .config/* ]]; then - target_rel=${target_rel#.config/} - fi - target_rel=${target_rel#./} - if [[ "$target_rel" == "." ]]; then - target_rel="" - fi - if [[ "$target_rel" == /* ]]; then - echo "Error: absolute paths are not supported: $target_path" >&2 - exit 1 - fi -fi - -base_path="$src_dir" -if [[ -n "$target_rel" ]]; then - base_path="$src_dir/$target_rel" -fi - -if [[ ! -e "$base_path" ]]; then - echo "Error: path not found in source: $base_path" >&2 - exit 1 -fi - -check_delete_marker() { - local rel_path="$1" - - # Check centralized .delete folder: config/.delete/path/to/dir_or_file - if [[ -f "$src_dir/.delete/$rel_path" ]] || [[ -d "$src_dir/.delete/$rel_path" ]]; then - return 0 - fi - - # Check inline .delete marker: config/path/to/.delete/dir_or_file - local parent_path="$src_dir/$rel_path" - local parent_dir=$(dirname "$parent_path") - local base_name=$(basename "$parent_path") - if [[ -f "$parent_dir/.delete/$base_name" ]] || [[ -d "$parent_dir/.delete/$base_name" ]]; then - return 0 - fi - - return 1 -} - -# Check if a path is a .delete directory or inside one (should be skipped during traversal) -is_in_delete_dir() { - local rel_path="$1" - # Check if the path itself is a .delete directory or any parent is .delete - local current="$rel_path" - while [[ "$current" != "." && "$current" != "/" && -n "$current" ]]; do - local base - base=$(basename "$current") - if [[ "$base" == ".delete" ]]; then - return 0 - fi - current=$(dirname "$current") - done - return 1 -} - -sync_file() { - local src_path="$1" - local rel_path=${src_path#"$src_dir"/} - local dst_path="$dest_dir/$rel_path" - - # Check if there's a corresponding .delete marker for this file - if check_delete_marker "$rel_path"; then - if [[ -f "$dst_path" ]]; then - delete_file "$dst_path" - deleted_files+=("$dst_path") - fi - return - fi - - if [[ ! -f "$dst_path" ]]; then - copy_file "$src_path" "$dst_path" - return - fi - - local src_hash - local dst_hash - src_hash=$(file_hash "$src_path") - dst_hash=$(file_hash "$dst_path") - - if [[ "$src_hash" != "$dst_hash" ]]; then - copy_file "$src_path" "$dst_path" - fi -} - -shopt -s globstar nullglob dotglob -if [[ -f "$base_path" ]]; then - sync_file "$base_path" -elif [[ -d "$base_path" ]]; then - for src_path in "$base_path"/**; do - rel_path=${src_path#"$src_dir"/} - - if [[ "$rel_path" == ".git" || "$rel_path" == .git/* ]]; then - continue - fi - - # Check if this is a .delete directory - process its contents to delete in destination - if [[ -d "$src_path" && "$(basename "$rel_path")" == ".delete" ]]; then - # Get the parent directory of the .delete folder - parent_rel_path=$(dirname "$rel_path") - # Process all files in this .delete directory to delete corresponding files in destination - for delete_marker in "$src_path"/**; do - if [[ -e "$delete_marker" ]]; then - # Get the basename of the marker (file/dir to delete) - marker_basename=$(basename "$delete_marker") - # Construct the target path in the parent directory - target_rel_path="$parent_rel_path/$marker_basename" - target_dst_path="$dest_dir/$target_rel_path" - - if [[ -d "$delete_marker" ]]; then - if [[ -d "$target_dst_path" ]]; then - delete_dir "$target_dst_path" - fi - elif [[ -f "$delete_marker" ]]; then - if [[ -f "$target_dst_path" ]]; then - delete_file "$target_dst_path" - fi - fi - fi - done - # Delete the .delete folder in destination if it exists - delete_dst_path="$dest_dir/$rel_path" - if [[ -d "$delete_dst_path" ]]; then - delete_dir "$delete_dst_path" - fi - continue - fi - - # Skip anything inside a .delete directory - don't process or copy - if is_in_delete_dir "$rel_path"; then - continue - fi - - dst_path="$dest_dir/$rel_path" - - if [[ -d "$src_path" ]]; then - # Check if there's a .delete marker for this directory - if check_delete_marker "$rel_path"; then - if [[ -d "$dst_path" ]]; then - delete_dir "$dst_path" - deleted_dirs+=("$dst_path") - fi - continue - fi - - if ! $dry_run; then - mkdir -p "$dst_path" - else - echo "mkdir: $dst_path" - fi - continue - fi - - if [[ ! -f "$src_path" ]]; then - continue - fi - - sync_file "$src_path" - done -fi - -if $dry_run; then - echo "Dry run complete. Re-run without --dry-run to apply changes." -else - echo "Sync complete. Updated files where content differed." -fi diff --git a/sync-script b/sync-script deleted file mode 100755 index 685f716..0000000 --- a/sync-script +++ /dev/null @@ -1,156 +0,0 @@ -#!/usr/bin/env bash -set -euo pipefail - -script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) -src_dir="$script_dir/script" -dest_dir="${HOME}/.local/bin" - -dry_run=false -target_path="" - -usage() { - cat <<'EOF' -Usage: sync-script.sh [--dry-run] [path] - -path can be: - script (all scripts) - script/foo (specific file or folder) - .local/bin (all scripts) - .local/bin/foo (specific file or folder) - foo (file or folder under script) -EOF -} - -for arg in "$@"; do - case "$arg" in - --dry-run) - dry_run=true - ;; - -h|--help) - usage - exit 0 - ;; - *) - if [[ -z "$target_path" ]]; then - target_path="$arg" - else - echo "Error: too many arguments." >&2 - usage >&2 - exit 1 - fi - ;; - esac -done - -hash_cmd="sha256sum" -if ! command -v "$hash_cmd" >/dev/null 2>&1; then - echo "Error: sha256sum not found. Install coreutils or adjust hash_cmd." >&2 - exit 1 -fi - -file_hash() { - "$hash_cmd" "$1" | awk '{print $1}' -} - -copy_file() { - local src="$1" - local dst="$2" - if $dry_run; then - echo "copy: $src -> $dst" - else - mkdir -p "$(dirname "$dst")" - cp -a "$src" "$dst" - fi -} - -if [[ ! -d "$src_dir" ]]; then - echo "Error: source script directory not found: $src_dir" >&2 - exit 1 -fi - -mkdir -p "$dest_dir" - -target_rel="$target_path" -if [[ -n "$target_rel" ]]; then - if [[ "$target_rel" == "script" || "$target_rel" == ".local/bin" ]]; then - target_rel="" - elif [[ "$target_rel" == script/* ]]; then - target_rel=${target_rel#script/} - elif [[ "$target_rel" == .local/bin/* ]]; then - target_rel=${target_rel#.local/bin/} - fi - target_rel=${target_rel#./} - if [[ "$target_rel" == "." ]]; then - target_rel="" - fi - if [[ "$target_rel" == /* ]]; then - echo "Error: absolute paths are not supported: $target_path" >&2 - exit 1 - fi -fi - -base_path="$src_dir" -if [[ -n "$target_rel" ]]; then - base_path="$src_dir/$target_rel" -fi - -if [[ ! -e "$base_path" ]]; then - echo "Error: path not found in source: $base_path" >&2 - exit 1 -fi - -sync_file() { - local src_path="$1" - local rel_path=${src_path#"$src_dir"/} - local dst_path="$dest_dir/$rel_path" - - if [[ ! -f "$dst_path" ]]; then - copy_file "$src_path" "$dst_path" - return - fi - - local src_hash - local dst_hash - src_hash=$(file_hash "$src_path") - dst_hash=$(file_hash "$dst_path") - - if [[ "$src_hash" != "$dst_hash" ]]; then - copy_file "$src_path" "$dst_path" - fi -} - -shopt -s globstar nullglob dotglob -if [[ -f "$base_path" ]]; then - sync_file "$base_path" -elif [[ -d "$base_path" ]]; then - for src_path in "$base_path"/**; do - rel_path=${src_path#"$src_dir"/} - - if [[ "$rel_path" == ".git" || "$rel_path" == .git/* ]]; then - continue - fi - - dst_path="$dest_dir/$rel_path" - - if [[ -d "$src_path" ]]; then - if ! $dry_run; then - mkdir -p "$dst_path" - else - echo "mkdir: $dst_path" - fi - continue - fi - - if [[ ! -f "$src_path" ]]; then - continue - fi - - sync_file "$src_path" - done -fi - -if $dry_run; then - echo "Dry run complete. Re-run without --dry-run to apply changes." -else - echo "Sync complete. Updated files where content differed." -fi diff --git a/templates/dofiles.conf.tmpl b/templates/dofiles.conf.tmpl new file mode 100644 index 0000000..0ac7fde --- /dev/null +++ b/templates/dofiles.conf.tmpl @@ -0,0 +1 @@ +DOTFILES_DIR={{ vars.DOTFILES_DIR }} diff --git a/templates/git-local.tmpl b/templates/git-local.tmpl new file mode 100644 index 0000000..8d13303 --- /dev/null +++ b/templates/git-local.tmpl @@ -0,0 +1,3 @@ +[user] +name = {{ vars.USER_FULLNAME }} +email = {{ vars.USER_EMAIL }}