From cc3640996f444fba471241428cf2a6ca7c90006f Mon Sep 17 00:00:00 2001 From: Christoffer Martinsson Date: Sat, 16 Aug 2025 17:10:36 +0200 Subject: [PATCH] Updated scripts --- config/hypr/hyprland.conf | 21 +- config/hypr/hyprland_STEAMBOX.conf | 9 +- config/nvim/init.lua | 682 ++++-------------- config/nvim/lua/.luarc.json | 3 - config/nvim/lua/custom/chadrc.lua | 6 - config/nvim/lua/custom/configs/lspconfig.lua | 27 - config/nvim/lua/custom/configs/null-ls.lua | 16 - config/nvim/lua/custom/configs/overrides.lua | 68 -- config/nvim/lua/custom/init.lua | 1 - config/nvim/lua/custom/mappings.lua | 30 - config/nvim/lua/custom/plugins.lua | 161 ----- config/nvim/lua/user/.luarc.json | 3 - config/nvim/lua/user/.stylua.toml | 7 - config/nvim/lua/user/init.lua | 98 --- config/nvim/lua/user/lsp/config/clangd.lua | 5 - config/nvim/lua/user/lsp/config/lua_ls.lua | 22 - config/nvim/lua/user/mappings.lua | 46 -- config/nvim/lua/user/options.lua | 30 - config/nvim/lua/user/plugins/astrotheme.lua | 27 - config/nvim/lua/user/plugins/cmp.lua | 20 - config/nvim/lua/user/plugins/community.lua | 9 - config/nvim/lua/user/plugins/core.lua | 82 --- config/nvim/lua/user/plugins/lspkind.lua | 27 - config/nvim/lua/user/plugins/mason.lua | 50 -- config/nvim/lua/user/plugins/null-ls.lua | 17 - config/nvim/lua/user/plugins/treesitter.lua | 22 - config/nvim/lua/user/plugins/user.lua | 54 -- config/qt5ct/qt5ct.conf | 8 +- config/qt6ct/qt6ct.conf | 8 +- config/walker/themes/cmtec.css | 2 +- config/walker/themes/cmtec.toml | 19 +- nightly_cm.nvim/LICENSE.txt | 21 - nightly_cm.nvim/README.md | 0 .../lightline/colorscheme/nightly.vim | 2 - nightly_cm.nvim/colors/nightly_cm.lua | 1 - nightly_cm.nvim/lua/.luarc.json | 3 - .../lua/lualine/themes/nightly_cm.lua | 39 - nightly_cm.nvim/lua/nightly_cm/config.lua | 26 - nightly_cm.nvim/lua/nightly_cm/init.lua | 22 - nightly_cm.nvim/lua/nightly_cm/palette.lua | 32 - nightly_cm.nvim/lua/nightly_cm/theme.lua | 399 ---------- update_arch.sh | 52 +- 42 files changed, 214 insertions(+), 1963 deletions(-) delete mode 100644 config/nvim/lua/.luarc.json delete mode 100644 config/nvim/lua/custom/chadrc.lua delete mode 100644 config/nvim/lua/custom/configs/lspconfig.lua delete mode 100644 config/nvim/lua/custom/configs/null-ls.lua delete mode 100644 config/nvim/lua/custom/configs/overrides.lua delete mode 100644 config/nvim/lua/custom/init.lua delete mode 100644 config/nvim/lua/custom/mappings.lua delete mode 100644 config/nvim/lua/custom/plugins.lua delete mode 100644 config/nvim/lua/user/.luarc.json delete mode 100644 config/nvim/lua/user/.stylua.toml delete mode 100644 config/nvim/lua/user/init.lua delete mode 100644 config/nvim/lua/user/lsp/config/clangd.lua delete mode 100644 config/nvim/lua/user/lsp/config/lua_ls.lua delete mode 100644 config/nvim/lua/user/mappings.lua delete mode 100644 config/nvim/lua/user/options.lua delete mode 100644 config/nvim/lua/user/plugins/astrotheme.lua delete mode 100644 config/nvim/lua/user/plugins/cmp.lua delete mode 100644 config/nvim/lua/user/plugins/community.lua delete mode 100644 config/nvim/lua/user/plugins/core.lua delete mode 100644 config/nvim/lua/user/plugins/lspkind.lua delete mode 100644 config/nvim/lua/user/plugins/mason.lua delete mode 100644 config/nvim/lua/user/plugins/null-ls.lua delete mode 100644 config/nvim/lua/user/plugins/treesitter.lua delete mode 100644 config/nvim/lua/user/plugins/user.lua delete mode 100644 nightly_cm.nvim/LICENSE.txt delete mode 100644 nightly_cm.nvim/README.md delete mode 100644 nightly_cm.nvim/autoload/lightline/colorscheme/nightly.vim delete mode 100644 nightly_cm.nvim/colors/nightly_cm.lua delete mode 100644 nightly_cm.nvim/lua/.luarc.json delete mode 100644 nightly_cm.nvim/lua/lualine/themes/nightly_cm.lua delete mode 100644 nightly_cm.nvim/lua/nightly_cm/config.lua delete mode 100644 nightly_cm.nvim/lua/nightly_cm/init.lua delete mode 100644 nightly_cm.nvim/lua/nightly_cm/palette.lua delete mode 100644 nightly_cm.nvim/lua/nightly_cm/theme.lua diff --git a/config/hypr/hyprland.conf b/config/hypr/hyprland.conf index d20d325..c630059 100644 --- a/config/hypr/hyprland.conf +++ b/config/hypr/hyprland.conf @@ -27,6 +27,8 @@ env = XCURSOR_SIZE,24 env = HYPRCURSOR_SIZE,24 env = QT_QPA_PLATFORM,wayland env = QT_QPA_PLATFORMTHEME,qt5ct # for Qt apps +# env = GTK_THEME,Adwaita:dark +# env = QT_STYLE_OVERRIDE,adwaita-dark ##################### ### LOOK AND FEEL ### @@ -99,11 +101,6 @@ dwindle { permanent_direction_override = true } -master { - new_status = slave - mfact = 0.5 -} - misc { force_default_wallpaper = -1 # Set to 0 or 1 to disable the anime mascot wallpapers disable_hyprland_logo = true # If true disables the random hyprland logo / anime girl background. :( @@ -235,12 +232,12 @@ windowrulev2 = rounding 0, floating:0, onworkspace:f[1] # Terminal scratchpad windowrulev2 = float, onworkspace:special:scratchpad -windowrulev2 = size 80% 80%, onworkspace:special:scratchpad +windowrulev2 = size 50% 50%, onworkspace:special:scratchpad workspace = special:scratchpad, on-created-empty:$terminal # Web scratchpad windowrulev2 = float, onworkspace:special:web -windowrulev2 = size 80% 80%, initialTitle:^(.*Brave.*)$ +windowrulev2 = size 50% 50%, initialTitle:^(.*Brave.*)$ windowrulev2 = center, initialTitle:^(.*Brave.*)$ workspace = special:web, on-created-empty:$browser windowrulev2 = size 450 253, initialTitle:^(Picture in picture)$ @@ -251,17 +248,17 @@ windowrulev2 = workspace e+0, initialTitle:^(Picture in picture)$ # Btop windowrulev2 = float, onworkspace:special:btop -windowrulev2 = size 80% 80%, onworkspace:special:btop +windowrulev2 = size 50% 50%, onworkspace:special:btop workspace = special:btop, on-created-empty:$terminal -e btop # Ranger windowrulev2 = float, onworkspace:special:ranger -windowrulev2 = size 80% 80%, onworkspace:special:ranger +windowrulev2 = size 50% 50%, onworkspace:special:ranger workspace = special:ranger, on-created-empty:$terminal -e ranger # NMtui windowrulev2 = float, onworkspace:special:nm -windowrulev2 = size 80% 80%, onworkspace:special:nm +windowrulev2 = size 50% 50%, onworkspace:special:nm workspace = special:nm, on-created-empty:nm-connection-editor # Timer @@ -273,7 +270,7 @@ workspace = special:timer, on-created-empty:io.github.efogdev.mpris-timer windowrulev2 = size 450 253, initialTitle:^(Discord Popout)$ windowrulev2 = float, onworkspace:special:discord windowrulev2 = float, initialTitle:^(.*Discord.*)$ -windowrulev2 = size 80% 80%, initialTitle:^(.*Discord.*)$ +windowrulev2 = size 50% 50%, initialTitle:^(.*Discord.*)$ workspace = special:discord, on-created-empty:flatpak run com.discordapp.Discord windowrulev2 = workspace special:discord, initialTitle:^(.*Discord.*)$ windowrulev2 = opacity 1.0 0.9, initialTitle:^(Discord Popout)$ @@ -287,7 +284,7 @@ windowrulev2 = dimaround, title:^(Volume Control)$ windowrulev2 = float, title:^(Helvum - Pipewire Patchbay)$ windowrulev2 = dimaround, title:^(Helvum - Pipewire Patchbay)$ windowrulev2 = float, onworkspace:special:mixer -windowrulev2 = size 30% 50%, onworkspace:special:mixer +windowrulev2 = size 50% 50%, onworkspace:special:mixer workspace = special:mixer, on-created-empty:pavucontrol # # Moonlight diff --git a/config/hypr/hyprland_STEAMBOX.conf b/config/hypr/hyprland_STEAMBOX.conf index 58fe590..1d2e83a 100644 --- a/config/hypr/hyprland_STEAMBOX.conf +++ b/config/hypr/hyprland_STEAMBOX.conf @@ -6,8 +6,13 @@ exec-once = cameractrls -d /dev/video0 -c auto_exposure=manual_mode,white_balanc exec-once = ~/Games/opentrack/build/install/bin/opentrack -platform xcb # Environmental variables -env = GBM_BACKEND, nvidia-drm -env = __GLX_VENDOR_LIBRARY_NAME, nvidia +env = LIBVA_DRIVER_NAME,nvidia +env = XDG_SESSION_TYPE,wayland +env = GBM_BACKEND,nvidia-drm +env = __GLX_VENDOR_LIBRARY_NAME,nvidia +env = WLR_NO_HARDWARE_CURSORS,1 +env = NVIDIA_WAYLAND_USE_DISPLAYLINK,1 + env = DXVK_HUD,fps,compiler env = DXVK_CONFIG,dxgi.maxDeviceMemory=6144;cachedDynamicResources=a; env = DXVK_ENABLE_NVAPI,1 diff --git a/config/nvim/init.lua b/config/nvim/init.lua index a00c88e..6f06fa1 100644 --- a/config/nvim/init.lua +++ b/config/nvim/init.lua @@ -1,563 +1,167 @@ ------------------------------------------------------------------- -- Settings ------------------------------------------------------------------- -vim.g.mapleader = " " -vim.g.maplocalleader = " " -vim.o.hlsearch = false -vim.wo.number = true -vim.o.mouse = "a" -vim.o.breakindent = true -vim.o.undofile = true -vim.o.ignorecase = true -vim.o.smartcase = true -vim.wo.signcolumn = "yes" -vim.o.termguicolors = true -vim.o.shiftwidth = 4 -vim.o.smarttab = true -vim.o.tabstop = 4 -vim.o.expandtab = true -vim.o.softtabstop = 4 -vim.o.inccommand = "split" -vim.o.cursorline = true -vim.o.showmatch = true -vim.o.updatetime = 250 -vim.o.timeoutlen = 300 -vim.o.pumheight = 10 -vim.o.relativenumber = true -vim.o.scrolloff = 8 -vim.o.showmode = false -vim.o.showtabline = 0 -vim.o.wrap = true -vim.o.foldmethod = "expr" -vim.o.foldexpr = "nvim_treesitter#foldexpr()" -vim.o.foldlevelstart = 99 -vim.o.autoread = true - -vim.schedule(function() - vim.o.clipboard = "unnamedplus" -end) +vim.opt.winborder = "rounded" +vim.opt.hlsearch = false +vim.opt.tabstop = 4 +vim.opt.cursorcolumn = false +vim.opt.ignorecase = true +vim.opt.shiftwidth = 4 +vim.opt.smartindent = true +vim.opt.number = true +vim.opt.relativenumber = true +vim.opt.termguicolors = true +vim.opt.undofile = true +vim.opt.signcolumn = "yes" +vim.g.netrw_banner = 0 -- gets rid of the annoying banner for netrw +vim.g.netrw_browse_split = 4 -- open in prior window +vim.g.netrw_altv = 1 -- change from left splitting to right splitting +vim.g.netrw_liststyle = 3 -- tree style view in netrw ------------------------------------------------------------------- -- Autocommands ------------------------------------------------------------------- --- Autoset current working directory based on closest git repo -vim.api.nvim_create_autocmd("BufEnter", { - callback = function() - local git_dir = vim.fn.finddir(".git", ".;") - if git_dir ~= "" then - local git_root = vim.fn.fnamemodify(git_dir, ":h") - vim.cmd("lcd " .. git_root) - end - end, -}) --- show cursor line only in active window -local cursorLineGrp = vim.api.nvim_create_augroup("CursorLine", { clear = true }) -vim.api.nvim_create_autocmd( - { "InsertLeave", "WinEnter" }, - { pattern = "*", command = "set cursorline", group = cursorLineGrp } -) -vim.api.nvim_create_autocmd( - { "InsertEnter", "WinLeave" }, - { pattern = "*", command = "set nocursorline", group = cursorLineGrp } -) -vim.api.nvim_create_autocmd( - { "InsertLeave", "FocusGained" }, - { pattern = "*", command = "set cursorline", group = cursorLineGrp } -) -vim.api.nvim_create_autocmd( - { "InsertEnter", "FocusLost" }, - { pattern = "*", command = "set nocursorline", group = cursorLineGrp } -) --- Auto update on file changes -vim.api.nvim_create_autocmd({ "BufEnter", "CursorHold", "CursorHoldI", "FocusGained" }, { - command = "if mode() != 'c' | checktime | endif", - pattern = { "*" }, -}) -vim.api.nvim_create_autocmd( - { "FileChangedShellPost" }, - { command = 'echohl WarningMsg | echo "File changed on disk. Buffer reloaded." | echohl None', pattern = { "*" } } -) - -------------------------------------------------------------------- --- Plugin management -------------------------------------------------------------------- -local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" - -if not vim.loop.fs_stat(lazypath) then - vim.fn.system({ - "git", - "clone", - "--filter=blob:none", - "https://github.com/folke/lazy.nvim.git", - "--branch=stable", -- latest stable release - lazypath, - }) -end - -vim.opt.rtp:prepend(lazypath) +-- -- show cursor line only in active window +-- local cursorLineGrp = vim.api.nvim_create_augroup("CursorLine", { clear = true }) +-- vim.api.nvim_create_autocmd( +-- { "InsertLeave", "WinEnter" }, +-- { pattern = "*", command = "set cursorline", group = cursorLineGrp } +-- ) +-- vim.api.nvim_create_autocmd( +-- { "InsertEnter", "WinLeave" }, +-- { pattern = "*", command = "set nocursorline", group = cursorLineGrp } +-- ) +-- vim.api.nvim_create_autocmd( +-- { "InsertLeave", "FocusGained" }, +-- { pattern = "*", command = "set cursorline", group = cursorLineGrp } +-- ) +-- vim.api.nvim_create_autocmd( +-- { "InsertEnter", "FocusLost" }, +-- { pattern = "*", command = "set nocursorline", group = cursorLineGrp } +-- ) ------------------------------------------------------------------- -- Plugin installation ------------------------------------------------------------------- -require("lazy").setup({ +vim.pack.add({ + { src = "https://git.cmtec.se/cm/nightly_cm.nvim.git" }, + { src = "https://github.com/mrjones2014/smart-splits.nvim" }, + { src = "https://github.com/nvim-lua/plenary.nvim" }, + { src = "https://github.com/kdheepak/lazygit.nvim" }, + { src = "https://github.com/echasnovski/mini.icons" }, + { src = "https://github.com/echasnovski/mini.statusline" }, + { src = "https://github.com/echasnovski/mini.pick" }, + { src = 'https://github.com/neovim/nvim-lspconfig' }, + { src = 'https://github.com/lewis6991/gitsigns.nvim' }, + { src = 'https://github.com/MunifTanjim/nui.nvim' }, + { src = 'https://github.com/folke/noice.nvim' }, +}) - { - dir = "~/linuxbox/nightly_cm.nvim", - lazy = false, - priority = 1000, - config = function() - vim.cmd.colorscheme("nightly_cm") - end, +------------------------------------------------------------------- +-- Plugin config +------------------------------------------------------------------- +-- colorscheme +vim.cmd.colorscheme("nightly_cm") +require "noice".setup() +require "mini.pick".setup() +require "mini.statusline".setup() +require "gitsigns".setup({ + signs = { + add = { text = "▎" }, + change = { text = "▎" }, + delete = { text = "▎" }, + topdelete = { text = "▎" }, + changedelete = { text = "▎" }, + untracked = { text = "▎" }, }, - - { - "folke/lazydev.nvim", - ft = "lua", -- only load on lua files - opts = { - library = { - { path = "${3rd}/luv/library", words = { "vim%.uv" } }, - }, - }, + preview_config = { + -- Options passed to nvim_open_win + border = "solid", + style = "minimal", + relative = "cursor", + row = 0, + col = 1, }, - - { - "neovim/nvim-lspconfig", - dependencies = { - { "j-hui/fidget.nvim", opts = {} }, +}) +------------------------------------------------------------------- +-- LSP config +------------------------------------------------------------------- +vim.lsp.enable({ "lua_ls", "rust_analyzer", "bashls", "pyright", "marksman", "clangd", "yamlls" }) +-- prevent the built-in vim.lsp.completion autotrigger from selecting the first item +vim.opt.completeopt = { "menuone", "popup", "noselect" } +vim.api.nvim_create_autocmd("LspAttach", { + callback = function(ev) + local client = vim.lsp.get_client_by_id(ev.data.client_id) + if client ~= nil and client:supports_method("textDocument/completion") then + vim.lsp.completion.enable(true, client.id, ev.buf, { autotrigger = true }) + end + end, +}) +vim.diagnostic.config({ + severity_sort = true, + float = { border = "rounded", source = "if_many" }, + underline = { severity = vim.diagnostic.severity.ERROR }, + signs = { + text = { + [vim.diagnostic.severity.ERROR] = "󰅚 ", + [vim.diagnostic.severity.WARN] = "󰀪 ", + [vim.diagnostic.severity.INFO] = "󰋽 ", + [vim.diagnostic.severity.HINT] = "󰌶 ", }, - config = function() - vim.api.nvim_create_autocmd("LspAttach", { - group = vim.api.nvim_create_augroup("kickstart-lsp-attach", { clear = true }), - callback = function(event) - local map = function(keys, func, desc, mode) - mode = mode or "n" - vim.keymap.set(mode, keys, func, { buffer = event.buf, desc = "LSP: " .. desc }) - end - - map("grn", vim.lsp.buf.rename, "[R]e[n]ame") - map("gra", vim.lsp.buf.code_action, "[G]oto Code [A]ction", { "n", "x" }) - map("grr", require("fzf-lua").lsp_references, "[G]oto [R]eferences") - map("gri", require("fzf-lua").lsp_implementations, "[G]oto [I]mplementation") - map("grd", require("fzf-lua").lsp_definitions, "[G]oto [D]efinition") - - -- WARN: This is not Goto Definition, this is Goto Declaration. - -- For example, in C this would take you to the header. - map("grD", vim.lsp.buf.declaration, "[G]oto [D]eclaration") - map("gO", require("fzf-lua").lsp_document_symbols, "Open Document Symbols") - map("gW", require("fzf-lua").lsp_live_workspace_symbols, "Open Workspace Symbols") - map("grt", require("fzf-lua").lsp_typedefs, "[G]oto [T]ype Definition") - end, - }) - - vim.diagnostic.config({ - severity_sort = true, - float = { border = "rounded", source = "if_many" }, - underline = { severity = vim.diagnostic.severity.ERROR }, - signs = { - 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 capabilities = require("blink.cmp").get_lsp_capabilities() - - local servers = { - clangd = {}, - html = {}, - yamlls = {}, - bashls = {}, - pyright = {}, - marksman = {}, - rust_analyzer = {}, - lua_ls = { - settings = { - Lua = { - completion = { - callSnippet = "Replace", - }, - }, - }, - }, + } 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, } - - for server_name, server in pairs(servers) do - server.capabilities = vim.tbl_deep_extend("force", {}, capabilities, server.capabilities or {}) - require("lspconfig")[server_name].setup(server) - end + return diagnostic_message[diagnostic.severity] end, }, +}) - { - "stevearc/conform.nvim", - opts = { - formatters_by_ft = { - lua = { "stylua" }, - python = { "isort", "black" }, - rust = { "rustfmt", lsp_format = "fallback" }, - c = { "clang_format" }, - cpp = { "clang_format" }, - javascript = { "prettier" }, - typescript = { "prettier" }, - javascriptreact = { "prettier" }, - typescriptreact = { "prettier" }, - css = { "prettier" }, - html = { "prettier" }, - json = { "prettier" }, - yaml = { "prettier" }, - markdown = { "prettier" }, - sh = { "shfmt" }, - }, - formatters = { - clang_format = { - prepend_args = { "--style={BasedOnStyle: LLVM, IndentWidth: 4, TabWidth: 4, UseTab: Never}" }, - }, - shfmt = { - prepend_args = { "-i", "4" }, - }, - }, - format_on_save = { - timeout_ms = 3000, - lsp_format = "fallback", - }, - }, - }, +------------------------------------------------------------------- +-- Keybindings +------------------------------------------------------------------- +local map = vim.keymap.set +vim.g.mapleader = " " +-- QoL bindings +map('i', 'jj', '', { noremap = true, silent = true }) +map('n', 'u', ':update :source', { noremap = true, silent = true }) +map('n', 'w', ':write', { noremap = true, silent = true }) +map('n', 'q', ':quit', { noremap = true, silent = true }) +map('n', 'v', ':vsplit', { noremap = true, silent = true }) - { - "saghen/blink.cmp", - event = "VimEnter", - version = "1.*", - -- optional: provides snippets for the snippet source - dependencies = { "rafamadriz/friendly-snippets" }, - --- @module 'blink.cmp' - --- @type blink.cmp.Config - opts = { - keymap = { - preset = "default", - }, +-- Git +map('n', 'g', ':LazyGitCurrentFile', { noremap = true, silent = true }) - appearance = { - nerd_font_variant = "mono", - }, +-- File browser +map('n', 'e', ':25Lex', { noremap = true, silent = true }) +map('n', 'f', ":Pick files", { noremap = true, silent = true }) +map('n', 'h', ":Pick help", { noremap = true, silent = true }) - completion = { - documentation = { auto_show = false, auto_show_delay_ms = 500 }, - }, +-- LSP +map('n', 'lf', vim.lsp.buf.format, { noremap = true, silent = true }) - sources = { - default = { "lsp", "buffer", "path", "snippets" }, - }, +-- Global Copy/Paste +map({ 'n', 'v' }, 'y', '"+y', { noremap = true, silent = true }) +map({ 'n', 'v' }, 'd', '"+d', { noremap = true, silent = true }) +map({ 'n', 'v' }, 'c', '1z=', { noremap = true, silent = true }) - fuzzy = { implementation = "prefer_rust_with_warning" }, - }, - }, - - { - "nvim-treesitter/nvim-treesitter", - build = ":TSUpdate", - main = "nvim-treesitter.configs", -- Sets main module to use for opts - opts = { - ensure_installed = { - "bash", - "c", - "diff", - "html", - "lua", - "luadoc", - "markdown", - "markdown_inline", - "query", - "vim", - "vimdoc", - "rust", - "python", - }, - auto_install = true, - highlight = { - enable = true, - additional_vim_regex_highlighting = { "ruby" }, - }, - indent = { enable = true, disable = { "ruby" } }, - }, - }, - - { - "ibhagwan/fzf-lua", - dependencies = { "echasnovski/mini.icons" }, - opts = { - "telescope", - fzf_colors = { - true, -- inherit fzf colors that aren't specified below from - -- the auto-generated theme similar to `fzf_colors=true` - ["fg"] = { "fg", "CursorLine" }, - ["bg"] = { "bg", "Normal" }, - ["hl"] = { "fg", "Comment" }, - ["fg+"] = { "fg", "Normal", "underline" }, - ["bg+"] = { "bg", { "CursorLine", "Normal" } }, - ["hl+"] = { "fg", "Statement" }, - ["info"] = { "fg", "PreProc" }, - ["prompt"] = { "fg", "Conditional" }, - ["pointer"] = { "fg", "Exception" }, - ["marker"] = { "fg", "Keyword" }, - ["spinner"] = { "fg", "Label" }, - ["header"] = { "fg", "Comment" }, - ["gutter"] = "-1", - }, - files = { - git_icons = true, -- show git icons? - file_icons = true, -- show file icons (true|"devicons"|"mini")? - color_icons = true, -- colorize file|git icons - }, - }, - }, - - { - "mrjones2014/smart-splits.nvim", - lazy = false, - opts = { - at_edge = "stop", - float_win_behavior = "mux", - ignored_buftypes = { "nofile", "quickfix", "prompt", "fzf" }, - ignored_filetypes = { "NvimTree", "fzf" }, - }, - }, - - { - "nvim-lualine/lualine.nvim", - opts = { - options = { - icons_enabled = true, - theme = "nightly_cm", - component_separators = "", - section_separators = "", - globalstatus = true, - }, - sections = { - lualine_a = { "mode" }, - lualine_b = { "branch", "diff" }, - lualine_c = { "diagnostics", "filename" }, - lualine_x = { - { - function() - return vim.fn.getcwd() - end, - }, - { - -- Lsp server name . - function() - local msg = "" - local clients = vim.lsp.get_clients({ bufnr = 0 }) - if next(clients) == nil then - return msg - end - for _, client in ipairs(clients) do - msg = msg .. client.name .. ", " - end - if msg == "" then - return msg - end - return msg:sub(1, -3) - end, - color = { fg = "#c6c6c6" }, - }, - }, - lualine_y = { "filetype" }, - lualine_z = { "progress" }, - }, - }, - }, - - { "echasnovski/mini.icons", version = "*", opts = {} }, - { "echasnovski/mini.pairs", version = "*", opts = {} }, - { "echasnovski/mini.surround", version = "*", opts = {} }, - { - "echasnovski/mini.files", - version = "*", - opts = { mappings = { - go_n_plus = "l", - go_out = "h", - go_out_plus = "H", - } }, - }, - - { - "karb94/neoscroll.nvim", - opts = { duration_multiplier = 0.5 }, - }, - - { - "folke/flash.nvim", - event = "VeryLazy", - ---@type Flash.Config - opts = {}, - -- stylua: ignore - keys = { - { "s", mode = { "n", "x", "o" }, function() require("flash").jump() end, desc = "Flash" }, - { "S", mode = { "n", "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" }, - }, - }, - - { - "lewis6991/gitsigns.nvim", - opts = { - signs = { - add = { text = "▎" }, - change = { text = "▎" }, - delete = { text = "▎" }, - topdelete = { text = "▎" }, - changedelete = { text = "▎" }, - untracked = { text = "▎" }, - }, - preview_config = { - -- Options passed to nvim_open_win - border = "solid", - style = "minimal", - relative = "cursor", - row = 0, - col = 1, - }, - }, - }, - - { - "kdheepak/lazygit.nvim", - lazy = true, - cmd = { - "LazyGit", - "LazyGitConfig", - "LazyGitCurrentFile", - "LazyGitFilter", - "LazyGitFilterCurrentFile", - }, - -- optional for floating window border decoration - dependencies = { - "nvim-lua/plenary.nvim", - }, - -- setting the keybinding for LazyGit with 'keys' is recommended in - -- order to load the plugin when the command is run for the first time - keys = { - { "", "LazyGit", desc = "LazyGit" }, - }, - }, - - { - "MeanderingProgrammer/render-markdown.nvim", - -- dependencies = { "nvim-treesitter/nvim-treesitter", "echasnovski/mini.nvim" }, -- if you use the mini.nvim suite - dependencies = { "nvim-treesitter/nvim-treesitter", "echasnovski/mini.icons" }, -- if you use standalone mini plugins - -- dependencies = { 'nvim-treesitter/nvim-treesitter', 'nvim-tree/nvim-web-devicons' }, -- if you prefer nvim-web-devicons - ---@module 'render-markdown' - ---@type render.md.UserConfig - opts = {}, - }, - - { - "lukas-reineke/indent-blankline.nvim", - main = "ibl", - ---@module "ibl" - ---@type ibl.config - opts = { - scope = { - show_end = false, - }, - }, - }, - - { - "norcalli/nvim-colorizer.lua", - opts = { "*" }, - }, - - { - "folke/which-key.nvim", - event = "VeryLazy", - init = function() - vim.o.timeout = true - vim.o.timeoutlen = 300 - end, - opts = {}, - }, - - { - "folke/noice.nvim", - event = "VeryLazy", - opts = { - -- add any options here - }, - dependencies = { - -- if you lazy-load any plugin below, make sure to add proper `module="..."` entries - "MunifTanjim/nui.nvim", - -- OPTIONAL: - -- `nvim-notify` is only needed, if you want to use the notification view. - -- If not available, we use `mini` as the fallback - "rcarriga/nvim-notify", - }, - }, - - { - "max397574/better-escape.nvim", - opts = { timeout = 300 }, - }, - - { "numToStr/Comment.nvim", opts = {} }, - - { - "folke/todo-comments.nvim", - dependencies = { "nvim-lua/plenary.nvim" }, - opts = {}, - }, -}, {}) - --- resizing splits -vim.keymap.set({ "n", "t" }, "", require("smart-splits").resize_left, { desc = "Resize left" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").resize_down, { desc = "Resize down" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").resize_up, { desc = "Resize up" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").resize_right, { desc = "Resize right" }) --- moving between splits -vim.keymap.set({ "n", "t" }, "", require("smart-splits").move_cursor_left, { desc = "Move cursor left" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").move_cursor_down, { desc = "Move cursor down" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").move_cursor_up, { desc = "Move cursor up" }) -vim.keymap.set({ "n", "t" }, "", require("smart-splits").move_cursor_right, { desc = "Move cursor right" }) --- swapping buffers between windows -vim.keymap.set("n", "h", require("smart-splits").swap_buf_left, { desc = "Swap buffer left" }) -vim.keymap.set("n", "j", require("smart-splits").swap_buf_down, { desc = "Swap buffer down" }) -vim.keymap.set("n", "k", require("smart-splits").swap_buf_up, { desc = "Swap buffer up" }) -vim.keymap.set("n", "l", require("smart-splits").swap_buf_right, { desc = "Swap buffer right" }) --- Yank, delete, and paste always use system clipboard -vim.keymap.set({ "n", "v" }, "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 }) --- vim.keymap.set({ 'n', 'v' }, 'x', '"+x', { noremap = true, silent = true }) -vim.keymap.set({ "n", "v" }, "p", '"+p', { noremap = true, silent = true }) -vim.keymap.set({ "n", "v" }, "P", '"+P', { noremap = true, silent = true }) --- Other -vim.keymap.set("n", "", "nohlsearch") -vim.keymap.set("n", "", ":tabNext", { desc = "Next tab", silent = true }) -vim.keymap.set("n", "", ":write", { desc = "Save", silent = true }) -vim.keymap.set("n", "", ":quit", { desc = "Quit", silent = true }) -vim.keymap.set("n", "e", ":e .", { desc = "File explorer", silent = true }) -vim.keymap.set("n", "f", ":FzfLua files", { desc = "Find file in cwd", silent = true }) -vim.keymap.set("n", "F", ":FzfLua files cwd=~/", { desc = "Find file in root", silent = true }) -vim.keymap.set("n", "b", ":FzfLua buffers", { desc = "Buffers", silent = true }) -vim.keymap.set("n", "d", ":FzfLua lsp_document_diagnostics", { desc = "Diagnostics", silent = true }) -vim.keymap.set("n", "o", ":FzfLua oldfiles", { desc = "Old file", silent = true }) -vim.keymap.set("n", "g", ":FzfLua git_status", { desc = "Git status", silent = true }) -vim.keymap.set("n", "t", ":below terminal", { desc = "Terminal", silent = true }) +-- Smart splits to support TMUX +map({ "n", "t" }, "", require("smart-splits").resize_left, { desc = "Resize left" }) +map({ "n", "t" }, "", require("smart-splits").resize_down, { desc = "Resize down" }) +map({ "n", "t" }, "", require("smart-splits").resize_up, { desc = "Resize up" }) +map({ "n", "t" }, "", require("smart-splits").resize_right, { desc = "Resize right" }) +map({ "n", "t" }, "", require("smart-splits").move_cursor_left, { desc = "Move cursor left" }) +map({ "n", "t" }, "", require("smart-splits").move_cursor_down, { desc = "Move cursor down" }) +map({ "n", "t" }, "", require("smart-splits").move_cursor_up, { desc = "Move cursor up" }) +map({ "n", "t" }, "", require("smart-splits").move_cursor_right, { desc = "Move cursor right" }) +map("n", "h", require("smart-splits").swap_buf_left, { desc = "Swap buffer left" }) +map("n", "j", require("smart-splits").swap_buf_down, { desc = "Swap buffer down" }) +map("n", "k", require("smart-splits").swap_buf_up, { desc = "Swap buffer up" }) +map("n", "l", require("smart-splits").swap_buf_right, { desc = "Swap buffer right" }) diff --git a/config/nvim/lua/.luarc.json b/config/nvim/lua/.luarc.json deleted file mode 100644 index 23b9ee2..0000000 --- a/config/nvim/lua/.luarc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "workspace.checkThirdParty": false -} \ No newline at end of file diff --git a/config/nvim/lua/custom/chadrc.lua b/config/nvim/lua/custom/chadrc.lua deleted file mode 100644 index d597261..0000000 --- a/config/nvim/lua/custom/chadrc.lua +++ /dev/null @@ -1,6 +0,0 @@ ----@type ChadrcConfig -local M = {} -M.ui = {theme = 'tomorrow_night'} -M.plugins = 'custom.plugins' -M.mappings = require "custom.mappings" -return M diff --git a/config/nvim/lua/custom/configs/lspconfig.lua b/config/nvim/lua/custom/configs/lspconfig.lua deleted file mode 100644 index c960e9d..0000000 --- a/config/nvim/lua/custom/configs/lspconfig.lua +++ /dev/null @@ -1,27 +0,0 @@ -local on_attach = require("plugins.configs.lspconfig").on_attach -local capabilities = require("plugins.configs.lspconfig").capabilities - -local lspconfig = require("lspconfig") -local util = require "lspconfig/util" -local servers = { "html", "cssls", "clangd", "pyright"} - -for _, lsp in ipairs(servers) do - lspconfig[lsp].setup { - on_attach = on_attach, - capabilities = capabilities, - } -end - -lspconfig.rust_analyzer.setup({ - on_attach = on_attach, - capabilities = capabilities, - filetypes = {"rust"}, - root_dir = util.root_pattern("Cargo.toml"), - settings = { - ['rust-analyzer'] = { - cargo = { - allFeatures = true, - }, - }, - }, -}) diff --git a/config/nvim/lua/custom/configs/null-ls.lua b/config/nvim/lua/custom/configs/null-ls.lua deleted file mode 100644 index 2a25470..0000000 --- a/config/nvim/lua/custom/configs/null-ls.lua +++ /dev/null @@ -1,16 +0,0 @@ -local null_ls = require "null-ls" - -local formatting = null_ls.builtins.formatting -local lint = null_ls.builtins.diagnostics - -local sources = { - formatting.prettier, - formatting.stylua, - - lint.shellcheck, -} - -null_ls.setup { - debug = true, - sources = sources, -} diff --git a/config/nvim/lua/custom/configs/overrides.lua b/config/nvim/lua/custom/configs/overrides.lua deleted file mode 100644 index 9cf0d1e..0000000 --- a/config/nvim/lua/custom/configs/overrides.lua +++ /dev/null @@ -1,68 +0,0 @@ -local M = {} - -M.treesitter = { - ensure_installed = { - "vim", - "lua", - "html", - "css", - "javascript", - "typescript", - "tsx", - "c", - "cpp", - "rust", - "markdown", - "markdown_inline", - "python" - }, - indent = { - enable = true, - -- disable = { - -- "python" - -- }, - }, -} - -M.mason = { - ensure_installed = { - -- lua stuff - "lua-language-server", - "stylua", - - -- web dev stuff - "css-lsp", - "html-lsp", - "typescript-language-server", - "deno", - "prettier", - - -- c/cpp stuff - "clangd", - "clang-format", - - -- rust - "rust-analyzer", - - -- python - "pyright", - }, -} - --- git support in nvimtree -M.nvimtree = { - git = { - enable = true, - }, - - renderer = { - highlight_git = true, - icons = { - show = { - git = true, - }, - }, - }, -} - -return M diff --git a/config/nvim/lua/custom/init.lua b/config/nvim/lua/custom/init.lua deleted file mode 100644 index 314c95f..0000000 --- a/config/nvim/lua/custom/init.lua +++ /dev/null @@ -1 +0,0 @@ -vim.g.dap_virtual_text = true diff --git a/config/nvim/lua/custom/mappings.lua b/config/nvim/lua/custom/mappings.lua deleted file mode 100644 index e2acf4b..0000000 --- a/config/nvim/lua/custom/mappings.lua +++ /dev/null @@ -1,30 +0,0 @@ -local M = {} - -M.dap = { - plugin = true, - n = { - ["db"] = { " DapToggleBreakpoint " }, - ["dus"] = { - function () - local widgets = require('dap.ui.widgets'); - local sidebar = widgets.sidebar(widgets.scopes); - sidebar.open(); - end, - "Open debugging sidebar" - } - } -} - -M.crates = { - plugin = true, - n = { - ["rcu"] = { - function () - require('crates').upgrade_all_crates() - end, - "update crates" - } - } -} - -return M diff --git a/config/nvim/lua/custom/plugins.lua b/config/nvim/lua/custom/plugins.lua deleted file mode 100644 index 132d296..0000000 --- a/config/nvim/lua/custom/plugins.lua +++ /dev/null @@ -1,161 +0,0 @@ -local overrides = require("custom.configs.overrides") - ----@type NvPluginSpec[] -local plugins = { - -- Override plugin definition options - { - "neovim/nvim-lspconfig", - dependencies = { - "jose-elias-alvarez/null-ls.nvim", - config = function() - require "custom.configs.null-ls" - end, - }, - config = function() - require "plugins.configs.lspconfig" - require "custom.configs.lspconfig" - end, - }, - -- override plugin configs - { - "williamboman/mason.nvim", - opts = overrides.mason - }, - - { - "nvim-treesitter/nvim-treesitter", - opts = overrides.treesitter, - }, - - { - "nvim-tree/nvim-tree.lua", - opts = overrides.nvimtree, - }, - - -- Debugger - { - "mfussenegger/nvim-dap", - init = function() - require("core.utils").load_mappings("dap") - end - }, - - { - "theHamsta/nvim-dap-virtual-text", - lazy = false, - config = function(_, opts) - require("nvim-dap-virtual-text").setup() - end - }, - - -- Rust - -- { - -- "simrat39/rust-tools.nvim", - -- ft = "rust", - -- dependencies = "neovim/nvim-lspconfig", - -- opts = function () - -- return require "custom.configs.rust-tools" - -- end, - -- config = function(_, opts) - -- require('rust-tools').setup(opts) - -- end - -- }, - - -- { - -- 'saecki/crates.nvim', - -- ft = {"rust", "toml"}, - -- config = function(_, opts) - -- local crates = require('crates') - -- crates.setup(opts) - -- require('cmp').setup.buffer({ - -- sources = { { name = "crates" }} - -- }) - -- crates.show() - -- require("core.utils").load_mappings("crates") - -- end, - -- }, - - { - "rust-lang/rust.vim", - ft = "rust", - init = function () - vim.g.rustfmt_autosave = 1 - end - }, - - -- Better escape (jj/jk) - { - "max397574/better-escape.nvim", - event = "InsertEnter", - config = function() - require("better_escape").setup() - end, - }, - - -- Signatures plugin to show function signatures as you type them - { - "ray-x/lsp_signature.nvim", - event = "BufRead", - config = function() - require("lsp_signature").setup { - hint_enable = false, - } - end, - }, - - -- -- Rooter plugin to change directory to the project root - -- { - -- "notjedi/nvim-rooter.lua", - -- event = "UIEnter", - -- config = function() - -- require("nvim-rooter").setup { - -- rooter_patterns = { "Makefile", ".git", ".hg", ".svn" }, - -- trigger_patterns = { "*" }, - -- manual = false, - -- } - -- end, - -- }, - - -- Leap plugin to jump to any line in the file - { - "ggandor/leap.nvim", - event = "UIEnter", - config = function() require("leap").add_default_mappings() end, - }, - - -- Copilot plugin to autocomplete text - { - "zbirenbaum/copilot.lua", - cmd = "Copilot", - event = "InsertEnter", - config = function() - require("copilot").setup { - suggestion = { enabled = false }, - panel = { enabled = false }, - filetypes = { markdown = true }, - } - end, - }, - - -- Copilot CMP plugin to autocomplete text in the completion menu - { - "zbirenbaum/copilot-cmp", - dependencies = "zbirenbaum/copilot.lua", - event = "InsertEnter", - config = function() require("copilot_cmp").setup() end, - }, - -- { - -- "hrsh7th/nvim-cmp", - -- opts = function() - -- local M = require "plugins.configs.cmp" - -- M.completion.completeopt = "menu,menuone,noselect" - -- M.mapping[""] = cmp.mapping.confirm { - -- behavior = cmp.ConfirmBehavior.Insert, - -- select = false, - -- } - -- table.insert(M.sources, {name = "crates"}) - -- return M - -- end, - -- } -} -return plugins diff --git a/config/nvim/lua/user/.luarc.json b/config/nvim/lua/user/.luarc.json deleted file mode 100644 index 23b9ee2..0000000 --- a/config/nvim/lua/user/.luarc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "workspace.checkThirdParty": false -} \ No newline at end of file diff --git a/config/nvim/lua/user/.stylua.toml b/config/nvim/lua/user/.stylua.toml deleted file mode 100644 index ae75a92..0000000 --- a/config/nvim/lua/user/.stylua.toml +++ /dev/null @@ -1,7 +0,0 @@ -column_width = 200 -line_endings = "Unix" -indent_type = "Spaces" -indent_width = 2 -quote_style = "AutoPreferDouble" -call_parentheses = "None" -collapse_simple_statement = "Always" diff --git a/config/nvim/lua/user/init.lua b/config/nvim/lua/user/init.lua deleted file mode 100644 index 742d9b9..0000000 --- a/config/nvim/lua/user/init.lua +++ /dev/null @@ -1,98 +0,0 @@ -return { - -- Configure AstroNvim updates - updater = { - remote = "origin", -- remote to use - channel = "stable", -- "stable" or "nightly" - version = "latest", -- "latest", tag name, or regex search like "v1.*" to only do updates before v2 (STABLE ONLY) - branch = "nightly", -- branch name (NIGHTLY ONLY) - commit = nil, -- commit hash (NIGHTLY ONLY) - pin_plugins = nil, -- nil, true, false (nil will pin plugins on stable only) - skip_prompts = false, -- skip prompts about breaking changes - show_changelog = true, -- show the changelog after performing an update - auto_quit = false, -- automatically quit the current session after a successful update - remotes = { -- easily add new remotes to track - }, - }, - - -- Set colorscheme to use - colorscheme = "astrodark", - - -- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on - diagnostics = { virtual_text = true, underline = true }, - - lsp = { - -- customize lsp formatting options - formatting = { - -- control auto formatting on save - format_on_save = { - enabled = false, -- enable or disable format on save globally - allow_filetypes = { -- enable format on save for specified filetypes only - -- "go", - }, - ignore_filetypes = { -- disable format on save for specified filetypes - -- "python", - }, - }, - disabled = { -- disable formatting capabilities for the listed language servers - -- disable lua_ls formatting capability if you want to use StyLua to format your lua code - -- "lua_ls", - }, - timeout_ms = 1000, -- default format timeout - -- filter = function(client) -- fully override the default formatting function - -- return true - -- end - }, - -- enable servers that you already have installed without mason - servers = { - -- "pyright" - }, - }, - - -- Configure require("lazy").setup() options - lazy = { - defaults = { lazy = true }, - performance = { - rtp = { - -- customize default disabled vim plugins - disabled_plugins = { - "tohtml", - "gzip", - "matchit", - "zipPlugin", - "netrwPlugin", - "tarPlugin", - }, - }, - }, - }, - - -- This function is run last and is a good place to configuring - -- augroups/autocommands and custom filetypes also this just pure lua so - -- anything that doesn't fit in the normal config locations above can go here - polish = function() - local rt = require "rust-tools" - - rt.setup { - server = { - on_attach = function(_, bufnr) - -- Hover actions - vim.keymap.set("n", "", rt.hover_actions.hover_actions, { buffer = bufnr }) - -- Code action groups - vim.keymap.set("n", "a", rt.code_action_group.code_action_group, { buffer = bufnr }) - end, - }, - } - -- Set up custom filetypes - -- vim.filetype.add { - -- extension = { - -- foo = "fooscript", - -- }, - -- filename = { - -- ["Foofile"] = "fooscript", - -- }, - -- pattern = { - -- ["~/%.config/foo/.*"] = "fooscript", - -- }, - -- } - end, -} diff --git a/config/nvim/lua/user/lsp/config/clangd.lua b/config/nvim/lua/user/lsp/config/clangd.lua deleted file mode 100644 index 8f48229..0000000 --- a/config/nvim/lua/user/lsp/config/clangd.lua +++ /dev/null @@ -1,5 +0,0 @@ -return { - capabilities = { - offsetEncoding = "utf-16", - }, -} diff --git a/config/nvim/lua/user/lsp/config/lua_ls.lua b/config/nvim/lua/user/lsp/config/lua_ls.lua deleted file mode 100644 index 4f8e140..0000000 --- a/config/nvim/lua/user/lsp/config/lua_ls.lua +++ /dev/null @@ -1,22 +0,0 @@ -return { - settings = { - Lua = { - runtime = { - -- Tell the language server which version of Lua you're using (most likely LuaJIT in the case of Neovim) - version = "LuaJIT", - }, - diagnostics = { - -- Get the language server to recognize the `vim` global - globals = { "vim" }, - }, - workspace = { - -- Make the server aware of Neovim runtime files - library = vim.api.nvim_get_runtime_file("", true), - }, - -- Do not send telemetry data containing a randomized but unique identifier - telemetry = { - enable = false, - }, - }, - }, -} diff --git a/config/nvim/lua/user/mappings.lua b/config/nvim/lua/user/mappings.lua deleted file mode 100644 index a1fbeb0..0000000 --- a/config/nvim/lua/user/mappings.lua +++ /dev/null @@ -1,46 +0,0 @@ --- Mapping data with "desc" stored directly by vim.keymap.set(). --- --- Please use this mappings table to set keyboard mapping since this is the --- lower level configuration and more robust one. (which-key will --- automatically pick-up stored data by this setting.) - -return { - -- first key is the mode - n = { - ["bD"] = { - function() - require("astronvim.utils.status").heirline.buffer_picker(function(bufnr) require("astronvim.utils.buffer").close( - bufnr) end) - end, - desc = "Pick to close", - }, - - ["b"] = { name = "Buffers" }, - [""] = { ":bnext", desc = "Next buffer tab" }, - - -- Open file - [""] = { ":Telescope find_files search_dirs=~/", desc = "Open file" }, - [""] = { ":Telescope find_files search_dirs=~/ hidden=true", desc = - "Open file inc. hidden files" }, - - -- Make - ["m"] = { name = "Make (Compile)" }, - ["mm"] = { ":make", desc = "Make" }, - ["mn"] = { ":make clean", desc = "Make clean" }, - ["mr"] = { ":make run", desc = "Make run" }, - ["mu"] = { ":make upload", desc = "Make upload" }, - - -- Go to source file - ["gs"] = { ":ClangdSwitchSourceHeader" }, - - -- Format code - [""] = { ":Format" }, - ["a"] = { ":lua require'rust-tools'.hover_actions.hover_actions()" }, - -- Disable bindings - ["n"] = false, - }, - t = { - -- setting a mapping to false will disable it - -- [""] = false, - }, -} diff --git a/config/nvim/lua/user/options.lua b/config/nvim/lua/user/options.lua deleted file mode 100644 index 23d6528..0000000 --- a/config/nvim/lua/user/options.lua +++ /dev/null @@ -1,30 +0,0 @@ --- set vim options here (vim.. = value) -return { - opt = { - -- set to true or false etc. - relativenumber = true, -- sets vim.opt.relativenumber - number = true, -- sets vim.opt.number - spell = false, -- sets vim.opt.spell - signcolumn = "auto", -- sets vim.opt.signcolumn to auto - wrap = false, -- sets vim.opt.wrap - textwidth = 200, -- sets vim.opt.textwidth - }, - g = { - mapleader = " ", -- sets vim.g.mapleader - autoformat_enabled = true, -- enable or disable auto formatting at start (lsp.formatting.format_on_save must be enabled) - cmp_enabled = true, -- enable completion at start - autopairs_enabled = true, -- enable autopairs at start - diagnostics_mode = 3, -- set the visibility of diagnostics in the UI (0=off, 1=only show in status line, 2=virtual text off, 3=all on) - icons_enabled = true, -- disable icons in the UI (disable if no nerd font is available, requires :PackerSync after changing) - ui_notifications_enabled = true, -- disable notifications when toggling UI elements - }, -} --- If you need more control, you can use the function()...end notation --- return function(local_vim) --- local_vim.opt.relativenumber = true --- local_vim.g.mapleader = " " --- local_vim.opt.whichwrap = vim.opt.whichwrap - { 'b', 's' } -- removing option from list --- local_vim.opt.shortmess = vim.opt.shortmess + { I = true } -- add to option list --- --- return local_vim --- end diff --git a/config/nvim/lua/user/plugins/astrotheme.lua b/config/nvim/lua/user/plugins/astrotheme.lua deleted file mode 100644 index a9c7504..0000000 --- a/config/nvim/lua/user/plugins/astrotheme.lua +++ /dev/null @@ -1,27 +0,0 @@ -return { - "AstroNvim/astrotheme", - config = function() - require("astrotheme").setup { - - palettes = { - astrodark = { - -- Extend or modify astrodarks palette colors - base = "#1e1e1e", - mantle = "#181818", - crust = "#1f1f1f", - surface0 = "#252525", - surface1 = "#3e3e3e", - overlay1 = "#2c2c2c", - overlay2 = "#282828", - subtext0 = "#4b4b4b", - subtext1 = "#777777", - text = "#ababab", - }, - }, - - highlights = { - astrodark = {}, - }, - } - end, -} diff --git a/config/nvim/lua/user/plugins/cmp.lua b/config/nvim/lua/user/plugins/cmp.lua deleted file mode 100644 index 051d4a1..0000000 --- a/config/nvim/lua/user/plugins/cmp.lua +++ /dev/null @@ -1,20 +0,0 @@ -return { - "hrsh7th/nvim-cmp", - -- override the options table that is used in the `require("cmp").setup()` call - opts = function(_, opts) - -- opts parameter is the default options table - -- the function is lazy loaded so cmp is able to be required - local cmp = require "cmp" - -- modify the sources part of the options table - opts.sources = cmp.config.sources { - { name = "nvim_lsp", priority = 1000 }, - { name = "luasnip", priority = 750 }, - { name = "buffer", priority = 500 }, - { name = "path", priority = 250 }, - { name = "copilot", priority = 100 }, - } - - -- return the new table to be used - return opts - end, -} -- override nvim-cmp plugin diff --git a/config/nvim/lua/user/plugins/community.lua b/config/nvim/lua/user/plugins/community.lua deleted file mode 100644 index 420cacd..0000000 --- a/config/nvim/lua/user/plugins/community.lua +++ /dev/null @@ -1,9 +0,0 @@ -return { - -- Add the community repository of plugin specifications - -- "AstroNvim/astrocommunity", - -- example of imporing a plugin, comment out to use it or add your own - -- available plugins can be found at https://github.com/AstroNvim/astrocommunity - - -- { import = "astrocommunity.colorscheme.catppuccin" }, - -- { import = "astrocommunity.completion.copilot-lua-cmp" }, -} diff --git a/config/nvim/lua/user/plugins/core.lua b/config/nvim/lua/user/plugins/core.lua deleted file mode 100644 index 5231ce5..0000000 --- a/config/nvim/lua/user/plugins/core.lua +++ /dev/null @@ -1,82 +0,0 @@ -return { - -- customize alpha options - { - "goolord/alpha-nvim", - opts = function(_, opts) - -- customize the dashboard header - opts.section.header.val = { - " =======================================================================================================", - " -------------------------------------------------------------------------------------------------------", - " ---████████████████████-----███████████-------███████████-----████████████--████████████-████████████--", - " --█████████████████████----█████████████-----█████████████---- -- - ---", - " --██████ ██---█████ ███-----███ █████---------██-------████████-----█-------------", - " -- -------------- --- ----- --- ----- ---------██-------█------------█-------------", - " --█████--------------------█████------████-████------█████---------██-------███████████--████████████--", - " -- -------------------- ------ ------ --------- ------- -- --", - " --█████--------------------█████--------█████--------█████---------------------------------------------", - " -- -------------------- -------- -------- ---------------------------------------------", - " --██████--------------██---█████---------------------█████------------- (Neo)vim coding IDE -----------", - " --█████████████████████ ---█████---------------------█████---------------------------------------------", - " ---███████████████████ ----█████---------------------█████---------------------------------------------", - " --- ----- --------------------- ---------------------------------------------", - " -------------------------------------------------------------------------------------------------------", - " =======================================================================================================", - } - opts.section.header.opts.hl = "String" - end, - }, - -- You can disable default plugins as follows: - -- { "max397574/better-escape.nvim", enabled = false }, - -- - -- You can also easily customize additional setup of plugins that is outside of the plugin's setup call - -- { - -- "L3MON4D3/LuaSnip", - -- config = function(plugin, opts) - -- require "plugins.configs.luasnip"(plugin, opts) -- include the default astronvim config that calls the setup call - -- -- add more custom luasnip configuration such as filetype extend or custom snippets - -- local luasnip = require "luasnip" - -- luasnip.filetype_extend("javascript", { "javascriptreact" }) - -- end, - -- }, - -- { - -- "windwp/nvim-autopairs", - -- config = function(plugin, opts) - -- require "plugins.configs.nvim-autopairs"(plugin, opts) -- include the default astronvim config that calls the setup call - -- -- add more custom autopairs configuration such as custom rules - -- local npairs = require "nvim-autopairs" - -- local Rule = require "nvim-autopairs.rule" - -- local cond = require "nvim-autopairs.conds" - -- npairs.add_rules( - -- { - -- Rule("$", "$", { "tex", "latex" }) - -- -- don't add a pair if the next character is % - -- :with_pair(cond.not_after_regex "%%") - -- -- don't add a pair if the previous character is xxx - -- :with_pair( - -- cond.not_before_regex("xxx", 3) - -- ) - -- -- don't move right when repeat character - -- :with_move(cond.none()) - -- -- don't delete if the next character is xx - -- :with_del(cond.not_after_regex "xx") - -- -- disable adding a newline when you press - -- :with_cr(cond.none()), - -- }, - -- -- disable for .vim files, but it work for another filetypes - -- Rule("a", "a", "-vim") - -- ) - -- end, - -- }, - -- By adding to the which-key config and using our helper function you can add more which-key registered bindings - -- { - -- "folke/which-key.nvim", - -- config = function(plugin, opts) - -- require "plugins.configs.which-key"(plugin, opts) -- include the default astronvim config that calls the setup call - -- -- Add bindings which show up as group name - -- local wk = require "which-key" - -- wk.register({ - -- b = { name = "Buffer" }, - -- }, { mode = "n", prefix = "" }) - -- end, - -- }, -} diff --git a/config/nvim/lua/user/plugins/lspkind.lua b/config/nvim/lua/user/plugins/lspkind.lua deleted file mode 100644 index 491e263..0000000 --- a/config/nvim/lua/user/plugins/lspkind.lua +++ /dev/null @@ -1,27 +0,0 @@ -return { - "onsails/lspkind.nvim", - opts = { - mode = "symbol", - symbol_map = { - NONE = "", - Array = "", - Boolean = "⊨", - Class = "", - Constructor = "", - Key = "", - Namespace = "", - Null = "NULL", - Number = "#", - Object = "⦿", - Package = "", - Property = "", - Reference = "", - Snippet = "", - String = "𝓐", - TypeParameter = "", - Unit = "", - Copilot = "", - }, - }, - vim.api.nvim_set_hl(0, "CmpItemKindCopilot", {fg ="#6CC644"}) -} diff --git a/config/nvim/lua/user/plugins/mason.lua b/config/nvim/lua/user/plugins/mason.lua deleted file mode 100644 index c5a7d93..0000000 --- a/config/nvim/lua/user/plugins/mason.lua +++ /dev/null @@ -1,50 +0,0 @@ --- customize mason plugins -return { - -- use mason-lspconfig to configure LSP installations - { - "williamboman/mason-lspconfig.nvim", - -- overrides `require("mason-lspconfig").setup(...)` - opts = function(_, opts) - -- add more things to the ensure_installed table protecting against community packs modifying it - opts.ensure_installed = require("astronvim.utils").list_insert_unique(opts.ensure_installed, { - "lua_ls", - "pyright", - "cssls", - "html", - "jsonls", - "clangd", - "marksman", - "bashls", - "dockerls", - "openscad_lsp", - }) - end, - }, - -- use mason-null-ls to configure Formatters/Linter installation for null-ls sources - { - "jay-babu/mason-null-ls.nvim", - -- overrides `require("mason-null-ls").setup(...)` - opts = function(_, opts) - -- add more things to the ensure_installed table protecting against community packs modifying it - opts.ensure_installed = require("astronvim.utils").list_insert_unique(opts.ensure_installed, { - "prettier", - "clang-format", - "black", - "flake8", - "markdownlint", - "beautysh", - "stylua", - }) - end, - }, - { - "jay-babu/mason-nvim-dap.nvim", - -- overrides `require("mason-nvim-dap").setup(...)` - opts = function(_, opts) - -- add more things to the ensure_installed table protecting against community packs modifying it - opts.ensure_installed = require("astronvim.utils").list_insert_unique(opts.ensure_installed, { - -- "python", - }) - end, - }, -} diff --git a/config/nvim/lua/user/plugins/null-ls.lua b/config/nvim/lua/user/plugins/null-ls.lua deleted file mode 100644 index beceeda..0000000 --- a/config/nvim/lua/user/plugins/null-ls.lua +++ /dev/null @@ -1,17 +0,0 @@ -return { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, config) - -- config variable is the default configuration table for the setup function call - -- local null_ls = require "null-ls" - - -- Check supported formatters and linters - -- https://github.com/jose-elias-alvarez/null-ls.nvim/tree/main/lua/null-ls/builtins/formatting - -- https://github.com/jose-elias-alvarez/null-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics - config.sources = { - -- Set a formatter - -- null_ls.builtins.formatting.stylua, - -- null_ls.builtins.formatting.prettier, - } - return config -- return final config table - end, -} diff --git a/config/nvim/lua/user/plugins/treesitter.lua b/config/nvim/lua/user/plugins/treesitter.lua deleted file mode 100644 index 7a5157e..0000000 --- a/config/nvim/lua/user/plugins/treesitter.lua +++ /dev/null @@ -1,22 +0,0 @@ -return { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - -- add more things to the ensure_installed table protecting against community packs modifying it - opts.ensure_installed = require("astronvim.utils").list_insert_unique(opts.ensure_installed, { - "lua", - "c", - "vim", - "bash", - "json", - "yaml", - "html", - "css", - "javascript", - "typescript", - "python", - "dockerfile", - "cpp", - "rust", - }) - end, -} diff --git a/config/nvim/lua/user/plugins/user.lua b/config/nvim/lua/user/plugins/user.lua deleted file mode 100644 index 10f152d..0000000 --- a/config/nvim/lua/user/plugins/user.lua +++ /dev/null @@ -1,54 +0,0 @@ -return { - -- Signatures plugin to show function signatures as you type them - { - "ray-x/lsp_signature.nvim", - event = "BufRead", - config = function() - require("lsp_signature").setup { - hint_enable = false, - } - end, - }, - - -- Rooter plugin to change directory to the project root - { - "notjedi/nvim-rooter.lua", - event = "UIEnter", - config = function() - require("nvim-rooter").setup { - rooter_patterns = { "Makefile", ".git", ".hg", ".svn" }, - trigger_patterns = { "*" }, - manual = false, - } - end, - }, - - -- Leap plugin to jump to any line in the file - { - "ggandor/leap.nvim", - event = "UIEnter", - config = function() require("leap").add_default_mappings() end, - }, - - -- Copilot plugin to autocomplete text - { - "zbirenbaum/copilot.lua", - cmd = "Copilot", - event = "InsertEnter", - config = function() - require("copilot").setup { - suggestion = { enabled = false }, - panel = { enabled = false }, - filetypes = { markdown = true }, - } - end, - }, - - -- Copilot CMP plugin to autocomplete text in the completion menu - { - "zbirenbaum/copilot-cmp", - event = "InsertEnter", - config = function() require("copilot_cmp").setup() end, - }, - 'simrat39/rust-tools.nvim' -} diff --git a/config/qt5ct/qt5ct.conf b/config/qt5ct/qt5ct.conf index b9c5869..ec9e8fd 100644 --- a/config/qt5ct/qt5ct.conf +++ b/config/qt5ct/qt5ct.conf @@ -1,7 +1,7 @@ [Appearance] -color_scheme_path=/usr/share/qt5ct/colors/airy.conf -custom_palette=false -standard_dialogs=default +color_scheme_path=/usr/share/qt5ct/colors/darker.conf +custom_palette=true +standard_dialogs=gtk3 style=Adwaita-Dark [Fonts] @@ -24,7 +24,7 @@ underline_shortcut=1 wheel_scroll_lines=3 [SettingsWindow] -geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\0\0\0\0\0\0\0\0\x4y\0\0\x2\xdf\0\0\0\0\0\0\0\0\0\0\x4\x7f\0\0\x2\xdf\0\0\0\0\x2\0\0\0\n\0\0\0\0\0\0\0\0\0\0\0\x4y\0\0\x2\xdf) +geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\0\0\0\0\0\0\0\0\aq\0\0\x4\x1a\0\0\0\0\0\0\0\0\0\0\a\x7f\0\0\x4(\0\0\0\0\x2\0\0\0\xf\0\0\0\0\0\0\0\0\0\0\0\aq\0\0\x4\x1a) [Troubleshooting] force_raster_widgets=1 diff --git a/config/qt6ct/qt6ct.conf b/config/qt6ct/qt6ct.conf index e786205..e2bdf99 100644 --- a/config/qt6ct/qt6ct.conf +++ b/config/qt6ct/qt6ct.conf @@ -1,7 +1,7 @@ [Appearance] -color_scheme_path=/usr/share/qt6ct/colors/airy.conf -custom_palette=false -standard_dialogs=default +color_scheme_path=/usr/share/qt6ct/colors/darker.conf +custom_palette=true +standard_dialogs=gtk3 style=Adwaita-Dark [Fonts] @@ -24,7 +24,7 @@ underline_shortcut=1 wheel_scroll_lines=3 [SettingsWindow] -geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\0\0\0\0\0\0\0\0\x5y\0\0\x5\x9b\0\0\0\0\0\0\0\0\0\0\x5\x7f\0\0\x5\x9f\0\0\0\0\x2\0\0\0\n\0\0\0\0\0\0\0\0\0\0\0\x5y\0\0\x5\x9b) +geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\0\0\0\0\0\0\0\0\aq\0\0\x4\x1a\0\0\0\0\0\0\0\0\0\0\aq\0\0\x4\x1a\0\0\0\0\x2\0\0\0\xf\0\0\0\0\0\0\0\0\0\0\0\aq\0\0\x4\x1a) [Troubleshooting] force_raster_widgets=1 diff --git a/config/walker/themes/cmtec.css b/config/walker/themes/cmtec.css index 529cc5a..c70b279 100644 --- a/config/walker/themes/cmtec.css +++ b/config/walker/themes/cmtec.css @@ -40,7 +40,7 @@ slider, border-radius: 2px; background: @background; padding: 32px; - border: 0px solid lighter(@background); + border: 2px solid lighter(@background); box-shadow: 0 19px 38px rgba(0, 0, 0, 0.3), 0 15px 12px rgba(0, 0, 0, 0.22); diff --git a/config/walker/themes/cmtec.toml b/config/walker/themes/cmtec.toml index d2a8498..c375d5f 100644 --- a/config/walker/themes/cmtec.toml +++ b/config/walker/themes/cmtec.toml @@ -1,9 +1,8 @@ - [ui.anchors] -bottom = true -left = true -right = true -top = true +# bottom = true +# left = true +# right = true +# top = true [ui.window] h_align = "fill" @@ -28,15 +27,15 @@ pixel_size = 24 theme = "" [ui.window.box.margins] -top = 400 +# top = 200 [ui.window.box.ai_scroll] name = "aiScroll" h_align = "fill" v_align = "fill" -max_height = 300 +max_height = 200 min_width = 400 -height = 300 +height = 200 width = 400 [ui.window.box.ai_scroll.margins] @@ -57,8 +56,8 @@ y_align = 0 wrap = true [ui.window.box.scroll.list] -marker_color = "#afd787" -max_height = 300 +marker_color = "#1BFFE1" +max_height = 340 max_width = 400 min_width = 400 width = 400 diff --git a/nightly_cm.nvim/LICENSE.txt b/nightly_cm.nvim/LICENSE.txt deleted file mode 100644 index 7e2f7d7..0000000 --- a/nightly_cm.nvim/LICENSE.txt +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2023 Alexis Corporal - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/nightly_cm.nvim/README.md b/nightly_cm.nvim/README.md deleted file mode 100644 index e69de29..0000000 diff --git a/nightly_cm.nvim/autoload/lightline/colorscheme/nightly.vim b/nightly_cm.nvim/autoload/lightline/colorscheme/nightly.vim deleted file mode 100644 index 56a8204..0000000 --- a/nightly_cm.nvim/autoload/lightline/colorscheme/nightly.vim +++ /dev/null @@ -1,2 +0,0 @@ -let s:palette = v:lua.require('lightline.colorscheme.nightly') -let g:lightline#colorscheme#nightly#palette = lightline#colorscheme#fill(s:palette) diff --git a/nightly_cm.nvim/colors/nightly_cm.lua b/nightly_cm.nvim/colors/nightly_cm.lua deleted file mode 100644 index ae2a7fa..0000000 --- a/nightly_cm.nvim/colors/nightly_cm.lua +++ /dev/null @@ -1 +0,0 @@ -require("nightly_cm").load() diff --git a/nightly_cm.nvim/lua/.luarc.json b/nightly_cm.nvim/lua/.luarc.json deleted file mode 100644 index 23b9ee2..0000000 --- a/nightly_cm.nvim/lua/.luarc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "workspace.checkThirdParty": false -} \ No newline at end of file diff --git a/nightly_cm.nvim/lua/lualine/themes/nightly_cm.lua b/nightly_cm.nvim/lua/lualine/themes/nightly_cm.lua deleted file mode 100644 index fbfbda4..0000000 --- a/nightly_cm.nvim/lua/lualine/themes/nightly_cm.lua +++ /dev/null @@ -1,39 +0,0 @@ -local nightly = { - normal = { - a = { bg = "#87afd7", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - c = { bg = "#303030", fg = "#c6c6c6" }, - }, - - insert = { - a = { bg = "#afd787", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - }, - - command = { - a = { bg = "#d7af5f", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - }, - - visual = { - a = { bg = "#87afd7", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - }, - - replace = { - a = { bg = "#d75f00", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - }, - - terminal = { - a = { bg = "#d7af5f", fg = "#0c0c0c" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - }, - - inactive = { - a = { bg = "#303030", fg = "#c6c6c6" }, - b = { bg = "#303030", fg = "#c6c6c6" }, - c = { bg = "#303030", fg = "#c6c6c6" }, - }, -} -return nightly diff --git a/nightly_cm.nvim/lua/nightly_cm/config.lua b/nightly_cm.nvim/lua/nightly_cm/config.lua deleted file mode 100644 index f47a3c8..0000000 --- a/nightly_cm.nvim/lua/nightly_cm/config.lua +++ /dev/null @@ -1,26 +0,0 @@ -local M = {} - -local defaults = { - transparent = false, - styles = { - comments = { italic = true }, - functions = { italic = false }, - variables = { italic = false }, - keywords = { italic = false }, - }, - highlights = {}, -} - -M.options = {} - -function M.setup(options) - M.options = vim.tbl_deep_extend("force", {}, defaults, options or {}) -end - -function M.extend(options) - M.options = vim.tbl_deep_extend("force", {}, M.options or defaults, options or {}) -end - -M.setup() - -return M diff --git a/nightly_cm.nvim/lua/nightly_cm/init.lua b/nightly_cm.nvim/lua/nightly_cm/init.lua deleted file mode 100644 index da7e57c..0000000 --- a/nightly_cm.nvim/lua/nightly_cm/init.lua +++ /dev/null @@ -1,22 +0,0 @@ -local config = require "nightly_cm.config" -local M = {} - -M.setup = config.setup - -function M.load() - -- only needed to clear when not the default colorscheme - if vim.g.colors_name then - vim.cmd "hi clear" - end - - -- enable termguicolors - if vim.api.nvim_get_option "termguicolors" == false then - vim.opt.termguicolors = true - end - - vim.g.colors_name = "nightly_cm" - - require("nightly_cm.theme").setup() -end - -return M diff --git a/nightly_cm.nvim/lua/nightly_cm/palette.lua b/nightly_cm.nvim/lua/nightly_cm/palette.lua deleted file mode 100644 index 8922048..0000000 --- a/nightly_cm.nvim/lua/nightly_cm/palette.lua +++ /dev/null @@ -1,32 +0,0 @@ -local M = {} - -M.dark_colors = { - color0 = "#000000", - color1 = "#d75f00", - color2 = "#afd787", - color3 = "#d7af5f", - color4 = "#87afd7", - color5 = "#d7d7af", - color6 = "#87afd7", - color7 = "#c6c6c6", - color8 = "#000000", - color9 = "#d75f00", - color10 = "#afd787", - color11 = "#d7af5f", - color12 = "#87afd7", - color13 = "#d7d7af", - color14 = "#87afd7", - color15 = "#eeeeee", - color16 = "#000000", - color17 = "#585858", - color18 = "#444444", - comment = "#6c6c6c", - black = "#000000", - background = "#262626", - foreground = "#c6c6c6", - cursorline = "#303030", - iblscope = "#435466", - none = "NONE", -} - -return M diff --git a/nightly_cm.nvim/lua/nightly_cm/theme.lua b/nightly_cm.nvim/lua/nightly_cm/theme.lua deleted file mode 100644 index 73deffd..0000000 --- a/nightly_cm.nvim/lua/nightly_cm/theme.lua +++ /dev/null @@ -1,399 +0,0 @@ -local theme = {} - -function theme.setup() - local options = require("nightly_cm.config").options - - local p = require("nightly_cm.palette").dark_colors - - if options.transparent then - p.background = "NONE" - vim.o.pumblend = 0 - end - - theme.highlights = { - -- Base highlights - Boolean = { fg = p.color5 }, - Character = { fg = p.color12 }, - ColorColumn = { bg = p.none }, - Comment = { fg = p.comment, style = options.styles.comments }, - Conceal = { fg = p.color4, bg = p.background }, - Conditional = { fg = p.color6 }, - Constant = { fg = p.color7 }, - Cursor = { fg = p.foreground, bg = p.foreground }, - CursorNC = { fg = "NONE", bg = "NONE" }, - CurSearch = { link = "IncSearch" }, - CursorColumn = { bg = p.background }, - CursorIM = { fg = p.foreground, bg = p.foreground }, - CursorLine = { bg = p.cursorline }, - CursorLineNr = { fg = p.foreground }, - Debug = { fg = p.color1 }, - Define = { fg = p.color6 }, - Delimiter = { fg = p.foreground }, - DiffAdd = { fg = p.color4, bg = p.background }, - DiffChange = { fg = p.color5, bg = p.background }, - DiffDelete = { fg = p.color1, bg = p.background }, - DiffText = { fg = p.color5, bg = p.background }, - Directory = { fg = p.color4 }, - EndOfBuffer = { fg = p.background }, - EndOfBufferNC = { fg = p.background }, - Error = { fg = p.color1, bg = p.background }, - ErrorMsg = { fg = p.color1, bg = p.background }, - Exception = { fg = p.color6 }, - Float = { fg = p.color5 }, - FloatBorder = { fg = p.comment, bg = p.black }, - FoldColumn = { fg = p.color4, bg = p.background }, - Folded = { fg = p.color4, bg = p.background }, - Function = { fg = p.color6, style = options.styles.functions }, - Identifier = { fg = p.color5 }, - Ignore = { fg = p.color7, bg = p.background }, - IncSearch = { fg = p.black, bg = p.color10 }, - Include = { fg = p.color6 }, - Keyword = { fg = p.color6, style = options.styles.keywords }, - Label = { fg = p.color4 }, - LineNr = { fg = p.color17 }, - Macro = { fg = p.color6 }, - MatchParen = { bg = p.color17 }, - ModeMsg = { fg = p.foreground, bg = p.background }, - MoreMsg = { fg = p.color5 }, - MsgArea = { fg = p.foreground, bg = p.background }, - MsgSeparator = { fg = p.foreground, bg = p.background }, - NonText = { fg = p.color5 }, - Normal = { fg = p.foreground, bg = p.background }, - NormalFloat = { bg = p.black }, - NormalNC = { fg = p.foreground, bg = p.background }, - Number = { fg = p.color3 }, - Operator = { fg = p.color6 }, - Pmenu = { fg = p.foreground, bg = p.black }, - PmenuSbar = { bg = p.black }, - PmenuSel = { fg = p.black, bg = p.color4 }, - PmenuThumb = { bg = p.color2 }, - PreCondit = { fg = p.color6 }, - PreProc = { fg = p.color6 }, - Question = { fg = p.color5 }, - QuickFixLine = { bg = p.color2 }, - Repeat = { fg = p.color6 }, - Search = { fg = p.black, bg = p.color4 }, - SignColumn = { fg = p.background, bg = p.background }, - Special = { fg = p.color6 }, - SpecialChar = { fg = p.foreground }, - SpecialComment = { fg = p.color2 }, - SpecialKey = { fg = p.color4 }, - SpellBad = { fg = p.color2 }, - SpellCap = { fg = p.color6 }, - SpellLocal = { fg = p.color4 }, - SpellRare = { fg = p.color6 }, - Statement = { fg = p.color6 }, - StatusLine = { fg = p.foreground, bg = p.background }, - StStatusLine = { fg = p.foreground, bg = p.background }, - Storage = { fg = p.color5 }, - StorageClass = { fg = p.color7 }, - String = { fg = p.color2 }, - Structure = { fg = p.color6 }, - Substitute = { fg = p.black, bg = p.color5 }, - TabLine = { fg = p.color2, bg = p.color16 }, - TabLineFill = { fg = p.foreground, bg = p.color16 }, - TabLineSel = { fg = p.foreground, bg = p.background }, - Tag = { fg = p.color4 }, - TermCursor = { fg = p.foreground, bg = p.foreground }, - TermCursorNC = { fg = p.foreground, bg = p.foreground }, - Title = { fg = p.color4, bold = true }, - Todo = { fg = p.color1, bg = p.background }, - type = { fg = p.color5 }, - typedef = { fg = p.color6 }, - underlined = { fg = p.color2, underline = true }, - Variable = { fg = p.color15 }, - VertSplit = { fg = p.cursorline }, - Visual = { bg = p.color18 }, - VisualNOS = { bg = p.background }, - WarningMsg = { fg = p.color3, bg = p.background }, - Whitespace = { fg = p.color1 }, - WildMenu = { fg = p.color7, bg = p.color4 }, - lCursor = { fg = p.foreground, bg = p.foreground }, - WinSeparator = { fg = p.cursorline }, - -- bufferline.nvim: https://github.com/akinsho/bufferline.nvim - BufferLineFill = { fg = p.background, bg = p.background }, - BufferLineIndicatorSelected = { fg = p.color2 }, - - -- Diagnostic - DiagnosticError = { fg = p.color1 }, - DiagnosticHint = { fg = p.color2 }, - DiagnosticInfo = { fg = p.color4 }, - DiagnosticWarn = { fg = p.color3 }, - DiagnosticUnnecessary = { fg = p.none }, - - -- diff - diffAdded = { fg = p.color4 }, - diffChanged = { fg = p.color5 }, - diffFile = { fg = p.color7 }, - diffIndexLine = { fg = p.color6 }, - diffLine = { fg = p.color5 }, - diffNewFile = { fg = p.color5 }, - diffOldFile = { fg = p.color5 }, - diffRemoved = { fg = p.color1 }, - - -- gitsigns: https://github.com/lewis6991/gitsigns.nvim - GitSignsAdd = { fg = p.color2 }, - GitSignsChange = { fg = p.color3 }, - GitSignsDelete = { fg = p.color1 }, - - -- indent-blankline.nvim: https://github.com/lukas-reineke/indent-blankline.nvim - IblIndent = { fg = p.cursorline }, - IblScope = { fg = p.color17 }, - - -- LSP - LspInfoFiletype = { fg = p.color15 }, - LspReferenceText = { bg = p.color4 }, - LspReferenceRead = { bg = p.color4 }, - LspReferenceWrite = { bg = p.color4 }, - LspInfoBorder = { link = "FloatBorder" }, - - -- lspsaga.nvim: https://github.com/glepnir/lspsaga.nvim - DefinitionCount = { fg = p.color6 }, - DefinitionIcon = { fg = p.color7 }, - LspFloatWinBorder = { link = "FloatBorder" }, - LspFloatWinNormal = { bg = p.black }, - LspSagaBorderTitle = { fg = p.color7 }, - LspSagaCodeActionBorder = { link = "FloatBorder" }, - LspSagaCodeActionContent = { fg = p.color6 }, - LspSagaCodeActionTitle = { fg = p.color7 }, - LspSagaDefPreviewBorder = {}, - LspSagaFinderSelection = { fg = p.color5 }, - LspSagaHoverBorder = { link = "FloatBorder" }, - LspSagaRenameBorder = { link = "FloatBorder" }, - LspSagaSignatureHelpBorder = { link = "FloatBorder" }, - ReferencesCount = { fg = p.color6 }, - ReferencesIcon = { fg = p.color7 }, - TargetWord = { fg = p.color7 }, - - -- Neogit: https://github.com/TimUntersberger/neogit - NeogitBranch = { fg = p.color6 }, - NeogitDiffAddHighlight = { fg = p.color4, bg = p.background }, - NeogitDiffContextHighlight = { bg = p.background, fg = p.foreground }, - NeogitDiffDeleteHighlight = { fg = p.color1, bg = p.background }, - NeogitHunkHeader = { bg = p.black, fg = p.foreground }, - NeogitHunkHeaderHighlight = { bg = p.comment, fg = p.color7 }, - NeogitRemote = { fg = p.color6 }, - - -- Neovim - healthError = { fg = p.color1 }, - healthSuccess = { fg = p.color4 }, - healthWarning = { fg = p.color3 }, - - -- nvim-cmp: https://github.com/hrsh7th/nvim-cmp - CmpDocumentationBorder = { fg = p.color17, bg = p.black }, - CmpItemAbbr = { fg = p.foreground, bg = "NONE" }, - CmpItemAbbrDeprecated = { fg = p.color2, bg = "NONE" }, - CmpItemAbbrMatch = { fg = p.color2, bg = "NONE" }, - CmpItemAbbrMatchFuzzy = { fg = p.color2, bg = "NONE" }, - CmpItemKind = { fg = p.color4, bg = p.black }, - CmpItemMenu = { fg = p.color2, bg = "NONE" }, - CmpItemKindFolder = { fg = p.color4 }, - CmpItemKindFile = { fg = p.color2 }, - CmpItemKindConstructor = { fg = p.color5 }, - CmpItemKindInterface = { fg = p.color5 }, - CmpItemKindReference = { fg = p.color5 }, - CmpItemKindConstant = { fg = p.color5 }, - CmpItemKindProperty = { fg = p.color5 }, - CmpItemKindModule = { fg = p.color5 }, - CmpItemKindClass = { fg = p.color5 }, - CmpItemKindField = { fg = p.color5 }, - CmpItemKindEvent = { fg = p.color5 }, - CmpItemKindSnippet = { fg = p.color4 }, - CmpItemKindKeyword = { fg = p.color4 }, - CmpItemKindValue = { fg = p.color4 }, - CmpItemKindOperator = { fg = p.color4 }, - CmpItemKindTypeParameter = { fg = p.foreground }, - CmpItemKindVariable = { fg = p.foreground }, - CmpItemKindText = { fg = p.foreground }, - CmpItemKindUnit = { fg = p.foreground }, - - -- Yank - YankyPut = { link = "Visual" }, - YankyYanked = { link = "Visual" }, - YankHighlight = { bg = p.cursorline }, - - -- Markdown - markdownCodeBlock = { fg = p.color7 }, - markdownCodeDelimeter = { fg = p.color7 }, - markdownUrl = { fg = p.color15 }, - markdownLink = { fg = p.foreground, underline = true }, - - -- nvim-tree.lua: https://github.com/nvim-tree/nvim-tree.lua - NvimTreeEmptyFolderName = { fg = p.foreground }, - NvimTreeEndOfBuffer = { fg = p.background, bg = p.background }, - NvimTreeEndOfBufferNC = { fg = p.background, bg = p.background }, - NvimTreeFolderIcon = { fg = p.color4, bg = p.background }, - NvimTreeFolderName = { fg = p.foreground }, - NvimTreeGitDeleted = { fg = p.color1 }, - NvimTreeGitDirty = { fg = p.color5 }, - NvimTreeGitNew = { fg = p.color4 }, - NvimTreeImageFile = { fg = p.foreground }, - NvimTreeIndentMarker = { fg = p.color0 }, - NvimTreeNormal = { fg = p.foreground, bg = p.background }, - NvimTreeNormalNC = { fg = p.foreground, bg = p.background }, - NvimTreeOpenedFolderName = { fg = p.foreground }, - NvimTreeRootFolder = { fg = p.color12 }, - NvimTreeSpecialFile = { fg = p.color5 }, - NvimTreeStatusLineNC = { bg = p.background, fg = p.color16 }, - NvimTreeSymlink = { fg = p.color3 }, - NvimTreeWinSeparator = { fg = p.black }, - - -- nvim-treesitter: https://github.com/nvim-treesitter/nvim-treesitter - ["@attribute"] = { fg = p.color4 }, - ["@boolean"] = { fg = p.color6 }, - ["@character"] = { fg = p.color4 }, - ["@comment"] = { fg = p.comment, style = options.styles.comments }, - ["@conditional"] = { fg = p.color4 }, - ["@constant"] = { fg = p.color6 }, - ["@constant.builtin"] = { fg = p.color4 }, - ["@constant.macro"] = { fg = p.color3 }, - ["@constructor"] = { fg = p.color4 }, - ["@exception"] = { fg = p.color11 }, - ["@field"] = { fg = p.color7 }, - ["@float"] = { link = "@number" }, - ["@function"] = { fg = p.color4, style = options.styles.functions }, - ["@function.builtin"] = { fg = p.color14 }, - ["@function.macro"] = { fg = p.color2 }, - ["@include"] = { fg = p.color3 }, - ["@keyword"] = { fg = p.color15, style = options.styles.keywords }, - ["@keyword.function"] = { fg = p.color4, style = options.styles.functions }, - ["@keyword.operator"] = { fg = p.color12 }, - ["@keyword.return"] = { fg = p.color4 }, - ["@label"] = { fg = p.color3 }, - ["@method"] = { fg = p.color12 }, - ["@namespace"] = { fg = p.color5 }, - ["@number"] = { fg = p.color15 }, - ["@operator"] = { fg = p.color7 }, - ["@parameter"] = { fg = p.color15 }, - ["@parameter.reference"] = { fg = p.color15 }, - ["@property"] = { fg = p.color5 }, - ["@punctuation.bracket"] = { fg = p.color7 }, - ["@punctuation.delimiter"] = { fg = p.color7 }, - ["@punctuation.special"] = { fg = p.color7 }, - ["@repeat"] = { fg = p.color13 }, - ["@string"] = { fg = p.color2 }, - ["@string.escape"] = { fg = p.color4 }, - ["@string.regex"] = { fg = p.color2 }, - ["@string.special"] = { fg = p.color4 }, - ["@symbol"] = { fg = p.color3 }, - ["@tag"] = { fg = p.color4 }, - ["@tag.attribute"] = { fg = p.color3 }, - ["@tag.delimiter"] = { fg = p.color7 }, - ["@text"] = { fg = p.color7 }, - ["@text.danger"] = { fg = p.color9 }, - ["@text.emphasis"] = { fg = p.color7, italic = true }, - ["@text.environment.name"] = { fg = p.color3 }, - ["@text.environtment"] = { fg = p.color5 }, - ["@text.literal"] = { fg = p.color2, italic = true }, - ["@text.math"] = { fg = p.color6 }, - ["@text.note"] = { fg = p.black, bg = p.color2 }, - ["@text.reference"] = { fg = p.color6 }, - ["@text.strike"] = { fg = p.color7, strikethrough = true }, - ["@text.strong"] = { fg = p.color7, bold = true }, - ["@text.title"] = { fg = p.color3, bold = true }, - ["@text.underline"] = { fg = p.color15, underline = true }, - ["@text.uri"] = { fg = p.color3, underline = true }, - ["@text.warning"] = { fg = p.color0, bg = p.color1 }, - ["@type"] = { fg = p.color4 }, - ["@type.builtin"] = { fg = p.color3 }, - ["@variable"] = { fg = p.color7, style = options.styles.variables }, - ["@variable.builtin"] = { fg = p.color4 }, - - -- LSP semantic tokens - -- ["@lsp.type.comment"] = { link = "@comment" }, - -- ["@lsp.type.enum"] = { link = "@type" }, - -- ["@lsp.type.interface"] = { link = "Identifier" }, - -- ["@lsp.type.keyword"] = { link = "@keyword" }, - -- ["@lsp.type.namespace"] = { link = "@namespace" }, - -- ["@lsp.type.parameter"] = { link = "@parameter" }, - -- ["@lsp.type.property"] = { link = "@property" }, - -- ["@lsp.type.variable"] = {}, -- use treesitter styles for regular variables - -- ["@lsp.typemod.method.defaultLibrary"] = { link = "@function.builtin" }, - -- ["@lsp.typemod.function.defaultLibrary"] = { link = "@function.builtin" }, - -- ["@lsp.typemod.operator.injected"] = { link = "@operator" }, - -- ["@lsp.typemod.string.injected"] = { link = "@string" }, - -- ["@lsp.typemod.variable.defaultLibrary"] = { link = "@variable.builtin" }, - -- ["@lsp.typemod.variable.injected"] = { link = "@variable" }, - - -- alpha.nvim: https://github.com/goolord/alpha-nvim - AlphaHeader = { fg = p.color2 }, - AlphaButton = { fg = p.color4 }, - AlphaFooter = { fg = p.color3 }, - AlphaShortcut = { fg = p.color5 }, - - -- dashboard.nvim: https://github.com/nvimdev/dashboard-nvim - DashboardHeader = { fg = p.color2 }, - DashboardCenter = { fg = p.color4 }, - DashboardFooter = { fg = p.color3 }, - DashboardShortcut = { fg = p.color5 }, - - -- telescope.nvim: https://github.com/nvim-telescope/telescope.nvim - TelescopeMatching = { fg = p.color2 }, - TelescopeSelection = { fg = p.color2, bg = p.bg }, - TelescopeMultiSelection = { bg = p.color16 }, - TelescopePromptTitle = { fg = p.background, bg = p.color2 }, - TelescopePreviewLine = { bg = p.background }, - TelescopePromptPrefix = { fg = p.color2, bg = p.cursorline }, - TelescopePromptBorder = { fg = p.cursorline, bg = p.cursorline }, - TelescopePromptNormal = { fg = p.fg, bg = p.cursorline }, - TelescopeResultsTitle = { fg = p.color16, bg = p.color16 }, - TelescopeResultsBorder = { fg = p.color16, bg = p.color16 }, - TelescopeResultsNormal = { fg = p.foreground, bg = p.color16 }, - TelescopePreviewTitle = { fg = p.cursorline, bg = p.color3 }, - TelescopePreviewBorder = { fg = p.cursorline, bg = p.cursorline }, - TelescopePreviewNormal = { fg = p.foreground, bg = p.cursorline }, - - -- trouble.nvim: https://github.com/folke/trouble.nvim - LspTroubleCount = { fg = p.color6, bg = p.foreground }, - LspTroubleNormal = { fg = p.foreground, bg = p.background }, - LspTroubleText = { fg = p.foreground }, - - -- vim-gitgutter: https://github.com/airblade/vim-gitgutter - GitGutterAdd = { fg = p.color2 }, - GitGutterChange = { fg = p.color3 }, - GitGutterDelete = { fg = p.color1 }, - } - - theme.terminal_colors = { - terminal_color_0 = p.color0, - terminal_color_1 = p.color1, - terminal_color_2 = p.color2, - terminal_color_3 = p.color3, - terminal_color_4 = p.color4, - terminal_color_5 = p.color5, - terminal_color_6 = p.color6, - terminal_color_7 = p.color7, - terminal_color_8 = p.color8, - terminal_color_9 = p.color9, - terminal_color_10 = p.color10, - terminal_color_11 = p.color11, - terminal_color_12 = p.color12, - terminal_color_13 = p.color13, - terminal_color_14 = p.color14, - terminal_color_15 = p.color15, - } - - for option, value in pairs(theme.terminal_colors) do - vim.g[option] = value - end - - theme.highlights = vim.tbl_extend("force", {}, theme.highlights, options.highlights) - - -- Hide all semantic highlights - for _, group in ipairs(vim.fn.getcompletion("@lsp", "highlight")) do - vim.api.nvim_set_hl(0, group, {}) - end - - -- Set the highlights - for group, colors in pairs(theme.highlights) do - if colors.style then - if type(colors.style) == "table" then - colors = vim.tbl_extend("force", colors, colors.style) - end - colors.style = nil - end - vim.api.nvim_set_hl(0, group, colors) - end -end - -return theme diff --git a/update_arch.sh b/update_arch.sh index d6db2e0..c1a5254 100755 --- a/update_arch.sh +++ b/update_arch.sh @@ -10,7 +10,7 @@ HOSTNAME=$(hostname | tr '[:lower:]' '[:upper:]') # Declare associative array for roles declare -A ROLES -for role in LAB BT GAME VR DESKTOP_BASE DESKTOP_WORK CODE NVIDIA_GPU NVIDIA_1080_GPU TERMINAL HYPERLAND; do +for role in MUSIC LAB BT GAME VR DESKTOP_BASE DESKTOP_WORK CODE NVIDIA_GPU NVIDIA_1080_GPU TERMINAL HYPERLAND; do ROLES["$role"]="no" done @@ -22,6 +22,7 @@ CMBOX) ROLES[CODE]="yes" ROLES[TERMINAL]="yes" ROLES[HYPERLAND]="yes" + ROLES[MUSIC]="yes" ;; STEAMBOX) ROLES[GAME]="yes" @@ -76,18 +77,12 @@ sleep 1 # Create backup/snapshot if pacman -Qs timeshift >/dev/null; then - # CONFIG_FILE="/etc/timeshift/timeshift.json" - # if [ -f "$CONFIG_FILE" ]; then - # BTRFS_MODE=$(jq '.btrfs_mode' "$CONFIG_FILE") - # if [ "$BTRFS_MODE" == '"true"' ]; then printf -- '\033[33m Creating backup/snapshot\n\033[37m' sudo timeshift --create --comments "Update script" - # fi - # fi fi # Enable multilib (if applicable) -if [ "${ROLES[GAME]}" == "yes" ]; then +if [ "${ROLES[GAME]}" == "yes" ] || [ "${ROLES[MUSIC]}" == "yes" ]; then if ! grep -q "^\[multilib\]" /etc/pacman.conf; then printf -- '\033[33m Enabling multilib\n\033[37m' sudo tee -a /etc/pacman.conf >/dev/null </dev/null; then sudo pacman --noconfirm -R gnu-free-fonts fi - sudo pacman --noconfirm --needed -S dysk lazygit alacritty btop ranger tmux fd neovim ttf-nerd-fonts-symbols ttf-roboto-mono-nerd gdu ruby bottom go php luarocks composer jdk-openjdk julia nodejs npm + sudo pacman --noconfirm --needed -S dysk lazygit alacritty btop ranger tmux fd ttf-nerd-fonts-symbols ttf-roboto-mono-nerd gdu ruby bottom go php luarocks composer jdk-openjdk julia nodejs npm + yay --noconfirm -S --needed --aur neovim-git-bin sudo npm install -g neovim @@ -332,12 +328,6 @@ EOT sudo setcap cap_sys_admin+p $(readlink -f $(which sunshine)) sudo systemctl daemon-reload - if [ "$HOSTNAME" == "CMBOX" ]; then - printf -- '\033[33m Installing CMBOX specific utilities\n\033[37m' - sudo pacman -S --noconfirm --needed onnxruntime qt6-serialport cameractrls qt6-5compat - yay --noconfirm -S --needed --aur openmpi - # yay --noconfirm -S --needed --aur opentrack-git - fi fi if [ "${ROLES[DESKTOP_WORK]}" == "yes" ]; then @@ -349,6 +339,38 @@ if [ "${ROLES[DESKTOP_WORK]}" == "yes" ]; then flatpak install -y flathub org.gimp.GIMP fi +# Install music production utility +if [ "${ROLES[MUSIC]}" == "yes" ]; then + sudo pacman -U --noconfirm https://archive.archlinux.org/packages/w/wine-staging/wine-staging-9.21-1-x86_64.pkg.tar.zst + PKG="wine-staging" + # Check if package is already in IgnorePkg + if ! grep -q "^IgnorePkg.*\b$PKG\b" /etc/pacman.conf; then + sudo sed -i "/^#IgnorePkg/ s/^#//" /etc/pacman.conf # uncomment if commented + sudo sed -i "/^IgnorePkg/ s/$/ $PKG/" /etc/pacman.conf # append package name + echo "Added $PKG to IgnorePkg in /etc/pacman.conf" + else + echo "$PKG is already in IgnorePkg." + fi + yay -Rdd pulseaudio pulseaudio-alsa pulseaudio-jack jack2 + sudo pacman -S --noconfirm --needed pipewire pipewire-jack pipewire-alsa pipewire-pulse gamemode + sudo pacman -S --noconfirm --needed pipewire-tools qpwgraph realtime-privileges yabridge yabridgectl + yay --noconfirm -S --needed --aur bitwig-studio + + sudo usermod -a -G realtime,audio,gamemode $USER + + sudo tee /etc/security/limits.d/99-pipewire.conf <<'EOF' +@audio soft rtprio 95 +@audio soft memlock unlimited +@audio hard rtprio 95 +@audio hard memlock unlimited +EOF + + systemctl --user --now disable pulseaudio.{socket,service} + systemctl --user mask pulseaudio + systemctl --user --now enable pipewire{,-pulse}.{socket,service} filter-chain.service + pw-metadata -n settings 0 clock.min-quantum 128 +fi + # Install game utility if [ "${ROLES[GAME]}" == "yes" ]; then printf -- '\033[33m Installing game utilities\n\033[37m'