diff --git a/README.md b/README.md new file mode 100644 index 0000000..99d9d72 --- /dev/null +++ b/README.md @@ -0,0 +1,9 @@ +# Personal Dotfiles :3 + +## Installation + +Execute the following command: + +```bash +curl -L https://codeberg.org/aleidk/dots/raw/branch/main/setup.sh | bash +``` diff --git a/config/nvim/lua/aleidk/keymaps.lua b/config/nvim/lua/aleidk/keymaps.lua index 20f4ac0..6f6e0f0 100644 --- a/config/nvim/lua/aleidk/keymaps.lua +++ b/config/nvim/lua/aleidk/keymaps.lua @@ -1,5 +1,9 @@ -- [[ Basic Keymaps ]] +function MAP(mode, l, r, desc) + vim.keymap.set(mode, l, r, { desc = desc, silent = true }) +end + local function default(desc) return { silent = true, diff --git a/config/nvim/lua/aleidk/plugins/bufferline.lua b/config/nvim/lua/aleidk/plugins/bufferline.lua index bc3afde..c6d4130 100644 --- a/config/nvim/lua/aleidk/plugins/bufferline.lua +++ b/config/nvim/lua/aleidk/plugins/bufferline.lua @@ -3,23 +3,23 @@ return { event = "VeryLazy", after = "onedark", keys = { - { "bp", "BufferLineTogglePin", desc = "Toggle pin" }, + { "bp", "BufferLineTogglePin", desc = "Toggle pin" }, { "bP", "BufferLineGroupClose ungrouped", desc = "Delete non-pinned buffers" }, - { "", "BufferLineCyclePrev", desc = "Prev buffer" }, - { "", "BufferLineCycleNext", desc = "Next buffer" }, + { "", "BufferLineCyclePrev", desc = "Prev buffer" }, + { "", "BufferLineCycleNext", desc = "Next buffer" }, }, dependencies = { { "echasnovski/mini.bufremove", - -- stylua: ignore - keys = { - { "bd", function() require("mini.bufremove").delete(0, false) end, desc = "Delete Buffer" }, - { "bD", function() require("mini.bufremove").delete(0, true) end, desc = "Delete Buffer (Force)" }, - }, + -- stylua: ignore + keys = { + { "bd", function() require("mini.bufremove").delete(0, false) end, desc = "Delete Buffer" }, + { "bD", function() require("mini.bufremove").delete(0, true) end, desc = "Delete Buffer (Force)" }, + }, }, }, config = function() - opts = { + local opts = { highlights = { separator = { bg = "NONE" } }, options = { -- FIXME: Doesn't work with onedark pro colorscheme @@ -28,13 +28,13 @@ return { close_command = function(n) require("mini.bufremove").delete(n, false) end, - -- stylua: ignore - right_mouse_command = function(n) require("mini.bufremove").delete(n, false) end, + -- stylua: ignore + right_mouse_command = function(n) require("mini.bufremove").delete(n, false) end, diagnostics = "nvim_lsp", diagnostics_indicator = function(_, _, diag) local icons = require("aleidk.constants").icons.diagnostics local ret = (diag.error and icons.Error .. diag.error .. " " or "") - .. (diag.warning and icons.Warn .. diag.warning or "") + .. (diag.warning and icons.Warn .. diag.warning or "") return vim.trim(ret) end, offsets = { diff --git a/config/nvim/lua/aleidk/plugins/init.lua b/config/nvim/lua/aleidk/plugins/init.lua index b5ec46e..d2858a7 100644 --- a/config/nvim/lua/aleidk/plugins/init.lua +++ b/config/nvim/lua/aleidk/plugins/init.lua @@ -18,10 +18,10 @@ return { -- Useful status updates for LSP -- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})` - { "j-hui/fidget.nvim", opts = {} }, + { "j-hui/fidget.nvim", opts = {} }, -- Additional lua configuration, makes nvim stuff amazing! - { "folke/neodev.nvim", opts = {} }, + { "folke/neodev.nvim", opts = {} }, }, }, @@ -56,4 +56,12 @@ return { }, }, }, + { + "RRethy/vim-illuminate", + event = { "BufReadPost", "BufNewFile" }, + opts = { delay = 200 }, + config = function(_, opts) + require("illuminate").configure(opts) + end, + }, } diff --git a/config/nvim/lua/aleidk/plugins/trouble.lua b/config/nvim/lua/aleidk/plugins/trouble.lua index 57271e1..505f611 100644 --- a/config/nvim/lua/aleidk/plugins/trouble.lua +++ b/config/nvim/lua/aleidk/plugins/trouble.lua @@ -1,32 +1,16 @@ return { "folke/trouble.nvim", - -- dependencies = { "kyazdani42/nvim-web-devicons" }, + cmd = { "TroubleToggle", "Trouble" }, config = function() require("trouble").setup({ mode = "document_diagnostics", - action_keys = { -- key mappings for actions in the trouble list - -- map to {} to remove a mapping, for example: - -- close = {}, - close = "q", -- close the list - cancel = "", -- cancel the preview and get back to your last window / buffer / cursor - refresh = "r", -- manually refresh - jump = { "", "" }, -- jump to the diagnostic or open / close folds - open_split = { "s" }, -- open buffer in new split - open_vsplit = { "v" }, -- open buffer in new vsplit - open_tab = { "t" }, -- open buffer in new tab - jump_close = { "o" }, -- jump to the diagnostic and close the list - toggle_mode = "m", -- toggle between "workspace" and "document" diagnostics mode - toggle_preview = "P", -- toggle auto_preview - hover = "K", -- opens a small popup with the full multiline message - preview = "p", -- preview the diagnostic location - close_folds = { "zM", "zm" }, -- close all folds - open_folds = { "zR", "zr" }, -- open all folds - toggle_fold = { "zA", "za" }, -- toggle fold of current file - previous = "k", -- previous item - next = "j", -- next item + action_keys = { + open_split = "s", + open_vsplit = "v", + open_tab = "t", }, }) - vim.keymap.set("n", "fd", "TroubleToggle", { silent = true, desc = "Search diagnostics" }) + MAP("n", "fd", "TroubleToggle", { silent = true, desc = "Search diagnostics" }) end, } diff --git a/config/zsh/functions/fedora.zsh b/config/zsh/functions/fedora.zsh index 7edb325..bad34af 100644 --- a/config/zsh/functions/fedora.zsh +++ b/config/zsh/functions/fedora.zsh @@ -5,10 +5,19 @@ dnf-save-install() { sudo dnf install -y $(cat "$DOTS/exports/dnf.txt") } +dnf-load-export() { + while read -r line; do + sudo dnf copr enable -y "$line" + done <"$DOTS/exports/copr.txt" + + sudo dnf install -y $(cat "$DOTS/exports/dnf.txt") +} + upgrade() { sudo dnf upgrade --refresh -y } +# where did I get this? mayor-upgrade() { if [[ $(dnf check-update -q) ]]; then echo "There are updates pending, update and reboot? [y/N]" diff --git a/exports/dnf.txt b/exports/dnf.txt index 99b9174..b7f15ff 100644 --- a/exports/dnf.txt +++ b/exports/dnf.txt @@ -1,3 +1,4 @@ +bat dnf-plugin-system-upgrade duf exa