diff --git a/.config/aliasrc b/.config/aliasrc index 90a9512..201ca47 100644 --- a/.config/aliasrc +++ b/.config/aliasrc @@ -7,6 +7,9 @@ background() { for ((i=2;i<=$#;i++)); do; ${@[1]} ${@[$i]} &> /dev/null &| ; don alias ":wq"="exit" alias ":q"="exit" +# cat +alias cat="bat" + # cd alias ".."="cd .." alias "..."="cd ../.." @@ -134,6 +137,7 @@ alias weather="curl wttr.in" # wget alias wget="wget --hsts-file=$XDG_CACHE_HOME/wget-hsts" +alias wget2c="aria2c" # yay alias yay="yay --sudoloop --noredownload --norebuild --combinedupgrade" diff --git a/.config/easyeffects/input/Fifine K688 - Chat.json b/.config/easyeffects/export/input/Fifine K688 - Chat.json similarity index 100% rename from .config/easyeffects/input/Fifine K688 - Chat.json rename to .config/easyeffects/export/input/Fifine K688 - Chat.json diff --git a/.config/easyeffects/input/Fifine K688 - Voice.json b/.config/easyeffects/export/input/Fifine K688 - Voice.json similarity index 100% rename from .config/easyeffects/input/Fifine K688 - Voice.json rename to .config/easyeffects/export/input/Fifine K688 - Voice.json diff --git a/.config/easyeffects/output/Beyerdynamic DT 770 Pro (80 Ohm) + W-Shape.json b/.config/easyeffects/export/output/Beyerdynamic DT 770 Pro (80 Ohm) + W-Shape.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT 770 Pro (80 Ohm) + W-Shape.json rename to .config/easyeffects/export/output/Beyerdynamic DT 770 Pro (80 Ohm) + W-Shape.json diff --git a/.config/easyeffects/output/Beyerdynamic DT 770 Pro (80 Ohm).json b/.config/easyeffects/export/output/Beyerdynamic DT 770 Pro (80 Ohm).json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT 770 Pro (80 Ohm).json rename to .config/easyeffects/export/output/Beyerdynamic DT 770 Pro (80 Ohm).json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Analytical.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Analytical.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Analytical.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Analytical.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Balanced.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Balanced.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Balanced.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Balanced.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Bright.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Bright.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Bright.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Bright.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Dark.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Dark.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Dark.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Dark.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Extra Bass.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Extra Bass.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Extra Bass.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Extra Bass.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Extra Treble.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Extra Treble.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Extra Treble.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Extra Treble.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + V-Shape.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + V-Shape.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + V-Shape.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + V-Shape.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + W-Shape.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + W-Shape.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + W-Shape.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + W-Shape.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Warm.json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Warm.json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour) + Warm.json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour) + Warm.json diff --git a/.config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour).json b/.config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour).json similarity index 100% rename from .config/easyeffects/output/Beyerdynamic DT1770 Pro (Velour).json rename to .config/easyeffects/export/output/Beyerdynamic DT1770 Pro (Velour).json diff --git a/.config/easyeffects/output/Flat.json b/.config/easyeffects/export/output/Flat.json similarity index 100% rename from .config/easyeffects/output/Flat.json rename to .config/easyeffects/export/output/Flat.json diff --git a/.config/easyeffects/output/HIFIMAN HE400se (stealth magnet) + W-Shape.json b/.config/easyeffects/export/output/HIFIMAN HE400se (stealth magnet) + W-Shape.json similarity index 100% rename from .config/easyeffects/output/HIFIMAN HE400se (stealth magnet) + W-Shape.json rename to .config/easyeffects/export/output/HIFIMAN HE400se (stealth magnet) + W-Shape.json diff --git a/.config/easyeffects/output/HIFIMAN HE400se (stealth magnet).json b/.config/easyeffects/export/output/HIFIMAN HE400se (stealth magnet).json similarity index 100% rename from .config/easyeffects/output/HIFIMAN HE400se (stealth magnet).json rename to .config/easyeffects/export/output/HIFIMAN HE400se (stealth magnet).json diff --git a/.config/easyeffects/output/TANGZU Wan'er S.G + W-Shape.json b/.config/easyeffects/export/output/TANGZU Wan'er S.G + W-Shape.json similarity index 100% rename from .config/easyeffects/output/TANGZU Wan'er S.G + W-Shape.json rename to .config/easyeffects/export/output/TANGZU Wan'er S.G + W-Shape.json diff --git a/.config/easyeffects/output/TANGZU Wan'er S.G.json b/.config/easyeffects/export/output/TANGZU Wan'er S.G.json similarity index 100% rename from .config/easyeffects/output/TANGZU Wan'er S.G.json rename to .config/easyeffects/export/output/TANGZU Wan'er S.G.json diff --git a/.config/easyeffects/output/Tin HiFi T2 Plus + W-Shape.json b/.config/easyeffects/export/output/Tin HiFi T2 Plus + W-Shape.json similarity index 100% rename from .config/easyeffects/output/Tin HiFi T2 Plus + W-Shape.json rename to .config/easyeffects/export/output/Tin HiFi T2 Plus + W-Shape.json diff --git a/.config/easyeffects/output/Tin HiFi T2 Plus.json b/.config/easyeffects/export/output/Tin HiFi T2 Plus.json similarity index 100% rename from .config/easyeffects/output/Tin HiFi T2 Plus.json rename to .config/easyeffects/export/output/Tin HiFi T2 Plus.json diff --git a/.config/fontconfig/fonts.conf b/.config/fontconfig/fonts.conf index c911ac0..82fc6b8 100644 --- a/.config/fontconfig/fonts.conf +++ b/.config/fontconfig/fonts.conf @@ -19,7 +19,7 @@ Joy Pixels - Font Awesome 6 Free + Symbola @@ -34,7 +34,7 @@ Joy Pixels - Font Awesome 6 Free + Symbola @@ -49,7 +49,7 @@ Joy Pixels - Font Awesome 6 Free + Symbola diff --git a/.config/mimeapps.list b/.config/mimeapps.list index ee17c7d..6c812a6 100644 --- a/.config/mimeapps.list +++ b/.config/mimeapps.list @@ -24,6 +24,8 @@ message/rfc822=mail.desktop x-scheme-handler/msteams=teams.desktop x-scheme-handler/tonsite=org.telegram.desktop.desktop inode/directory=file-browser.desktop +x-scheme-handler/betterdiscord=discord.desktop +x-scheme-handler/discord=vesktop.desktop [Added Associations] application/vnd.openxmlformats-officedocument.wordprocessingml.document=libreoffice-writer.desktop; diff --git a/.config/nvim/after/ftplugin/csv.lua b/.config/nvim/after/ftplugin/csv.lua new file mode 100644 index 0000000..8ada645 --- /dev/null +++ b/.config/nvim/after/ftplugin/csv.lua @@ -0,0 +1,8 @@ +vim.api.nvim_create_autocmd({ 'VimEnter' }, + { + callback = function() + require("csvview").enable() + end + }) + +vim.o.textwidth = 0 diff --git a/.config/nvim/after/ftplugin/markdown.lua b/.config/nvim/after/ftplugin/markdown.lua index 66569cd..491c552 100644 --- a/.config/nvim/after/ftplugin/markdown.lua +++ b/.config/nvim/after/ftplugin/markdown.lua @@ -36,3 +36,6 @@ vim.o.textwidth = 100 -- frabjous/knap vim.keymap.set('n', 'p', require("knap").toggle_autopreviewing, { noremap = true }) + +-- benlubas/molten-nvim +require("quarto").activate() diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json index 43a4554..e9bc3d8 100644 --- a/.config/nvim/lazy-lock.json +++ b/.config/nvim/lazy-lock.json @@ -1,69 +1,81 @@ { - "action-hints.nvim": { "branch": "main", "commit": "ab10fef255dd4bc933c92d8f9969828f2f856e71" }, + "action-hints.nvim": { "branch": "main", "commit": "ac72c23c2e901084e0c08a743942d8d7b8c560de" }, "barbecue": { "branch": "main", "commit": "cd7e7da622d68136e13721865b4d919efd6325ed" }, - "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, - "cmp-nvim-lsp": { "branch": "main", "commit": "39e2eda76828d88b773cc27a3f61d2ad782c922d" }, - "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, + "blink.download": { "branch": "main", "commit": "86361b98f3c8317904a08e3bd12cf3cdcbe3e925" }, + "blink.pairs": { "branch": "main", "commit": "d8bf802cca951f0a3b72ddeed21bc5a1d5353f65" }, + "cmp-buffer": { "branch": "main", "commit": "b74fab3656eea9de20a9b8116afa3cfc4ec09657" }, + "cmp-nvim-lsp": { "branch": "main", "commit": "bd5a7d6db125d4654b50eeae9f5217f24bb22fd3" }, + "cmp-path": { "branch": "main", "commit": "c642487086dbd9a93160e1679a1327be111cbc25" }, "cmp-under-comparator": { "branch": "master", "commit": "6857f10272c3cfe930cece2afa2406e1385bfef8" }, - "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, + "cmp_luasnip": { "branch": "master", "commit": "98d9cb5c2c38532bd9bdb481067b20fea8f32e90" }, "comment.nvim": { "branch": "master", "commit": "e30b7f2008e52442154b66f7c519bfd2f1e32acb" }, - "conform.nvim": { "branch": "master", "commit": "40d4e98fcc3e6f485f0e8924c63734bc7e305967" }, + "conform.nvim": { "branch": "master", "commit": "fbcb4fa7f34bfea9be702ffff481a8e336ebf6ed" }, "cpsm": { "branch": "master", "commit": "1a5fc1b6169bb80c29b0b986130c4f3f1a9ed82e" }, + "csvview.nvim": { "branch": "main", "commit": "bbab4c2f808fd8e11ec8dfdd128251aadba566a1" }, "diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" }, + "edgy.nvim": { "branch": "main", "commit": "8bfd2808994a988c975694122f68624b8a219f5f" }, "fterm.nvim": { "branch": "master", "commit": "d1320892cc2ebab472935242d9d992a2c9570180" }, - "fzy-lua-native": { "branch": "master", "commit": "820f745b7c442176bcc243e8f38ef4b985febfaf" }, - "git-blame.nvim": { "branch": "master", "commit": "2883a7460f611c2705b23f12d58d398d5ce6ec00" }, - "gitsigns.nvim": { "branch": "main", "commit": "863903631e676b33e8be2acb17512fdc1b80b4fb" }, - "goto-preview": { "branch": "main", "commit": "1519ea3512828c944eed5b2bbb66a8f8deb92447" }, - "indent-blankline.nvim": { "branch": "master", "commit": "e7a4442e055ec953311e77791546238d1eaae507" }, - "knap": { "branch": "main", "commit": "0040760bb504a713ea5988c7c490a15faf477c57" }, - "lazy.nvim": { "branch": "main", "commit": "1159bdccd8910a0fd0914b24d6c3d186689023d9" }, - "leap.nvim": { "branch": "main", "commit": "c6bfb191f1161fbabace1f36f578a20ac6c7642c" }, - "lsp_signature.nvim": { "branch": "master", "commit": "fc38521ea4d9ec8dbd4c2819ba8126cea743943b" }, - "lspkind-nvim": { "branch": "master", "commit": "59c3f419af48a2ffb2320cea85e44e5a95f71664" }, - "lualine.nvim": { "branch": "master", "commit": "b431d228b7bbcdaea818bdc3e25b8cdbe861f056" }, + "fzy-lua-native": { "branch": "master", "commit": "9d720745d5c2fb563c0d86c17d77612a3519c506" }, + "git-blame.nvim": { "branch": "main", "commit": "9874ec1ec8bc53beb33b7cd82c092b85271a578b" }, + "gitsigns.nvim": { "branch": "main", "commit": "1ee5c1fd068c81f9dd06483e639c2aa4587dc197" }, + "goto-preview": { "branch": "main", "commit": "cf561d10b4b104db20375c48b86cf36af9f96e00" }, + "image.nvim": { "branch": "master", "commit": "446a8a5cc7a3eae3185ee0c697732c32a5547a0b" }, + "indent-blankline.nvim": { "branch": "master", "commit": "005b56001b2cb30bfa61b7986bc50657816ba4ba" }, + "jupytext.nvim": { "branch": "main", "commit": "c8baf3ad344c59b3abd461ecc17fc16ec44d0f7b" }, + "knap": { "branch": "main", "commit": "7db44d0bb760120142cc1e8f43e44976de59c2f6" }, + "lazy.nvim": { "branch": "main", "commit": "1ea3c4085785f460fb0e46d2fe1ee895f5f9e7c1" }, + "leap.nvim": { "branch": "main", "commit": "f5fe479e20d809df7b54ad53142c2bdb0624c62a" }, + "logger.nvim": { "branch": "main", "commit": "63dd10c9b9a159fd6cfe08435d9606384ff103c5" }, + "lsp_signature.nvim": { "branch": "master", "commit": "b58cca003d1d3311213d6db0352f58d8e57bfff0" }, + "lspkind-nvim": { "branch": "master", "commit": "3ddd1b4edefa425fda5a9f95a4f25578727c0bb3" }, + "lualine.nvim": { "branch": "master", "commit": "b8c23159c0161f4b89196f74ee3a6d02cdc3a955" }, "luasnip": { "branch": "master", "commit": "03c8e67eb7293c404845b3982db895d59c0d1538" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "25c11854aa25558ee6c03432edfa0df0217324be" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "6bdb14f230de0904229ec367b410fb817e59b072" }, "mason-null-ls.nvim": { "branch": "main", "commit": "de19726de7260c68d94691afb057fa73d3cc53e7" }, - "mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" }, - "modes.nvim": { "branch": "main", "commit": "326cff3282419b3bcc745061978c1e592cae055d" }, - "none-ls.nvim": { "branch": "main", "commit": "6bdd9b3364e12ffb346ac224db3df37de0b1429b" }, - "nvim-autopairs": { "branch": "master", "commit": "ee297f215e95a60b01fde33275cc3c820eddeebe" }, - "nvim-cmp": { "branch": "main", "commit": "ae644feb7b67bf1ce4260c231d1d4300b19c6f30" }, + "mason.nvim": { "branch": "main", "commit": "ad7146aa61dcaeb54fa900144d768f040090bff0" }, + "modes.nvim": { "branch": "main", "commit": "0932ba4e0bdc3457ac89a8aeed4d56ca0b36977a" }, + "molten-nvim": { "branch": "main", "commit": "a286aa914d9a154bc359131aab788b5a077a5a99" }, + "none-ls.nvim": { "branch": "main", "commit": "5cf63841461b49989972d35bf886e076a1ab3649" }, + "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, + "nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" }, "nvim-colorizer.lua": { "branch": "master", "commit": "6ed09146ee637006367b5e225be6208a1ea02579" }, - "nvim-docs-view": { "branch": "master", "commit": "365593534e0acd762bfddce6e8313315ffa4fa36" }, - "nvim-hlslens": { "branch": "main", "commit": "07afd4dd14405ad14b142a501a3abea6ae44b21b" }, - "nvim-lspconfig": { "branch": "master", "commit": "d141895d1d9f41048fff201d62a2d6e96d299e32" }, - "nvim-navic": { "branch": "master", "commit": "8649f694d3e76ee10c19255dece6411c29206a54" }, - "nvim-scrollbar": { "branch": "main", "commit": "d09f14aa16c9f2748e77008f9da7b1f76e4e7b85" }, - "nvim-surround": { "branch": "main", "commit": "ec2dc7671067e0086cdf29c2f5df2dd909d5f71f" }, - "nvim-tree.lua": { "branch": "master", "commit": "1c9553a19f70df3dcb171546a3d5e034531ef093" }, - "nvim-treesitter": { "branch": "master", "commit": "5a2ff8b7ca5470b1011ed82ef3fdd53139ffc467" }, - "nvim-ts-autotag": { "branch": "main", "commit": "e239a560f338be31337e7abc3ee42515daf23f5e" }, - "nvim-ts-rainbow": { "branch": "master", "commit": "ef95c15a935f97c65a80e48e12fe72d49aacf9b9" }, - "nvim-ufo": { "branch": "main", "commit": "203c9f434feec57909ab4b1e028abeb3349b7847" }, - "nvim-web-devicons": { "branch": "master", "commit": "19d257cf889f79f4022163c3fbb5e08639077bd8" }, + "nvim-docs-view": { "branch": "master", "commit": "5676cc094d426edd39134b1eefca2cab441cca8a" }, + "nvim-hlslens": { "branch": "main", "commit": "6d42444785ea0d41555d033485910c5e78916f3b" }, + "nvim-lspconfig": { "branch": "master", "commit": "cc2f5f2fa28d240574808e78847978ed6ef20d2a" }, + "nvim-navic": { "branch": "master", "commit": "f887d794a0f4594882814d7780980a949200a238" }, + "nvim-scrollbar": { "branch": "main", "commit": "5b103ef0fd2e8b9b4be3878ed38d224522192c6c" }, + "nvim-surround": { "branch": "main", "commit": "a868c256c861044beb9794b4dd126480dcdfbdad" }, + "nvim-tree.lua": { "branch": "master", "commit": "e397756d2a79d74314ea4cd3efc41300e91c0ff0" }, + "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, + "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, + "nvim-ufo": { "branch": "main", "commit": "72d54c31079d38d8dfc5456131b1d0fb5c0264b0" }, + "nvim-web-devicons": { "branch": "master", "commit": "b8221e42cf7287c4dcde81f232f58d7b947c210d" }, "nvim-yarp": { "branch": "master", "commit": "bb5f5e038bfe119d3b777845a76b0b919b35ebc8" }, - "plenary.nvim": { "branch": "master", "commit": "2d9b06177a975543726ce5c73fca176cedbffe9d" }, + "ogpt.nvim": { "branch": "main", "commit": "0fae02db8cb07391f86c3dbe807f62190a2d997f" }, + "otter.nvim": { "branch": "main", "commit": "fc0aa35b1985077d11a20ddf4006bf40f2cd7397" }, + "outline.nvim": { "branch": "main", "commit": "6b62f73a6bf317531d15a7ae1b724e85485d8148" }, + "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "popup-menu.nvim": { "branch": "master", "commit": "b618bd0c824a20417d845fa0022327228e6988a2" }, "projections.nvim": { "branch": "pre_release", "commit": "889914169fa1f5c00fb8659653b5a8330fb223e6" }, "promise-async": { "branch": "main", "commit": "119e8961014c9bfaf1487bf3c2a393d254f337e2" }, + "quarto-nvim": { "branch": "main", "commit": "0e9491509b38efbd83d3f41dbfacc7fc4bd40191" }, "renamer.nvim": { "branch": "master", "commit": "1614d466df53899f11dd5395eaac3c09a275c384" }, + "rustaceanvim": { "branch": "master", "commit": "12504405821c05874d2d1f6b5ec919f9808e2c99" }, "spelunker.vim": { "branch": "master", "commit": "a0bc530f62798bbe053905555a4aa9ed713485eb" }, - "symbols-outline.nvim": { "branch": "master", "commit": "564ee65dfc9024bdde73a6621820866987cbb256" }, "tabular": { "branch": "master", "commit": "12437cd1b53488e24936ec4b091c9324cafee311" }, "tccs.nvim": { "branch": "master", "commit": "e50c1504286b5ee2700961a600f26c9b338bd042" }, + "telescope-words.nvim": { "branch": "main", "commit": "295d51fe1e525fee18c0c164ad0ae5fb23273aa0" }, "telescope.nvim": { "branch": "master", "commit": "776b509f80dd49d8205b9b0d94485568236d1192" }, - "tidy.nvim": { "branch": "main", "commit": "58fcc63de53840fa78946e4161e8883e67213f92" }, - "todo-comments.nvim": { "branch": "main", "commit": "ae0a2afb47cf7395dc400e5dc4e05274bf4fb9e0" }, - "trouble.nvim": { "branch": "main", "commit": "254145ffd528b98eb20be894338e2d5c93fa02c2" }, - "undotree": { "branch": "master", "commit": "78b5241191852ffa9bb5da5ff2ee033160798c3b" }, + "tidy.nvim": { "branch": "main", "commit": "c8cd0e6e0108da25c3e10c3f33d8c03b3d8806f1" }, + "todo-comments.nvim": { "branch": "main", "commit": "19d461ddd543e938eb22505fb03fa878800270b6" }, + "trouble.nvim": { "branch": "main", "commit": "c098362fe603d3922095e7db595961e020bdf2d0" }, + "undotree": { "branch": "master", "commit": "0f1c9816975b5d7f87d5003a19c53c6fd2ff6f7f" }, "vim-abolish": { "branch": "master", "commit": "dcbfe065297d31823561ba787f51056c147aa682" }, "vim-hug-neovim-rpc": { "branch": "master", "commit": "93ae38792bc197c3bdffa2716ae493c67a5e7957" }, - "vim-illuminate": { "branch": "master", "commit": "5eeb7951fc630682c322e88a9bbdae5c224ff0aa" }, + "vim-illuminate": { "branch": "master", "commit": "0d1e93684da00ab7c057410fecfc24f434698898" }, "vim-markdown": { "branch": "master", "commit": "8f6cb3a6ca4e3b6bcda0730145a0b700f3481b51" }, "vim-renamer": { "branch": "master", "commit": "9c6346eb4556cf2d8ca55de6969247ab14fe2383" }, - "which-key.nvim": { "branch": "main", "commit": "8badb359f7ab8711e2575ef75dfe6fbbd87e4821" }, + "which-key.nvim": { "branch": "main", "commit": "b4177e3eaf15fe5eb8357ebac2286d488be1ed00" }, "wilder.nvim": { "branch": "master", "commit": "679f348dc90d80ff9ba0e7c470c40a4d038dcecf" }, "winshift.nvim": { "branch": "main", "commit": "37468ed6f385dfb50402368669766504c0e15583" } } diff --git a/.config/nvim/lua/autocmd.lua b/.config/nvim/lua/autocmd.lua index 165bef7..91d1534 100644 --- a/.config/nvim/lua/autocmd.lua +++ b/.config/nvim/lua/autocmd.lua @@ -12,6 +12,7 @@ vim.api.nvim_create_autocmd({ "VimLeavePre" }, { Session.store(vim.loop.cwd()) end, }) + vim.api.nvim_create_autocmd({ "VimEnter" }, { callback = function() if vim.fn.argc() ~= 0 then @@ -24,3 +25,92 @@ vim.api.nvim_create_autocmd({ "VimEnter" }, { end, desc = "Restore last session automatically", }) + +-- benlubas/molten-nvim +local imb = function(e) + vim.schedule(function() + local kernels = vim.fn.MoltenAvailableKernels() + local try_kernel_name = function() + local metadata = vim.json.decode(io.open(e.file, "r"):read("a"))["metadata"] + return metadata.kernelspec.name + end + local ok, kernel_name = pcall(try_kernel_name) + if not ok or not vim.tbl_contains(kernels, kernel_name) then + kernel_name = nil + local venv = os.getenv("VIRTUAL_ENV") or os.getenv("CONDA_PREFIX") + if venv ~= nil then + kernel_name = string.match(venv, "/.+/(.+)") + end + end + if kernel_name ~= nil and vim.tbl_contains(kernels, kernel_name) then + vim.cmd(("MoltenInit %s"):format(kernel_name)) + end + vim.cmd("MoltenImportOutput") + end) +end + +vim.api.nvim_create_autocmd("BufAdd", { + pattern = { "*.ipynb" }, + callback = imb, +}) + +vim.api.nvim_create_autocmd("BufEnter", { + pattern = { "*.ipynb" }, + callback = function(e) + if vim.api.nvim_get_vvar("vim_did_enter") ~= 1 then + imb(e) + end + end, +}) + +local default_notebook = [[ + { + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython" + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3" + } + }, + "nbformat": 4, + "nbformat_minor": 5 + } +]] + +local function new_notebook(filename) + local path = filename .. ".ipynb" + local file = io.open(path, "w") + if file then + file:write(default_notebook) + file:close() + vim.cmd("edit " .. path) + else + print("Error: Could not open new notebook file for writing.") + end +end + +vim.api.nvim_create_user_command('NewNotebook', function(opts) + new_notebook(opts.args) +end, { + nargs = 1, + complete = 'file' +}) diff --git a/.config/nvim/lua/dictionaries/dictionary_de-de.txt b/.config/nvim/lua/dictionaries/dictionary_de-de.txt index f64a4a2..0a39d53 100644 --- a/.config/nvim/lua/dictionaries/dictionary_de-de.txt +++ b/.config/nvim/lua/dictionaries/dictionary_de-de.txt @@ -1,5 +1,23 @@ Bonitur +Entlebucher Sennenhund +Homeserver +Impro-Theater +Improtheater +Infokratie Königinnensubstanz Magazinbeute Magazinbeuten +Orgas +Poetry +Poetry-Slam +Poetryslam Pollenhose +Slam +Slammern +Slams +Torrenting +Uni-Theater +Unitheater +egozentristisch +Meta +shiftete diff --git a/.config/nvim/lua/dictionaries/dictionary_names.txt b/.config/nvim/lua/dictionaries/dictionary_names.txt index f0188b6..66882bf 100644 --- a/.config/nvim/lua/dictionaries/dictionary_names.txt +++ b/.config/nvim/lua/dictionaries/dictionary_names.txt @@ -1,3 +1,47 @@ +APV Akallabêth +Annoyed Altisaur +Aule +Barros +Boarding Party +Boelsen +CDSS +Casper +Caspers +CdE +Combi +Commander Edain +Elodie +Eyal +Greater +Guttersnipe +Habenhausen +IFAM +IFAMs +Jeanine +Kratom +Kubitschek +Käte +MTG +Magic +Magic: The Gathering +Mathis +Matvey +Mint Númenor +Overwatch +PopOS +Precon +Precons +Shinies +Shiny +SommerAka +SommerAkademie +TCAV +Weizman +WinterAka +WinterAkademie +Writhing Chrysalis +Ziegeleiweg +Zimin diff --git a/.config/nvim/lua/keymap.lua b/.config/nvim/lua/keymap.lua index 4bf58da..03e45fd 100644 --- a/.config/nvim/lua/keymap.lua +++ b/.config/nvim/lua/keymap.lua @@ -1,5 +1,6 @@ -- setup keymap function local wk = require("which-key") +local telescope = require("telescope") local lazygit = require("FTerm"):new({ cmd = "lazygit" }) wk.add({ @@ -8,11 +9,13 @@ wk.add({ {mode = "n", "gp", desc = "LSP: preview"}, {mode = "c", "w", desc = "Write"}, {mode = "c", "w!", desc = "Write: overwrite"}, + {mode = "n", "a", desc = "AI"}, {mode = "n", "g", desc = "Git"}, {mode = "n", "f", desc = "Telescope: find"}, {mode = "n", "gd", desc = "Git: diff"}, {mode = "n", "s", desc = "Substitute"}, {mode = "n", "t", desc = "Terminal"}, + {mode = "n", "r", desc = "Quarto"}, {mode = "n", "", desc = "Navigation"}, -- unmap unwanted commands {mode = "n", "Zt", "", noremap = true}, @@ -30,8 +33,6 @@ wk.add({ {mode = "n", "", "", noremap = true}, {mode = "n", "", "", noremap = true}, {mode = "n", "", "", noremap = true}, - -- spell - {mode = "n", "s", "z=", desc = "Spell: display suggestions"}, -- shortcuts for quitting {mode = "n", "ZA", ":xa", desc = "Exit: write and quit all buffers", noremap = true}, {mode = "n", "ZQ", ":conf q", desc = "Exit: quit current buffer", noremap = true}, @@ -51,7 +52,7 @@ wk.add({ {mode = "n", "sa", ":%S//g", desc = "Substitute: free form", noremap = true}, {mode = "n", "ss", ":%S/\\<\\>//g", desc = "Substitute: word under cursor", noremap = true}, -- simrat39/symbols-outline.nvim - {mode = "n", "", ":SymbolsOutline", desc = "CTags: toggle"}, + {mode = "n", "", ":Outline", desc = "CTags: toggle"}, -- nvim-tree/nvim-tree.lua {mode = "n", "", ":NvimTreeToggle toggle", desc = "File tree: toggle"}, -- mbbill/undotree @@ -62,16 +63,16 @@ wk.add({ {mode = "n", "tt", require("FTerm").toggle, desc = "Terminal: open", noremap = true}, {mode = "n", "gt", function() lazygit:toggle() end, desc = "Git: open lazygit", noremap = true}, {mode = "n", "tg", function() lazygit:toggle() end, desc = "Terminal: open lazygit", noremap = true}, - {mode = "n", "tg", function() lazygit:toggle() end, desc = "Terminal: open lazygit", noremap = true}, -- sindrets/diffview.nvim {mode = "n", "gdo", ":DiffviewOpen", desc = "Git: open diff"}, {mode = "n", "gdc", ":DiffviewClose", desc = "Git: close diff"}, -- folke/trouble.nvim - {mode = "n", "x", ":TroubleToggle", desc = "LSP: toggle error list"}, + {mode = "n", "", ":Trouble diagnostics toggle", desc = "LSP: toggle error list"}, -- hrsh7th/nvim-cmp - {mode = "n", "gd", vim.lsp.buf.definition(), desc = "LSP: goto definition", noremap = true}, - {mode = "n", "gD", vim.lsp.buf.declaration(), desc = "LSP: goto declaration", noremap = true}, - {mode = "n", "gi", vim.lsp.buf.implementation(), desc = "LSP: list implementation", noremap = true}, + {mode = "n", "gd", function() vim.lsp.buf.definition() end, desc = "LSP: goto definition", noremap = true}, + {mode = "n", "gD", function() vim.lsp.buf.declaration() end, desc = "LSP: goto declaration", noremap = true}, + {mode = "n", "gT", function() vim.lsp.buf.type_definition() end, desc = "LSP: goto type definition", noremap = true}, + {mode = "n", "gi", function() vim.lsp.buf.implementation() end, desc = "LSP: list implementation", noremap = true}, {mode = "n", "gr", function() vim.lsp.buf.references() end, desc = "LSP: list references", noremap = true}, {mode = "n", "K", vim.lsp.buf.hover(), desc = "LSP: show documentation", noremap = true}, {mode = "n", "", function() require("conform").format({ async = true, lsp_fallback = true }) end, desc = "LSP: format", noremap = true}, @@ -85,11 +86,16 @@ wk.add({ -- filipdutescu/renamer.nvim {mode = "n", "", function() require("renamer").rename() end, desc = "LSP: rename", noremap = true}, -- nvim-telescope/telescope.nvim - {mode = "n", "", ":Telescope find_files", desc = "Telescope: find files", noremap = true}, {mode = "n", "ff", ":Telescope find_files", desc = "Telescope: find files", noremap = true}, + {mode = "n", "ff", ":Telescope find_files", desc = "Telescope: find files", noremap = true}, + -- archie-judd/telescope-words.nvim + {mode = "n", "wd", telescope.extensions.telescope_words.search_dictionary, desc = "Telescope: search dictionary", noremap = true}, + {mode = "n", "wt", telescope.extensions.telescope_words.search_thesaurus, desc = "Telescope: search thesaurus", noremap = true}, + -- gnikdroy/projections.nvim + {mode = "n", "fp", function() vim.cmd("Telescope projections") end, desc = "Telescope: find projects", noremap = true}, -- kamykn/spelunker.vim - {mode = "n", "t", ":call spelunker#toggle()", desc = "Spelunker: toggle spell check", noremap = true}, - {mode = "n", "l", function() if vim.opt.spelllang._value == "de_de" then vim.opt.spelllang = "en_us" print("Spell language set to en_us") else vim.opt.spelllang = "de_de" print("Spell language set to de_de") end vim.opt.spell = false end, desc = "Spell: toggle spell language", noremap = true}, + {mode = "n", "t", ":call spelunker#toggle()", desc = "Spelunker: toggle spell check", noremap = true}, + {mode = "n", "s", "z=", desc = "Spell: display suggestions"}, -- kevinhwang91/nvim-ufo {mode = "n", "K", function() local winid = require("ufo").peekFoldedLinesUnderCursor() if not winid then vim.lsp.buf.hover() end end, desc = "LSP: peek folded section", noremap = true}, -- kevinhwang91/nvim-hlslens @@ -101,6 +107,13 @@ wk.add({ {mode = "n", "f", "(leap-forward)", desc = "Navigation: enter leap mode for forward movement", noremap = true}, {mode = "n", "F", "(leap-backward)", desc = "Navigation: enter leap mode for backwards movement", noremap = true}, {mode = "n", "gf", "(leap-from-window)", desc = "Navigation: enter leap mode for other windows", noremap = true}, - -- gnikdroy/projections.nvim - {mode = "n", "fp", function() vim.cmd("Telescope projections") end, desc = "Telescope: find projects", noremap = true}, + -- quarto-dev/quarto-nvim + {mode = "n", "rc", require("quarto.runner").run_cell, desc = "Quarto: Run cell", noremap = true, silent = true}, + {mode = "n", "ra", require("quarto.runner").run_above, desc = "Quarto: Run cell and above", noremap = true, silent = true}, + {mode = "n", "rA", require("quarto.runner").run_all, desc = "Quarto: Run all cells", noremap = true, silent = true}, + {mode = "n", "rl", require("quarto.runner").run_line, desc = "Quarto: Run line", noremap = true, silent = true}, + {mode = "n", "rr", require("quarto.runner").run_range, desc = "Quarto: Run visual range", noremap = true, silent = true}, + {mode = "n", "rL", function() require("quarto.runner").run_all(true) end, desc = "Quarto: Run all cells of all languages", noremap = true, silent = true}, + -- huynle/ogpt-nvim + {mode = "n", "ai", ":OGPT", desc = "OGTP: Open AI View", noremap = true}, }) diff --git a/.config/nvim/lua/plugins/blink-pairs.lua b/.config/nvim/lua/plugins/blink-pairs.lua new file mode 100644 index 0000000..45893a7 --- /dev/null +++ b/.config/nvim/lua/plugins/blink-pairs.lua @@ -0,0 +1,34 @@ +return { + "saghen/blink.pairs", + version = "*", -- (recommended) only required with prebuilt binaries + + -- download prebuilt binaries from github releases + dependencies = "saghen/blink.download", + + --- @module 'blink.pairs' + --- @type blink.pairs.Config + opts = { + mappings = { + enabled = true, + pairs = { + ["("] = ")", + ["["] = "]", + ["{"] = "}", + ["'"] = "'", + ['"'] = '"', + ["`"] = "`", + }, + }, + highlights = { + enabled = true, + groups = { + "BlinkPairsOrange", + "BlinkPairsPurple", + "BlinkPairsBlue", + }, + priority = 200, + ns = vim.api.nvim_create_namespace("blink.pairs"), + }, + debug = false, + }, +} diff --git a/.config/nvim/lua/plugins/csvview.lua b/.config/nvim/lua/plugins/csvview.lua new file mode 100644 index 0000000..8aa21d4 --- /dev/null +++ b/.config/nvim/lua/plugins/csvview.lua @@ -0,0 +1,17 @@ +return { + { + "hat0uma/csvview.nvim", + opts = { + parser = { comments = { "#", "//" } }, + keymaps = { + textobject_field_inner = { "if", mode = { "o", "x" } }, + textobject_field_outer = { "af", mode = { "o", "x" } }, + jump_next_field_end = { "", mode = { "n", "v" } }, + jump_prev_field_end = { "", mode = { "n", "v" } }, + jump_next_row = { "", mode = { "n", "v" } }, + jump_prev_row = { "", mode = { "n", "v" } }, + }, + }, + cmd = { "CsvViewEnable", "CsvViewDisable", "CsvViewToggle" }, + } +} diff --git a/.config/nvim/lua/plugins/goto-preview.lua b/.config/nvim/lua/plugins/goto-preview.lua index a3fb692..aefa8f3 100644 --- a/.config/nvim/lua/plugins/goto-preview.lua +++ b/.config/nvim/lua/plugins/goto-preview.lua @@ -1,5 +1,6 @@ return { "rmagatti/goto-preview", + dependencies = 'rmagatti/logger.nvim', config = function() require("goto-preview").setup({}) end, diff --git a/.config/nvim/lua/plugins/knap.lua b/.config/nvim/lua/plugins/knap.lua index 51efe5e..b323498 100644 --- a/.config/nvim/lua/plugins/knap.lua +++ b/.config/nvim/lua/plugins/knap.lua @@ -1,27 +1,55 @@ return { - -- latex asynchronous pdf rendering { 'frabjous/knap', ft = { 'tex' }, config = function() + + local function detect_engine() + local first_line = vim.api.nvim_buf_get_lines(0, 0, 1, false)[1] or "" + if first_line:match("^%%%s*xelatex") then + return "xelatex" + else + return "pdflatex" + end + end + + local function set_engine() + local engine = detect_engine() + + if engine == "xelatex" then + vim.g.knap_settings.textopdf = + "xelatex -synctex=1 -interaction=batchmode %docroot%" + else + vim.g.knap_settings.textopdf = + "pdflatex -synctex=1 -interaction=batchmode %docroot%" + end + end + vim.g.knap_settings = { delay = 100, - -- tex texoutputext = "pdf", - textopdf = "pdflatex -synctex=1 -halt-on-error -interaction=batchmode %docroot%", + textopdf = "xelatex -synctex=1 -interaction=batchmode %docroot%", textopdfviewerlaunch = - "zathura --synctex-editor-command 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%{input}'\"'\"',%{line},0)\"' ./%outputfile%", - textopdfviewerrefresh = "none", - textopdfforwardjump = "zathura --synctex-forward=%line%:%column%:%srcfile% %outputfile%", - -- markdown - mdoutputext = "pdf", - mdtopdf = "pandoc %docroot% --toc --toc-depth=5 -V colorlinks=true -V linkcolor=blue -V urlcolor=red -V toccolor=gray -o %outputfile%", - mdtopdfviewerlaunch = "zathura ./%outputfile%", - mdtohtml = "pandoc --standalone %docroot% -o %outputfile%", - mdtohtmlviewerlaunch = "firefox --kiosk --new-window %outputfile%", - mdtohtmlviewerrefresh = "none", - mdtopdfviewerrefresh = "none", + "zathura --synctex-editor-command 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%{input}'\"'\"',%{line},0)\"' ./%outputfile%", + textopdfviewerrefresh = "reload", + textopdfforwardjump = + "zathura --synctex-forward=%line%:%column%:%srcfile% %outputfile%", } + + vim.api.nvim_create_autocmd("User", { + pattern = "KnapShowView", + callback = set_engine + }) + + vim.api.nvim_create_autocmd("User", { + pattern = "KnapCompile", + callback = set_engine + }) + + vim.api.nvim_create_autocmd("BufWritePost", { + pattern = "*.tex", + callback = set_engine + }) end } } diff --git a/.config/nvim/lua/plugins/lualine.lua b/.config/nvim/lua/plugins/lualine.lua index 79321aa..0d0f569 100644 --- a/.config/nvim/lua/plugins/lualine.lua +++ b/.config/nvim/lua/plugins/lualine.lua @@ -15,7 +15,7 @@ return { }, { "tiyn/tccs.nvim" }, { - "roobert/action-hints.nvim", + "tiyn/action-hints.nvim", config = function() require("action-hints").setup({ template = { diff --git a/.config/nvim/lua/plugins/mason.lua b/.config/nvim/lua/plugins/mason.lua index dd625ef..fa1beda 100644 --- a/.config/nvim/lua/plugins/mason.lua +++ b/.config/nvim/lua/plugins/mason.lua @@ -45,7 +45,7 @@ return { "yamlfmt", } } - } + }, }, opts = { ui = { icons = Install_signs } } } diff --git a/.config/nvim/lua/plugins/molten.lua b/.config/nvim/lua/plugins/molten.lua new file mode 100644 index 0000000..1216aa5 --- /dev/null +++ b/.config/nvim/lua/plugins/molten.lua @@ -0,0 +1,61 @@ +return { + { + "benlubas/molten-nvim", + version = "^1.0.0", + dependencies = { + { + "3rd/image.nvim", + opts = { + backend = "ueberzug", + max_width = 100, + max_height = 12, + max_height_window_percentage = math.huge, + max_width_window_percentage = math.huge, + window_overlap_clear_enabled = true, + window_overlap_clear_ft_ignore = { "cmp_menu", "cmp_docs", "" }, + }, + }, + { + "quarto-dev/quarto-nvim", + dependencies = { + "jmbuhr/otter.nvim", + "nvim-treesitter/nvim-treesitter", + }, + opts = { + lspFeatures = { + languages = { "python" }, + chunks = "all", + diagnostics = { + enabled = true, + triggers = { "BufWritePost" }, + }, + completion = { + enabled = true, + }, + }, + codeRunner = { + enabled = true, + default_method = "molten", + }, + }, + }, + { + "GCBallesteros/jupytext.nvim", + opts = { + style = "markdown", + output_extension = "md", + force_ft = "markdown", + }, + }, + }, + build = ":UpdateRemotePlugins", + init = function() + vim.g.molten_auto_open_output = false + vim.g.molten_wrap_output = true + vim.g.molten_virt_text_output = true + vim.g.molten_virt_lines_off_by_1 = true + vim.g.molten_image_provider = "image.nvim" + vim.g.molten_output_win_max_height = 20 + end, + }, +} diff --git a/.config/nvim/lua/plugins/nvim-autopairs.lua b/.config/nvim/lua/plugins/nvim-autopairs.lua deleted file mode 100644 index 483083d..0000000 --- a/.config/nvim/lua/plugins/nvim-autopairs.lua +++ /dev/null @@ -1,7 +0,0 @@ -return { - -- automatic closing of brackets - { - 'windwp/nvim-autopairs', - opts = {} - } -} diff --git a/.config/nvim/lua/plugins/nvim-docs-view.lua b/.config/nvim/lua/plugins/nvim-docs-view.lua index 210ad1f..d992cfd 100644 --- a/.config/nvim/lua/plugins/nvim-docs-view.lua +++ b/.config/nvim/lua/plugins/nvim-docs-view.lua @@ -1,5 +1,5 @@ return { - "amrbashir/nvim-docs-view", + "tiyn/nvim-docs-view", lazy = true, cmd = "DocsViewToggle", opts = { diff --git a/.config/nvim/lua/plugins/nvim-lspconfig.lua b/.config/nvim/lua/plugins/nvim-lspconfig.lua index d4d07af..8a2d8fd 100644 --- a/.config/nvim/lua/plugins/nvim-lspconfig.lua +++ b/.config/nvim/lua/plugins/nvim-lspconfig.lua @@ -1,18 +1,23 @@ return { -- lang server management { - 'neovim/nvim-lspconfig', + "neovim/nvim-lspconfig", dependencies = { - 'williamboman/mason-lspconfig.nvim', + "williamboman/mason-lspconfig.nvim", { - 'hrsh7th/cmp-nvim-lsp', + "mrcjkb/rustaceanvim", + version = "^6", + lazy = false, + }, + { + "hrsh7th/cmp-nvim-lsp", config = function() Capabilities = require("cmp_nvim_lsp").default_capabilities() Capabilities.textDocument.foldingRange = { dynamicRegistration = false, - lineFoldingOnly = true + lineFoldingOnly = true, } - end + end, }, }, config = function() @@ -36,40 +41,40 @@ return { "texlab", -- "tsserver", "yamlls", - } + }, }) - + local default_flags = { + debounce_text_changes = 150, + allow_incremental_sync = true, + progress = true, + } local servers = { - lua_ls = { - Lua = { - diagnostics = { - globals = { 'vim' } + ltex = { + settings = { + ltex = { + -- language = "de-DE", + enabled = { "latex", "markdown" }, + dictionary = Dictionaries, }, - telemetry = { enable = false }, }, }, - ltex = { - ltex = { - -- language = "de-DE", - enabled = { "latex" }, - dictionary = Dictionaries, - } - } - } - local default = { __index = function() return {} end } - setmetatable(servers, default) - require("mason-lspconfig").setup_handlers({ - function(server_name) - require('lspconfig')[server_name].setup({ - on_attach = Attach_func, - capabilities = Capabilities, - flags = { - debounce_text_changes = 150 + lua_ls = { + settings = { + lua = { + diagnostics = { globals = { "vim" } }, + telemetry = { enable = false }, }, - settings = servers[server_name] - }) - end - }) - end - } + }, + }, + pyright = {} + } + for name, config in pairs(servers) do + vim.lsp.config(name, vim.tbl_extend("force", config, { + on_attach = on_attach, + capabilities = Capabilities, + flags = default_flags, + })) + end + end, + }, } diff --git a/.config/nvim/lua/plugins/nvim-treesitter.lua b/.config/nvim/lua/plugins/nvim-treesitter.lua index 3640b27..e1e94a6 100644 --- a/.config/nvim/lua/plugins/nvim-treesitter.lua +++ b/.config/nvim/lua/plugins/nvim-treesitter.lua @@ -7,7 +7,7 @@ return { -- automatically close html-tags 'windwp/nvim-ts-autotag', -- color brackets - 'p00f/nvim-ts-rainbow', + -- 'p00f/nvim-ts-rainbow', }, config = function() require("nvim-treesitter.configs").setup({ @@ -19,17 +19,18 @@ return { "markdown_inline", "latex", "python", + "rust", "lua", }, - highlight = { enable = true }, + -- highlight = { enable = true }, autotag = { enable = false }, - rainbow = { - enable = false, - extended_mode = true, - max_file_lines = nil, - -- colors = {}, - -- termcolors = {} - } + -- rainbow = { + -- enable = true, + -- extended_mode = true, + -- max_file_lines = nil, + -- -- colors = {}, + -- -- termcolors = {} + -- } }) end } diff --git a/.config/nvim/lua/plugins/ogpt.lua b/.config/nvim/lua/plugins/ogpt.lua new file mode 100644 index 0000000..31cb05a --- /dev/null +++ b/.config/nvim/lua/plugins/ogpt.lua @@ -0,0 +1,139 @@ +return { +{ + "huynle/ogpt.nvim", + event = "VeryLazy", + opts = { + default_provider = "ollama", + edgy = true, -- enable this! + single_window = false, -- set this to true if you want only one OGPT window to appear at a time + providers = { + ollama = { + api_host = "http://localhost:11434", -- free resources: https://github.com/cheahjs/free-llm-api-resources + api_key = "", + model = "deepseek-r1:7b", + } + } + }, + dependencies = { + "MunifTanjim/nui.nvim", + "nvim-lua/plenary.nvim", + "nvim-telescope/telescope.nvim" + } +}, +{ + "folke/edgy.nvim", + event = "VeryLazy", + init = function() + vim.opt.laststatus = 3 + vim.opt.splitkeep = "screen" -- or "topline" or "screen" + end, + opts = { + exit_when_last = false, + animate = { + enabled = false, + }, + wo = { + winbar = true, + winfixwidth = true, + winfixheight = false, + winhighlight = "WinBar:EdgyWinBar,Normal:EdgyNormal", + spell = false, + signcolumn = "no", + }, + keys = { + -- -- close window + ["q"] = function(win) + win:close() + end, + -- close sidebar + ["Q"] = function(win) + win.view.edgebar:close() + end, + -- increase width + [""] = function(win) + win:resize("width", 3) + end, + -- decrease width + [""] = function(win) + win:resize("width", -3) + end, + -- increase height + [""] = function(win) + win:resize("height", 3) + end, + -- decrease height + [""] = function(win) + win:resize("height", -3) + end, + }, + right = { + { + title = "OGPT Popup", + ft = "ogpt-popup", + size = { width = 0.2 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPT Parameters", + ft = "ogpt-parameters-window", + size = { height = 6 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPT Template", + ft = "ogpt-template", + size = { height = 6 }, + }, + { + title = "OGPT Sessions", + ft = "ogpt-sessions", + size = { height = 6 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPT System Input", + ft = "ogpt-system-window", + size = { height = 6 }, + }, + { + title = "OGPT", + ft = "ogpt-window", + size = { height = 0.5 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPT {{{selection}}}", + ft = "ogpt-selection", + size = { width = 80, height = 4 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPt {{{instruction}}}", + ft = "ogpt-instruction", + size = { width = 80, height = 4 }, + wo = { + wrap = true, + }, + }, + { + title = "OGPT Chat", + ft = "ogpt-input", + size = { width = 80, height = 4 }, + wo = { + wrap = true, + }, + }, + }, + }, + } +} diff --git a/.config/nvim/lua/plugins/outline.lua b/.config/nvim/lua/plugins/outline.lua new file mode 100644 index 0000000..985f98a --- /dev/null +++ b/.config/nvim/lua/plugins/outline.lua @@ -0,0 +1,13 @@ +return { + { + "hedyhli/outline.nvim", + opts = { + outline_window = { + width = 25 + }, + symbols = { + icon_source = 'lspkind', + } + } + } +} diff --git a/.config/nvim/lua/plugins/symbols-outline.lua b/.config/nvim/lua/plugins/symbols-outline.lua deleted file mode 100644 index 54e1fe7..0000000 --- a/.config/nvim/lua/plugins/symbols-outline.lua +++ /dev/null @@ -1,39 +0,0 @@ -return { - -- ctags like menu - { - "simrat39/symbols-outline.nvim", - opts = { - width = 25, - symbols = { - File = { icon = Lsp_signs.File, hl = "@text.uri" }, - Module = { icon = Lsp_signs.Module, hl = "@namespace" }, - Class = { icon = Lsp_signs.Class, hl = "@type" }, - Method = { icon = Lsp_signs.Method, hl = "@method" }, - Property = { icon = Lsp_signs.Property, hl = "@method" }, - Field = { icon = Lsp_signs.Field, hl = "@field" }, - Constructor = { icon = Lsp_signs.Constructor, hl = "@constructor" }, - Enum = { icon = Lsp_signs.Enum, hl = "@type" }, - Interface = { icon = Lsp_signs.Interface, hl = "@type" }, - Function = { icon = Lsp_signs.Function, hl = "@function" }, - Variable = { icon = Lsp_signs.Variable, hl = "@constant" }, - Constant = { icon = Lsp_signs.Constant, hl = "@constant" }, - Key = { icon = Lsp_signs.Keyword, hl = "@type" }, - EnumMember = { icon = Lsp_signs.EnumMember, hl = "@field" }, - Struct = { icon = Lsp_signs.Struct, hl = "@type" }, - Event = { icon = Lsp_signs.Event, hl = "@type" }, - Operator = { icon = Lsp_signs.Operator, hl = "@operator" }, - TypeParameter = { icon = Lsp_signs.TypeParameter, hl = "@parameter" }, - Boolean = { icon = Lsp_signs.Boolean, hl = "@boolean" }, - Null = { icon = Lsp_signs.Null, hl = "@type" }, - Component = { icon = Lsp_signs.Component, hl = "@function" }, - Fragment = { icon = Lsp_signs.Fragment, hl = "@constant" }, - Object = { icon = Lsp_signs.Object, hl = "@type" }, - Array = { icon = Lsp_signs.Array, hl = "@constant" }, - Number = { icon = Lsp_signs.Number, hl = "@number" }, - String = { icon = Lsp_signs.String, hl = "@string" }, - Namespace = { icon = Lsp_signs.Namespace, hl = "@namespace" }, - Package = { icon = Lsp_signs.Package, hl = "@namespace" }, - }, - }, - }, -} diff --git a/.config/nvim/lua/plugins/telescope.lua b/.config/nvim/lua/plugins/telescope.lua index 8382353..dc31800 100644 --- a/.config/nvim/lua/plugins/telescope.lua +++ b/.config/nvim/lua/plugins/telescope.lua @@ -3,7 +3,10 @@ return { { 'nvim-telescope/telescope.nvim', version = '0.1.2', - dependencies = { 'nvim-lua/plenary.nvim' }, + dependencies = { + 'nvim-lua/plenary.nvim', + 'archie-judd/telescope-words.nvim' + }, opts = {} } } diff --git a/.config/nvim/lua/resources/header.tex b/.config/nvim/lua/resources/header.tex new file mode 100644 index 0000000..63e5b9a --- /dev/null +++ b/.config/nvim/lua/resources/header.tex @@ -0,0 +1,13 @@ +% \usepackage[utf8]{inputenc} +% \DeclareUnicodeCharacter{2605}{\ensuremath{\star}} +% +\usepackage{fontspec} +\usepackage{newunicodechar} + +\newfontfamily\symbolafont{Symbola} + +% U+2605 BLACK STAR +\newunicodechar{★}{{\symbolafont ★}} + +% U+2606 WHITE STAR +\newunicodechar{☆}{{\symbolafont ☆}} diff --git a/.config/nvim/lua/style.lua b/.config/nvim/lua/style.lua index 02142f6..e714846 100644 --- a/.config/nvim/lua/style.lua +++ b/.config/nvim/lua/style.lua @@ -21,6 +21,7 @@ Menu_signs = { path = "", } + Lsp_signs = { Array = "", Boolean = "⊥", @@ -106,22 +107,17 @@ Lualine_signs = { unnamed = "", } -vim.fn.sign_define( - "DiagnosticSignError", - { texthl = "DiagnosticSignError", text = Error_sign, numhl = "DiagnosticSignError" } -) -vim.fn.sign_define( - "DiagnosticSignWarn", - { texthl = "DiagnosticSignWarn", text = Warn_sign, numhl = "DiagnosticSignWarn" } -) -vim.fn.sign_define( - "DiagnosticSignInfo", - { texthl = "DiagnosticSignInfo", text = Info_sign, numhl = "DiagnosticSignInfo" } -) -vim.fn.sign_define( - "DiagnosticSignHint", - { texthl = "DiagnosticSignHint", text = Hint_sign, numhl = "DiagnosticSignHint" } -) +vim.diagnostic.config({ + severity_sort = true, + signs = { + text = { + [vim.diagnostic.severity.ERROR] = Error_sign, + [vim.diagnostic.severity.WARN] = Warn_sign, + [vim.diagnostic.severity.INFO] = Info_sign, + [vim.diagnostic.severity.HINT] = Hint_sign, + }, + }, +}) -- enable colorcolumn when textwidth is set vim.o.cursorline = true diff --git a/.config/qt6ct/qt6ct.conf b/.config/qt6ct/qt6ct.conf index fb51240..c77c0e3 100644 --- a/.config/qt6ct/qt6ct.conf +++ b/.config/qt6ct/qt6ct.conf @@ -3,7 +3,7 @@ color_scheme_path=/usr/share/qt6ct/colors/darker.conf custom_palette=true icon_theme=breeze-dark standard_dialogs=default -style=Breeze +style=Adwaita-Dark [Fonts] fixed="Linux Biolinum,12,-1,5,400,0,0,0,0,0,0,0,0,0,0,1" @@ -25,7 +25,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\x16\0\0\t\xff\0\0\x5\x9f\0\0\0\0\0\0\0\x16\0\0\t\xff\0\0\x5\x9f\0\0\0\0\0\0\0\0\n\0\0\0\0\0\0\0\0\x16\0\0\t\xff\0\0\x5\x9f) +geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\0\0\0\0\0\x13\0\0\x5\xff\0\0\x3\xbf\0\0\0\0\0\0\0\x13\0\0\x5\xff\0\0\x3\xbf\0\0\0\0\0\0\0\0\x6\0\0\0\0\0\0\0\0\x13\0\0\x5\xff\0\0\x3\xbf) [Troubleshooting] force_raster_widgets=1 diff --git a/.config/swaylock/config b/.config/swaylock/config new file mode 100644 index 0000000..f32e615 --- /dev/null +++ b/.config/swaylock/config @@ -0,0 +1 @@ +image=~/.local/share/lock diff --git a/.config/swhkd/swhkdrc b/.config/swhkd/swhkdrc new file mode 100644 index 0000000..f3ad474 --- /dev/null +++ b/.config/swhkd/swhkdrc @@ -0,0 +1,86 @@ +super + b + $BROWSER + +super + m + thunderbird + +super + u + record_stop + +super + i + record_start + +super + o + record_replay_start + +super + p + record_replay_save + +super + a + lmc previous + +super + s + lmc playpause + +super + d + lmc next + +super + c + lmc loop + +super + x + lmc shuffle + +super + bracketright + lmc mute_toggle + +super + backslash + lmc deaf_toggle + +super + apostrophe + lmc tap_toggle + +super + bracketleft + dnd toggle + +super + shift + b + killall -SIGUSR1 waybar + +super + shift + r + pkill -HUP swhkd ; notify-send -u low 'SWHKD' 'Reloaded hotkeys' + +super + shift + space + dunstctl close-all + +super + F7 + mount_menu + +super + F8 + umount_menu + +super + F9 + systemctl restart NetworkManager ; notify-send -u low 'Network' 'Restartet NM' + +super + F10 + prompt "Lock computer?" "swaylock -i ~/.local/share/lock" + +super + shift + F10 + prompt "Hibernate computer?" "systemctl hibernate" + +super + F11 + prompt "Shutdown computer?" "shutdown -h now" + +super + F12 + prompt "Reboot computer?" "reboot now" + +Print + screenshot + +XF86AudioMute + lmc deaf_toggle + +XF86AudioLowerVolume + lmc down + +XF86AudioRaiseVolume + lmc up diff --git a/.config/sxhkd/sxhkdrc b/.config/sxhkd/sxhkdrc index 0e64a14..b1280bd 100644 --- a/.config/sxhkd/sxhkdrc +++ b/.config/sxhkd/sxhkdrc @@ -49,6 +49,9 @@ super + Return Print screenshot +super + space + touchpad toggle + super + shift + space dunstctl close-all diff --git a/.config/waybar/config.jsonc b/.config/waybar/config.jsonc new file mode 100644 index 0000000..01c1052 --- /dev/null +++ b/.config/waybar/config.jsonc @@ -0,0 +1,85 @@ + +{ + "layer": "bottom", // Waybar at top layer + "position": "top", // Waybar position (top|bottom|left|right) + "height": 5, // Waybar height (to be removed for auto height) + // "width": 1280, // Waybar width + // Choose the order of the modules + "modules-left": ["dwl/tags", "dwl/window"], + "modules-right": ["cpu", "memory", "pulseaudio#output", "pulseaudio#input", "network", "battery", "clock", "tray"], + // Modules configuration + // "sway/workspaces": { + // "disable-scroll": true, + // "all-outputs": true, + // "format": "{name}: {icon}", + // "format-icons": { + // "1": "", + // "2": "", + // "3": "", + // "4": "", + // "5": "", + // "urgent": "", + // "focused": "", + // "default": "" + // } + // }, + "dwl/tags": { + "tag-labels": [ "", "", "", "", "", "", "", "", "", "" ], + "num-tags": 10 + }, + "dwl/window": { + "format": "{layout} {title}" + }, + "tray": { + "icon-size": 20, + "spacing": 10 + }, + "clock": { + "format": " {:%d %b %H:%M}" + }, + "battery": { + "states": { + "good": 75, + "warning": 25, + "critical": 15 + }, + "format": "{icon}", + "format-icons": { + "default": ["", "", "", "", ""], + "charging": ["", "", "", "", ""] + } + // "format-charging": "{capacity}%", + // "format-plugged": "{capacity}%", + // "format-alt": "{time} ", + // "format-good": "", // An empty format will hide the module + // "format-full": "", + }, + "network": { + // "interface": "wlp2*", // (Optional) To force the use of this interface + "format-wifi": "{icon}", + "format-ethernet": "󰈀", + "format-disconnected": "", + "format-icons": [ "" ] + }, + "pulseaudio#output": { + // "scroll-step": 1, // %, can be a float + "format-source": "", + "format-source-muted": "", + "format": "{format_source}" + }, + "pulseaudio#input": { + // "scroll-step": 1, // %, can be a float + "format": "{icon}", + "format-muted": "", + "format-bluetooth": "{format_source}", + "format-icons": [ "", "", "", ""] + }, + //disk-usage, gpu + "cpu": { + "format": "", + "tooltip": true + }, + "memory": { + "format": "" + } +} diff --git a/.config/waybar/style.css b/.config/waybar/style.css new file mode 100644 index 0000000..258acc9 --- /dev/null +++ b/.config/waybar/style.css @@ -0,0 +1,238 @@ +* { + border: none; + border-radius: 4px; + /* `ttf-font-awesome` is required to be installed for icons */ + font-family: Mono, Helvetica, Arial, sans-serif; + + /* adjust font-size value to your liking: */ + font-size: 15px; + + min-height: 0; +} + +window#waybar { + background-color: rgba(0, 0, 0, 1); + /* border-bottom: 3px solid rgba(100, 114, 125, 0.5); */ + color: #ffffff; + /* transition-property: background-color; */ + /* transition-duration: .5s; */ + /* border-radius: 0; */ +} + +/* window#waybar.hidden { + opacity: 0.2; +} */ + +/* +window#waybar.empty { + background-color: transparent; +} +window#waybar.solo { + background-color: #FFFFFF; +} +*/ + +/* window#waybar.termite { + background-color: #000000; +} + +window#waybar.chromium { + background-color: #000000; + border: none; +} */ + +#tags button { + /* padding: 0 0.4em; */ + /* background-color: transparent; */ + color: #ffffff; + /* Use box-shadow instead of border so the text isn't offset */ + box-shadow: inset 0 -3px transparent; +} + +/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ +#tags button:hover { + background: rgba(0, 0, 0, 0.9); + /* box-shadow: inset 0 -3px #ffffff; */ +} + +#tags button.occupied { + /* background-color: #282828; */ + box-shadow: inset 0 -3px #ffffff; +} + +#tags button.focused { + background-color: #555a63; + /* box-shadow: inset 0 -3px #ffffff; */ +} + +#tags button.urgent { + background-color: #eb4d4b; +} + +#mode { + background-color: #64727D; + /* border-bottom: 3px solid #ffffff; */ +} + +#clock, +#battery, +#cpu, +#memory, +#temperature, +#backlight, +#network, +#pulseaudio, +#custom-media, +#tray, +#mode, +#idle_inhibitor, +#mpd { + padding: 0 10px; + margin: 6px 3px; + color: #000000; +} + +#window, +#tags { + margin: 0 4px; +} + +/* If workspaces is the leftmost module, omit left margin */ +.modules-left > widget:first-child > #tags { + margin-left: 0; +} + +/* If workspaces is the rightmost module, omit right margin */ +.modules-right > widget:last-child > #tags { + margin-right: 0; +} + +#clock { + background-color: #000000; + color: white; +} + +#battery { + background-color: #000000; + color: white; +} + +#battery.charging { + color: #ffffff; + background-color: #000000; +} + +@keyframes blink { + to { + background-color: #ffffff; + color: #000000; + } +} + +#battery.critical:not(.charging) { + background-color: #f53c3c; + color: #ffffff; + animation-name: blink; + animation-duration: 0.5s; + animation-timing-function: linear; + animation-iteration-count: infinite; + animation-direction: alternate; +} + +label:focus { + background-color: #000000; +} + +#cpu { + background-color: #000000; + color: #ffffff; +} + +#memory { + background-color: #000000; + color: white; +} + +#backlight { + background-color: #000000; + color:white; +} + +#network { + background-color: #000000; + color:white; +} + +#network.disconnected { + background-color: #000000; +} + +#pulseaudio { + background-color: #000000; + color: #ffffff; +} + +#pulseaudio.muted { + background-color: #000000; + color: #ffffff; +} + +#custom-media { + background-color: #66cc99; + color: #2a5c45; + min-width: 100px; +} + +#custom-media.custom-spotify { + background-color: #66cc99; +} + +#custom-media.custom-vlc { + background-color: #ffa000; +} + +#temperature { + background-color: #f0932b; +} + +#temperature.critical { + background-color: #eb4d4b; +} + +#tray { + background-color: #000000; +} + +#idle_inhibitor { + background-color: #2d3436; +} + +#idle_inhibitor.activated { + background-color: #ecf0f1; + color: #2d3436; +} + +#mpd { + background-color: #66cc99; + color: #2a5c45; +} + +#mpd.disconnected { + background-color: #f53c3c; +} + +#mpd.stopped { + background-color: #90b1b1; +} + +#mpd.paused { + background-color: #51a37a; +} + +#language { + background: #bbccdd; + color: #333333; + padding: 0 5px; + margin: 6px 3px; + min-width: 16px; +} diff --git a/.config/wayland/swayidle.sh b/.config/wayland/swayidle.sh new file mode 100755 index 0000000..c7bb52f --- /dev/null +++ b/.config/wayland/swayidle.sh @@ -0,0 +1,11 @@ +#!/bin/sh +exec swayidle -w \ + timeout 600 "brightnessctl -s set 0%" resume "brightnessctl -r"\ + timeout 1200 "notify-send -u critical 'Power' 'Laptop will suspend in 10 minutes!'"\ + timeout 1200 "notify-send -u critical 'Power' 'Screen will turn off soon'"\ + timeout 1260 "wlr-randr --output eDP-1 --off" resume "wlr-randr --output eDP-1 --on"\ + timeout 1500 "notify-send -u critical 'Power' 'System will suspend in 5 minutes!'"\ + timeout 1740 "notify-send -u critical 'Power' 'System will suspend in 1 minute!'"\ + timeout 1790 "notify-send -u critical 'Power' 'System will suspend in 10 seconds!'"\ + timeout 1795 "notify-send -u critical 'Power' 'System will suspend in 5 seconds!'"\ + timeout 1800 "systemctl suspend-then-hibernate" diff --git a/.config/wayland/wayland.conf b/.config/wayland/wayland.conf new file mode 100755 index 0000000..8776a3f --- /dev/null +++ b/.config/wayland/wayland.conf @@ -0,0 +1,31 @@ +#!/bin/sh +exec systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP & +exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP & +nmcli radio wifi on & + +[ -f "${HOME}/.config/wayland/swayidle.sh" ] && . "${HOME}/.config/wayland/swayidle.sh" & +[ -f "${HOME}/.config/wayland/wayland-local.conf" ] && . "${HOME}/.config/wayland/wayland-local.conf" & + +$STATUSBAR & # use environment variable +xss-lock -- swaylock & # enable locking the screen upon sleep +swaybg -i ~/.local/share/bg & +dunst & +dunstctl rule dnd_low disable & +dunstctl rule dnd_normal disable & +swhks && swhkd & + +pavucontrol & +easyeffects --gapplication-service & +nextcloud & +keepassxc & +zen-browser & +discord & +signal-desktop & +Telegram & +threema-beta & +thunderbird & + +# monitor toggle & +# touchpad off & +# xset r rate 300 50 & # Speed xrate up +# redshift & # redshift for saving your eyes diff --git a/.config/xdg-desktop-portal/portals.conf b/.config/xdg-desktop-portal/portals.conf new file mode 100644 index 0000000..39e9c9e --- /dev/null +++ b/.config/xdg-desktop-portal/portals.conf @@ -0,0 +1,5 @@ +[preferred] +default=gtk +org.freedesktop.impl.portal.Screenshot=wlr +org.freedesktop.impl.portal.ScreenCast=wlr +org.freedesktop.impl.portal.Secret=gnome-keyring diff --git a/.config/yay/config.json b/.config/yay/config.json new file mode 100644 index 0000000..58cd9ed --- /dev/null +++ b/.config/yay/config.json @@ -0,0 +1,3 @@ +{ + "removemake": "yes" +} diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc index 491a5b5..296a74b 100644 --- a/.config/zsh/.zshrc +++ b/.config/zsh/.zshrc @@ -81,6 +81,33 @@ function +vi-git-stash() { fi } +################## +# CUSTOM WIDGETS # +################## + +_git_fix_main_master() { + if [[ $BUFFER == git\ * ]]; then + local has_main=0 + local has_master=0 + git rev-parse --verify main >/dev/null 2>&1 && has_main=1 + git rev-parse --verify master >/dev/null 2>&1 && has_master=1 + if [[ $has_main -eq 1 && $has_master -eq 0 ]]; then + if [[ $BUFFER == *" master"* ]]; then + BUFFER=${BUFFER//" master"/" main"} + fi + fi + if [[ $has_master -eq 1 && $has_main -eq 0 ]]; then + if [[ $BUFFER == *" main"* ]]; then + BUFFER=${BUFFER//" main"/" master"} + fi + fi + fi + zle accept-line +} + +zle -N _git_fix_main_master +bindkey "^M" _git_fix_main_master + ######### # STYLE # ######### @@ -164,17 +191,20 @@ setopt autocd autopushd autoload -Uz compinit && compinit # Plugin: command not found notice -source /usr/share/doc/pkgfile/command-not-found.zsh +[ -f "/usr/share/doc/pkgfile/command-not-found.zsh" ] && source /usr/share/doc/pkgfile/command-not-found.zsh # Plugin: fuzzy completion -source /usr/share/zsh/plugins/fzf-tab-git/fzf-tab.plugin.zsh +[ -f "/usr/share/zsh/plugins/fzf-tab-git/fzf-tab.plugin.zsh" ] && source /usr/share/zsh/plugins/fzf-tab-git/fzf-tab.plugin.zsh # Plugin: autosuggestions -source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh -bindkey '^ ' autosuggest-accept +[ -f "/usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh" ] && source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh && bindkey '^ ' autosuggest-accept # Plugin: syntax highlighting -source /usr/share/zsh/plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh +[ -f "/usr/share/zsh/plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh" ] && source /usr/share/zsh/plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh + +# Plugin: Autopair + +[ -f "/usr/share/zsh/plugins/zsh-autopair/zsh-autopair.plugin.zsh" ] && source /usr/share/zsh/plugins/zsh-autopair/zsh-autopair.plugin.zsh # Open shell with tmux always if [[ -n "$PS1" ]] && [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then @@ -185,7 +215,7 @@ fi eval $(thefuck --alias) # python -#eval "$(pyenv init -)" +eval "$(pyenv init -)" ########################## # COMMANDS BEFORE PROMPT # diff --git a/.dmrc b/.dmrc new file mode 100644 index 0000000..3e10fe0 --- /dev/null +++ b/.dmrc @@ -0,0 +1,2 @@ +[Desktop] +Session=xinitrc diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 0000000..dccfd9e --- /dev/null +++ b/.gitconfig @@ -0,0 +1,24 @@ +[user] + email = tiyn@posteo.eu + ; email = tiyn@mail-mk.eu + name = tiyn +[filter "lfs"] + process = git-lfs filter-process + required = true + clean = git-lfs clean -- %f + smudge = git-lfs smudge -- %f +[init] + defaultBranch = main +[fetch] + prune = true +[core] + pager = delta +[interactive] + diffFilter = delta --color-only +[delta] + navigate = true + dark = true + side-by-side = true + show-syntax-themes = true +[merge] + conflictStyle = zdiff3 diff --git a/.gitignore b/.gitignore index 0d5c06e..5a0bcc9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .dotfiles .config/nvim/plugin/packer_compiled.lua +.config/wayland/wayland-local.conf diff --git a/.local/bin/app-maps/discord b/.local/bin/app-maps/discord new file mode 100755 index 0000000..b229cc7 --- /dev/null +++ b/.local/bin/app-maps/discord @@ -0,0 +1,6 @@ +#!/bin/sh +if command -v vesktop >/dev/null 2>&1; then + exec vesktop --force-device-scale-factor=1.2 "$@" +else + exec discord "$@" +fi diff --git a/.local/bin/app-maps/threema-beta b/.local/bin/app-maps/threema-beta new file mode 100755 index 0000000..abba033 --- /dev/null +++ b/.local/bin/app-maps/threema-beta @@ -0,0 +1,3 @@ +#!/bin/sh +export XDG_CURRENT_DESKTOP="GNOME" +exec /usr/bin/threema-beta "$@" diff --git a/.local/bin/etc/nvim/compiler b/.local/bin/etc/nvim/compiler index b01bcac..9301230 100755 --- a/.local/bin/etc/nvim/compiler +++ b/.local/bin/etc/nvim/compiler @@ -10,6 +10,7 @@ file=$(readlink -f "$1") dir=$(dirname "$file") base="${file%.*}" basenodir="${1%.*}" +vipercmd="silicon" #"carbon" cd "$dir" || exit @@ -25,6 +26,7 @@ textype() { \ } case "$file" in + *\.vpr) $vipercmd "$file" ;; *\.ms) refer -PS -e "$file" | groff -me -ms -kept -T pdf > "$base".pdf ;; *\.mom) refer -PS -e "$file" | groff -mom -kept -T pdf > "$base".pdf ;; *\.[0-9]) refer -PS -e "$file" | groff -mandoc -T pdf > "$base".pdf ;; @@ -37,10 +39,14 @@ case "$file" in *\.js) node "$file" ;; *\.c) if [ -f Makefile ]; then make run; else cc "$file" -o "$base" && "$base"; fi ;; *\.nim) nim c -r -d:noColors "$file" ;; - *\.py) python "$file" ;; + *\.py) python3 "$file" ;; *\.go) go run "$file" ;; *\.lua) lua "$file" ;; *\.sent) setsid sent "$file" 2>/dev/null & ;; *\.r|*\.R) Rscript "$file" ;; + *\.smt2) z3 "$file" ;; + *\.rs) (cd "$dir" && cargo locate-project >/dev/null 2>&1) \ + && (cd "$(dirname "$(cd "$dir" && cargo locate-project --message-format plain)")" && cargo run) \ + || (rustc "$file" && "./$(basename "${file%.rs}")") ;; *) sed 1q "$file" | grep "^#!/" | sed "s/^#!//" | xargs -r -I % "$file" ;; esac diff --git a/.local/bin/etc/screen_capture/record_replay_start b/.local/bin/etc/screen_capture/record_replay_start index 5bababc..3eadcad 100755 --- a/.local/bin/etc/screen_capture/record_replay_start +++ b/.local/bin/etc/screen_capture/record_replay_start @@ -5,12 +5,19 @@ audio_2=${CAPTURE_OUTPUT_AUDIO:-easyeffects_source} output=${CAPTURE_DIR:-$HOME/downloads} device=${CAPTURE_DEVICE:-cpu} -window=$(xdotool getwindowfocus) fps=60 format="mp4" -v_codec="h264" +v_codec="hevc" +# v_codec="h264" a_codec="opus" lenght=20 + +if [ $DISPLAY_SERVER = "wayland" ]; then + window="screen" +elif [ $DISPLAY_SERVER = "xorg" ]; then + window=$(xdotool getwindowfocus) +fi + gpu-screen-recorder -encoder $device -w $window -f $fps -a $audio_1 -a $audio_2 -c $format -k $v_codec -ac $a_codec -r $lenght -o $output & notify-send -u low 'Screen record' 'Replay started' diff --git a/.local/bin/etc/screen_capture/record_start b/.local/bin/etc/screen_capture/record_start index 946e94b..9f0fb51 100755 --- a/.local/bin/etc/screen_capture/record_start +++ b/.local/bin/etc/screen_capture/record_start @@ -5,12 +5,18 @@ audio_2=${CAPTURE_OUTPUT_AUDIO:-easyeffects_source} output=${CAPTURE_DIR:-$HOME/downloads} device=${CAPTURE_DEVICE:-cpu} -window=$(xdotool getwindowfocus) -fps=30 +fps=60 format="mp4" -v_codec="h264" +v_codec="hevc" +# v_codec="h264" a_codec="aac" output="$output/recording-$(date '+%Y-%m-%d_%H-%M-%S').$format" -gpu-screen-recorder -encoder $device -w $window -c $format -k $v_codec -ac $a_codec -f $fps -o $output & +if [ $DISPLAY_SERVER = "wayland" ]; then + window="screen" +elif [ $DISPLAY_SERVER = "xorg" ]; then + window=$(xdotool getwindowfocus) +fi + +gpu-screen-recorder -encoder $device -w $window -c $format -k $v_codec -ac $a_codec -f $fps -o $output -a $audio_1 -a $audio_2 & notify-send -u low 'Screen record' 'Recording started' diff --git a/.local/bin/etc/statusbar/internet b/.local/bin/etc/statusbar/internet index c776504..e22605a 100755 --- a/.local/bin/etc/statusbar/internet +++ b/.local/bin/etc/statusbar/internet @@ -2,7 +2,7 @@ wifipercent=" 0" -[ "$(cat /sys/class/net/w*/operstate)" = 'down' ] && wifiicon="^c#ff0000^ " && wifistatus="down" +[ "$(cat /sys/class/net/w*/operstate)" = 'down' ] && wifiicon="^c#ff0000^ ^d^ " && wifistatus="down" [ ! -n "${wifiicon+var}" ] && wifistatus="up" && wifipercent=$(grep "^\s*w" /proc/net/wireless | awk '{ print int($3 * 100 / 70) }') @@ -21,5 +21,6 @@ then fi fi +[ -f /sys/class/net/e*/operstate ] && lanicon=$(cat /sys/class/net/e*/operstate | sed "s/down/^b#282828^^c#ff0000^  /;s/up/^b#282828^^c#dfdfdf^ 󰈀 /") || lanicon="^b#282828^^c#ff0000^  " -echo "$(cat /sys/class/net/e*/operstate | sed "s/down/^b#282828^^c#ff0000^  /;s/up/^b#282828^^c#dfdfdf^ 󰈀 /")" "$wifiicon" +echo "$lanicon" "$wifiicon" diff --git a/.local/bin/etc/sxhkd/keymap b/.local/bin/etc/sxhkd/keymap index 29e4c53..1451400 100755 --- a/.local/bin/etc/sxhkd/keymap +++ b/.local/bin/etc/sxhkd/keymap @@ -6,13 +6,13 @@ echo $variant case "$1" in toggle) if [ "$layout" = "de" -a "$variant" = "nodeadkeys" ] then - setxkbmap de && notify-send -u low 'SXHKD' 'Set keymap to german' + setxkbmap de -option compose:rctrl && notify-send -u low 'SXHKD' 'Set keymap to german' elif [ "$layout" = "de" -a "$variant" = "" ] then - setxkbmap de ru && notify-send -u low 'SXHKD' 'Set keymap to russian (german)' + setxkbmap de ru -option compose:rctrl && notify-send -u low 'SXHKD' 'Set keymap to russian (german)' elif [ "$layout" = "de" -a "$variant" = "ru" ] then - setxkbmap de nodeadkeys && notify-send -u low 'SXHKD' 'Set keymap to german (nodeadkeys)' + setxkbmap de nodeadkeys -option compose:rctrl && notify-send -u low 'SXHKD' 'Set keymap to german (nodeadkeys)' fi ;; *) cat << EOF keymap: cli script to change the keymap quickly. diff --git a/.local/bin/etc/sxhkd/screenshot b/.local/bin/etc/sxhkd/screenshot index fa1930d..1e6ed47 100755 --- a/.local/bin/etc/sxhkd/screenshot +++ b/.local/bin/etc/sxhkd/screenshot @@ -9,12 +9,21 @@ output="$output/screenshot-$(date '+%Y-%m-%d_%H-%M-%S').png" xclip_img="xclip -sel clip -t image/png" xclip_txt="xclip -sel clip -t text/plain" -case "$(printf "a selected area\\na selected area (copy)\\ncurrent window\\ncurrent window (copy)\\nfull screen\\nfull screen (copy)\\ncolor picker (copy)" | dmenu -l 6 -i -p "Screenshot which area?")" in - "a selected area") maim -s --hidecursor $output ;; - "a selected area (copy)") maim -s --hidecursor | ${xclip_img} ;; - "current window") maim -i "$(xdotool getactivewindow)" $output ;; - "current window (copy)") maim -i "$(xdotool getactivewindow)" | ${xclip_img} ;; - "full screen") maim $output ;; - "full screen (copy)") maim | ${xclip_img} ;; - "color picker (copy)") xcolor |tr -d '\n' | ${xclip_txt} ;; -esac +if [ $DISPLAY_SERVER = "wayland" ]; then + case "$(printf "a selected area\\na selected area (copy)\\nfull screen\\nfull screen (copy)" | dmenu -l 6 -i -p "Screenshot which area?")" in + "a selected area") grim -g "$(slurp)" $output ;; + "a selected area (copy)") grim -g "$(slurp)" - | wl-copy ;; + "full screen") grim $output ;; + "full screen (copy)") grim - | wl-copy ;; + esac +elif [ $DISPLAY_SERVER = "xorg" ]; then + case "$(printf "a selected area\\na selected area (copy)\\ncurrent window\\ncurrent window (copy)\\nfull screen\\nfull screen (copy)\\ncolor picker (copy)" | dmenu -l 6 -i -p "Screenshot which area?")" in + "a selected area") maim -s --hidecursor $output ;; + "a selected area (copy)") maim -s --hidecursor | ${xclip_img} ;; + "current window") maim -i "$(xdotool getactivewindow)" $output ;; + "current window (copy)") maim -i "$(xdotool getactivewindow)" | ${xclip_img} ;; + "full screen") maim $output ;; + "full screen (copy)") maim | ${xclip_img} ;; + "color picker (copy)") xcolor |tr -d '\n' | ${xclip_txt} ;; + esac +fi diff --git a/.local/bin/etc/sxhkd/touchpad b/.local/bin/etc/sxhkd/touchpad index 80646e0..637c2ba 100755 --- a/.local/bin/etc/sxhkd/touchpad +++ b/.local/bin/etc/sxhkd/touchpad @@ -4,13 +4,17 @@ # by lukesmithxyz, checkout github.com/lukesmithxyz/voidrice case "$1" in - toggle) (synclient | grep "TouchpadOff.*1" && synclient TouchpadOff=0)>/dev/null && notify-send "TouchPad reactivated." && exit - synclient TouchpadOff=1 && notify-send "TouchPad deactivated." ;; + on) synclient TouchpadOff=0 && notify-send "TouchPad activated." ;; + off) synclient TouchpadOff=1 && notify-send "TouchPad deactivated." ;; + toggle) (synclient | grep "TouchpadOff.*1") && touchpad on && exit + touchpad off ;; *) cat << EOF touchpad: cli script to enable and disable the touchpad. Allowed options: - toggle Toggle the touchpad on and off + on Turn touchpad on + off Turn touchpad off + toggle Toggle the touchpad on or off all else Print this message EOF diff --git a/.local/bin/etc/viper/carbon b/.local/bin/etc/viper/carbon new file mode 100755 index 0000000..1b3ca07 --- /dev/null +++ b/.local/bin/etc/viper/carbon @@ -0,0 +1,2 @@ +#!/bin/sh +java -jar "$VIPER_CARBON" --z3Exe "$VIPER_Z3" --boogieExe "$VIPER_BOOGIE" "$@" diff --git a/.local/bin/etc/viper/silicon b/.local/bin/etc/viper/silicon new file mode 100755 index 0000000..3e4376c --- /dev/null +++ b/.local/bin/etc/viper/silicon @@ -0,0 +1,2 @@ +#!/bin/sh +java -jar "$VIPER_SILICON" "$@" diff --git a/.local/bin/tools/wallpaper b/.local/bin/tools/wallpaper index 0c9357b..a044a71 100755 --- a/.local/bin/tools/wallpaper +++ b/.local/bin/tools/wallpaper @@ -3,31 +3,53 @@ # Adapted from a script by lukesmithxyz, checkout github.com/lukesmithxyz/voidrice wall_desk=${WALLPAPER_DESKTOP:-$XDG_DATA_HOME/bg} +lightdm_desk=${WALLPAPER_LIGHTDM:-$XDG_DATA_HOME/lightdm} wall_lock=${WALLPAPER_LOCK:-$XDG_DATA_HOME/lock} case "$1" in + lightdm) trueloc="$(readlink -f "$2")" && + case "$(file --mime-type -b "$trueloc")" in + image/* ) sudo cp "$(readlink -f "$2")" "$lightdm_desk" && notify-send -i "$lightdm_desk" "LightDM wallpaper has been changed." ;; + inode/directory ) sudo cp "$(find "$trueloc" -iregex '.*.\(jpg\|jpeg\|png\|gif\)' -type f | shuf -n 1)" "$lightdm_desk" && notify-send -i "$lightdm_desk" "Random LightDM wallpaper chosen." ;; + *) notify-send "🖼️ Error" "Not a valid image or directory." ; exit 1;; + esac + xwallpaper --stretch "$wall_desk" ;; desktop) trueloc="$(readlink -f "$2")" && case "$(file --mime-type -b "$trueloc")" in image/* ) ln -f "$(readlink -f "$2")" "$wall_desk" && notify-send -i "$wall_desk" "Desktop wallpaper has been changed." ;; inode/directory ) ln -f "$(find "$trueloc" -iregex '.*.\(jpg\|jpeg\|png\|gif\)' -type f | shuf -n 1)" "$wall_desk" && notify-send -i "$wall_desk" "Random desktop wallpaper chosen." ;; *) notify-send "🖼️ Error" "Not a valid image or directory." ; exit 1;; esac - xwallpaper --zoom "$wall_desk" ;; + xwallpaper --stretch "$wall_desk" ;; lock) trueloc="$(readlink -f "$2")" && case "$(file --mime-type -b "$trueloc")" in image/* ) ln -f "$(readlink -f "$2")" "$wall_lock" && notify-send -i "$wall_lock" "Lock screen wallpaper has been changed." ;; inode/directory ) ln -f "$(find "$trueloc" -iregex '.*.\(jpg\|jpeg\|png\|gif\)' -type f | shuf -n 1)" "$wall_lock" && notify-send -i "$wall_lock" "Random lock screen wallpaper chosen." ;; *) notify-send "🖼️ Error" "Not a valid image or directory." ; exit 1;; esac ;; + all) wallpaper lightdm "$2" && + wallpaper lock "$2" && + wallpaper desktop "$2";; *) cat << EOF wallpaper: cli script to set and reset the wallpaper of the desktop and lock screen. Allowed options: + desktop [PATH] Set the wallpaper of the desktop to the specified path. If no path is given reset it. + lock [PATH] Set the wallpaper of the lock screen to the specified path. If no path is given reset it. + + lightdm [PATH] Set the wallpaper of the lightdm screen to the specified + path. + If no path is given reset it. + + all [PATH] Set wallpaper for both lock screen, the dektop and the + lightdm screen to a specified path. + If no path is given reset it. + all else Print this message EOF diff --git a/.local/share/applications/browser.desktop b/.local/share/applications/browser.desktop index a1c16ac..07b0683 100644 --- a/.local/share/applications/browser.desktop +++ b/.local/share/applications/browser.desktop @@ -1,4 +1,4 @@ [Desktop Entry] Type=Application Name=Browser -Exec=$BROWSER %u +Exec=zen-browser %u diff --git a/.local/share/lightdm b/.local/share/lightdm new file mode 120000 index 0000000..e0769f4 --- /dev/null +++ b/.local/share/lightdm @@ -0,0 +1 @@ +/etc/lightdm/background.jpg \ No newline at end of file diff --git a/.profile b/.profile index a469f51..59b3376 100644 --- a/.profile +++ b/.profile @@ -1,8 +1,11 @@ #!/bin/sh # Profile file. Runs on login. +# sets default display server (can be overwritten in ~/.config/profile/local_profile) +export DISPLAY_SERVER="xorg" + # Adds `~/.local/bin` and all subdirectories to $PATH -export PATH="${PATH}:$(du "${HOME}/.local/bin/" | cut -f2 | tr '\n' ':' | sed 's/:*$//')" +export PATH="$(du "${HOME}/.local/bin/" | cut -f2 | tr '\n' ':' | sed 's/:*$//')":${PATH} # Add flatpak to path export PATH="/var/lib/flatpak/exports/bin:${PATH}" @@ -13,7 +16,6 @@ export EDITOR="nvim" export FILE="vifmrun" export IMAGE="sxiv" export READER="zathura" -export STATUSBAR="dwmblocks" export TERMINAL="st" export QT_QPA_PLATFORMTHEME="qt6ct" @@ -40,6 +42,7 @@ export SUDO_ASKPASS="${HOME}/.local/bin/tools/pw_menu" export TMUX_TMPDIR="${XDG_CACHE_HOME}/tmux" export WGETRC="${XDG_CONFIG_HOME}/wgetrc" export ZDOTDIR="${XDG_CONFIG_HOME}/zsh" +export BAT_THEME="Visual Studio Dark+" export CUDA_DIR="/opt/cuda" export CUDA_PATH="/opt/cuda" @@ -61,10 +64,18 @@ export PATH="${GOBIN}:${PATH}" # nim export PATH="${HOME}/.nimble/bin:${PATH}" +# viper +export VIPER_SILICON="" +export VIPER_CARBON="" +export VIPER_Z3="/bin/z3" +export VIPER_BOOGIE="$HOME/.dotnet/tools/boogie" + # python export PYENV_ROOT="$HOME/.pyenv" export PATH="$PYENV_ROOT/bin:$PATH" +eval "$(pyenv init --path)" + # less/man colors export LESS=-R export LESS_TERMCAP_mb="$(printf '%b' '')"; a="${a%_}" @@ -82,5 +93,11 @@ echo "$0" | grep "zsh$" >/dev/null && [ -f ${ZDOTDIR}/.zshrc ] && source "${ZDOT # load optional variables [ -f ~/.config/profile/local_profile ] && source "${HOME}/.config/profile/local_profile" -# Start graphical server if not already running. -[ "$(tty)" = "/dev/tty1" ] && ! pgrep -x Xorg >/dev/null && exec startx +# Start graphical server based on set display server +if [ $DISPLAY_SERVER = "wayland" ]; then + export STATUSBAR="waybar" + dwl -s ~/.config/wayland/wayland.conf +elif [ $DISPLAY_SERVER = "xorg" ]; then + export STATUSBAR="dwmblocks" + [ "$(tty)" = "/dev/tty1" ] && ! pgrep -x Xorg >/dev/null && exec startx +fi diff --git a/.xinitrc b/.xinitrc old mode 100644 new mode 100755 diff --git a/.xsession b/.xsession new file mode 120000 index 0000000..97fc5d0 --- /dev/null +++ b/.xsession @@ -0,0 +1 @@ +/home/user/.xinitrc \ No newline at end of file