diff --git a/Makefile b/Makefile index 89749ad..b5d3187 100644 --- a/Makefile +++ b/Makefile @@ -11,13 +11,13 @@ home: copy-config sudo nixos-rebuild switch --flake /etc/nixos#nixos upgrade: copy-config - sudo nixos-rebuild switch --upgrade --flake /etc/nixos + sudo nixos-rebuild switch --upgrade --flake . debug: copy-config sudo nixos-rebuild switch --flake /etc/nixos --show-trace --verbose up: - sudo nix flake update --flake /etc/nixos + sudo nix flake update --flake . upp: nix flake update ~/nixos/${i} diff --git a/flake.lock b/flake.lock index 1118e43..33024a8 100644 --- a/flake.lock +++ b/flake.lock @@ -68,14 +68,32 @@ "type": "github" } }, + "beaker-src": { + "flake": false, + "locked": { + "lastModified": 1773884524, + "narHash": "sha256-1dnlofWaxI/YRID+WPz2jHZNDyloBubDt/bAQk9ePLU=", + "ref": "refs/heads/master", + "rev": "abc598baf15d6f8a4de395a27ba34b1e769558e1", + "revCount": 21, + "shallow": false, + "type": "git", + "url": "https://git.bwaaa.monster/beaker" + }, + "original": { + "shallow": false, + "type": "git", + "url": "https://git.bwaaa.monster/beaker" + } + }, "firefox-gnome-theme": { "flake": false, "locked": { - "lastModified": 1764873433, - "narHash": "sha256-1XPewtGMi+9wN9Ispoluxunw/RwozuTRVuuQOmxzt+A=", + "lastModified": 1775176642, + "narHash": "sha256-2veEED0Fg7Fsh81tvVDNYR6SzjqQxa7hbi18Jv4LWpM=", "owner": "rafaelmardojai", "repo": "firefox-gnome-theme", - "rev": "f7ffd917ac0d253dbd6a3bf3da06888f57c69f92", + "rev": "179704030c5286c729b5b0522037d1d51341022c", "type": "github" }, "original": { @@ -110,11 +128,11 @@ ] }, "locked": { - "lastModified": 1765835352, - "narHash": "sha256-XswHlK/Qtjasvhd1nOa1e8MgZ8GS//jBoTqWtrS1Giw=", + "lastModified": 1769996383, + "narHash": "sha256-AnYjnFWgS49RlqX7LrC4uA+sCCDBj0Ry/WOJ5XWAsa0=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "a34fae9c08a15ad73f295041fec82323541400a9", + "rev": "57928607ea566b5db3ad13af0e57e921e6b12381", "type": "github" }, "original": { @@ -131,11 +149,11 @@ ] }, "locked": { - "lastModified": 1767609335, - "narHash": "sha256-feveD98mQpptwrAEggBQKJTYbvwwglSbOv53uCfH9PY=", + "lastModified": 1775087534, + "narHash": "sha256-91qqW8lhL7TLwgQWijoGBbiD4t7/q75KTi8NxjVmSmA=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "250481aafeb741edfe23d29195671c19b36b6dca", + "rev": "3107b77cd68437b9a76194f0f7f9c55f2329ca5b", "type": "github" }, "original": { @@ -163,20 +181,18 @@ "gnome-shell": { "flake": false, "locked": { - "host": "gitlab.gnome.org", "lastModified": 1767737596, "narHash": "sha256-eFujfIUQDgWnSJBablOuG+32hCai192yRdrNHTv0a+s=", "owner": "GNOME", "repo": "gnome-shell", "rev": "ef02db02bf0ff342734d525b5767814770d85b49", - "type": "gitlab" + "type": "github" }, "original": { - "host": "gitlab.gnome.org", "owner": "GNOME", - "ref": "gnome-49", "repo": "gnome-shell", - "type": "gitlab" + "rev": "ef02db02bf0ff342734d525b5767814770d85b49", + "type": "github" } }, "home-manager": { @@ -186,11 +202,11 @@ ] }, "locked": { - "lastModified": 1766949189, - "narHash": "sha256-t4lRzHDaAvSNIPcZO4NrjnfeYv+Yvr2BUWkUnoCbuzs=", + "lastModified": 1775683737, + "narHash": "sha256-oBYyowo6yfgb95Z78s3uTnAd9KkpJpwzjJbfnpLaM2Y=", "owner": "nix-community", "repo": "home-manager", - "rev": "398bc87bc89fc05a3c3731884b16e819c52e2b00", + "rev": "7ba4ee4228ed36123c7cb75d50524b43514ef992", "type": "github" }, "original": { @@ -208,11 +224,11 @@ "scenefx": "scenefx" }, "locked": { - "lastModified": 1773464981, - "narHash": "sha256-zKlImlnnf+iJeUke2gthzvmXu0cl8P7vBNRwvjkbsN4=", + "lastModified": 1775461179, + "narHash": "sha256-4vvuk6tl8M2wuW3VJU9Uwc3HCrL95cSJImEODNNQEy8=", "owner": "mangowm", "repo": "mango", - "rev": "32c36ba48548f1b30e929c8a739f838bac72db2f", + "rev": "e83a9dff820ce2215ecbbbea7d617d24d0825174", "type": "github" }, "original": { @@ -223,11 +239,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1766902047, - "narHash": "sha256-5hlaevYkLMeR2+6WThInVkWl0F35ioE4027kXVsglEE=", + "lastModified": 1775728626, + "narHash": "sha256-EhIPCT/tFqqPt4DMQZAUJj953GOZMjlBZq91zj/XWsk=", "owner": "nixos", "repo": "nixpkgs", - "rev": "652f1b042e5fa87705fb952aad193cefc18446f5", + "rev": "0c33d38e5790d4bbf65f0a7f1ac7fe58d2e361f4", "type": "github" }, "original": { @@ -254,18 +270,15 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1766651565, - "narHash": "sha256-QEhk0eXgyIqTpJ/ehZKg9IKS7EtlWxF3N7DXy42zPfU=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "3e2499d5539c16d0d173ba53552a4ff8547f4539", - "type": "github" + "lastModified": 1775036866, + "narHash": "sha256-ByAX1LkhCwZ94+KnFAmnJSMAvui7kgCxjHgUHsWAbfI=", + "rev": "6201e203d09599479a3b3450ed24fa81537ebc4e", + "type": "tarball", + "url": "https://releases.nixos.org/nixos/unstable/nixos-26.05pre972949.6201e203d095/nixexprs.tar.xz" }, "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" + "type": "tarball", + "url": "https://channels.nixos.org/nixos-unstable/nixexprs.tar.xz" } }, "nixvim": { @@ -277,15 +290,15 @@ "systems": "systems" }, "locked": { - "lastModified": 1766941632, - "narHash": "sha256-QB8XEoY5D2iRYntcKzJ5wlvgpqqQSe0P0h5CvBO/rUk=", - "owner": "nix-community", + "lastModified": 1775745046, + "narHash": "sha256-NveNW324sm4uTo5tkoMlTH+wX95J8ZW5sFC6MozMM6g=", + "owner": "elisiei", "repo": "nixvim", - "rev": "ff75a5d3cc674391814c4703464ea1a3db204078", + "rev": "526d737a8d78af80d870b5b602674959d7385c84", "type": "github" }, "original": { - "owner": "nix-community", + "owner": "elisiei", "repo": "nixvim", "type": "github" } @@ -302,11 +315,11 @@ ] }, "locked": { - "lastModified": 1767810917, - "narHash": "sha256-ZKqhk772+v/bujjhla9VABwcvz+hB2IaRyeLT6CFnT0=", + "lastModified": 1775228139, + "narHash": "sha256-ebbeHmg+V7w8050bwQOuhmQHoLOEOfqKzM1KgCTexK4=", "owner": "nix-community", "repo": "NUR", - "rev": "dead29c804adc928d3a69dfe7f9f12d0eec1f1a4", + "rev": "601971b9c89e0304561977f2c28fa25e73aa7132", "type": "github" }, "original": { @@ -315,12 +328,34 @@ "type": "github" } }, + "omnisearch": { + "inputs": { + "beaker-src": "beaker-src", + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1774755469, + "narHash": "sha256-sO6h2JLu7eaxILkHQgdAo7oDc8soqJbIShzlzH79tUw=", + "ref": "refs/heads/master", + "rev": "6b8a278b4f2973391b256eedf6add3d6a3516bc0", + "revCount": 79, + "type": "git", + "url": "https://git.coom.tech/eli/omnisearch" + }, + "original": { + "type": "git", + "url": "https://git.coom.tech/eli/omnisearch" + } + }, "root": { "inputs": { "home-manager": "home-manager", "mangowm": "mangowm", "nixpkgs": "nixpkgs", "nixvim": "nixvim", + "omnisearch": "omnisearch", "spicetify-nix": "spicetify-nix", "stylix": "stylix" } @@ -352,11 +387,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1766897356, - "narHash": "sha256-oKp9luuuXuMoUwpGUKUdt0G7lZGovcyOEI3guG0rNCw=", + "lastModified": 1775421933, + "narHash": "sha256-JkEbzFDFTsUlVtHEzA8Y4r3O9LInhb96eOCbtGjGnbM=", "owner": "Gerg-L", "repo": "spicetify-nix", - "rev": "6b49c4094e93629af2fcf789e0897450f57e2551", + "rev": "ec8d73085fdf807d55765335dc8126e14e7b2096", "type": "github" }, "original": { @@ -379,22 +414,22 @@ ], "nur": "nur", "systems": "systems_3", - "tinted-foot": "tinted-foot", "tinted-kitty": "tinted-kitty", "tinted-schemes": "tinted-schemes", "tinted-tmux": "tinted-tmux", "tinted-zed": "tinted-zed" }, "locked": { - "lastModified": 1771626923, - "narHash": "sha256-Mn6oeKrY+Sw6kH0jK+hp5QQH4MTcqwBRQL/ScZDNcz8=", - "owner": "nix-community", + "lastModified": 1775244614, + "narHash": "sha256-eVKt8wpQqg6Hq/UdHQkV1izXGloGQxdlE4SSk9/X27s=", + "owner": "MrSom3body-contrib", "repo": "stylix", - "rev": "b09847414b50c65788936199918272377f70fb91", + "rev": "20adcebacda98b176e7ecc4b988c5cbef57bd2f4", "type": "github" }, "original": { - "owner": "nix-community", + "owner": "MrSom3body-contrib", + "ref": "fix/foot-theme", "repo": "stylix", "type": "github" } @@ -444,23 +479,6 @@ "type": "github" } }, - "tinted-foot": { - "flake": false, - "locked": { - "lastModified": 1726913040, - "narHash": "sha256-+eDZPkw7efMNUf3/Pv0EmsidqdwNJ1TaOum6k7lngDQ=", - "owner": "tinted-theming", - "repo": "tinted-foot", - "rev": "fd1b924b6c45c3e4465e8a849e67ea82933fcbe4", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "tinted-foot", - "rev": "fd1b924b6c45c3e4465e8a849e67ea82933fcbe4", - "type": "github" - } - }, "tinted-kitty": { "flake": false, "locked": { @@ -480,11 +498,11 @@ "tinted-schemes": { "flake": false, "locked": { - "lastModified": 1767710407, - "narHash": "sha256-+W1EB79Jl0/gm4JqmO0Nuc5C7hRdp4vfsV/VdzI+des=", + "lastModified": 1772661346, + "narHash": "sha256-4eu3LqB9tPqe0Vaqxd4wkZiBbthLbpb7llcoE/p5HT0=", "owner": "tinted-theming", "repo": "schemes", - "rev": "2800e2b8ac90f678d7e4acebe4fa253f602e05b2", + "rev": "13b5b0c299982bb361039601e2d72587d6846294", "type": "github" }, "original": { @@ -496,11 +514,11 @@ "tinted-tmux": { "flake": false, "locked": { - "lastModified": 1767489635, - "narHash": "sha256-e6nnFnWXKBCJjCv4QG4bbcouJ6y3yeT70V9MofL32lU=", + "lastModified": 1772934010, + "narHash": "sha256-x+6+4UvaG+RBRQ6UaX+o6DjEg28u4eqhVRM9kpgJGjQ=", "owner": "tinted-theming", "repo": "tinted-tmux", - "rev": "3c32729ccae99be44fe8a125d20be06f8d7d8184", + "rev": "c3529673a5ab6e1b6830f618c45d9ce1bcdd829d", "type": "github" }, "original": { @@ -512,11 +530,11 @@ "tinted-zed": { "flake": false, "locked": { - "lastModified": 1767488740, - "narHash": "sha256-wVOj0qyil8m+ouSsVZcNjl5ZR+1GdOOAooAatQXHbuU=", + "lastModified": 1772909925, + "narHash": "sha256-jx/5+pgYR0noHa3hk2esin18VMbnPSvWPL5bBjfTIAU=", "owner": "tinted-theming", "repo": "base16-zed", - "rev": "11abb0b282ad3786a2aae088d3a01c60916f2e40", + "rev": "b4d3a1b3bcbd090937ef609a0a3b37237af974df", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index bd64dfb..eb54925 100644 --- a/flake.nix +++ b/flake.nix @@ -12,13 +12,13 @@ # nvim nixvim = { - url = "github:nix-community/nixvim"; + url = "github:elisiei/nixvim"; inputs.nixpkgs.follows = "nixpkgs"; }; # stylix (thx esteban) stylix = { - url = "github:nix-community/stylix"; + url = "github:MrSom3body-contrib/stylix/fix/foot-theme"; inputs.nixpkgs.follows = "nixpkgs"; }; @@ -27,41 +27,51 @@ url = "github:mangowm/mango"; inputs.nixpkgs.follows = "nixpkgs"; }; - }; - outputs = inputs @ { - nixpkgs, - home-manager, - stylix, - spicetify-nix, - nixvim, - mangowm, - ... - }: { - nixosConfigurations = { - nixos = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = {inherit inputs;}; - modules = [ - ./nixos/configuration.nix - home-manager.nixosModules.home-manager - { - home-manager.useGlobalPkgs = true; - home-manager.useUserPackages = true; - home-manager.users.elisiei = { - imports = [ - ./home/home.nix - spicetify-nix.homeManagerModules.spicetify - stylix.homeModules.stylix - nixvim.homeModules.nixvim - mangowm.hmModules.mango - ]; - }; - home-manager.backupFileExtension = "hm-backup"; - home-manager.extraSpecialArgs = {inherit inputs;}; - } - ]; - }; + # omnisearch + omnisearch = { + url = "git+https://git.coom.tech/eli/omnisearch"; + inputs.nixpkgs.follows = "nixpkgs"; }; }; + + outputs = + inputs@{ + nixpkgs, + home-manager, + stylix, + spicetify-nix, + nixvim, + mangowm, + omnisearch, + ... + }: + { + nixosConfigurations = { + nixos = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + specialArgs = { inherit inputs; }; + modules = [ + ./nixos/configuration.nix + home-manager.nixosModules.home-manager + omnisearch.nixosModules.default + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.users.elisiei = { + imports = [ + ./home/home.nix + spicetify-nix.homeManagerModules.spicetify + stylix.homeModules.stylix + nixvim.homeModules.nixvim + mangowm.hmModules.mango + ]; + }; + home-manager.backupFileExtension = "hm-backup"; + home-manager.extraSpecialArgs = { inherit inputs; }; + } + ]; + }; + }; + }; } diff --git a/home/home.nix b/home/home.nix index 81fdbb9..eb56391 100644 --- a/home/home.nix +++ b/home/home.nix @@ -3,15 +3,14 @@ ./packages.nix # wm - # ./modules/wm/sway/default.nix ./modules/wm/mango/default.nix + ./modules/wm/mango/waybar.nix # editors ./modules/ide/nvim/default.nix # terminal stuff ./modules/terminal/foot/default.nix - ./modules/terminal/st/default.nix # shell stuff ./modules/shell/bash/default.nix @@ -19,7 +18,6 @@ # user stuff ./modules/user/direnv/default.nix - ./modules/user/bemenu/default.nix ./modules/user/dunst/default.nix ./modules/user/git/default.nix ./modules/user/stylix/default.nix diff --git a/home/modules/ide/nvim/default.nix b/home/modules/ide/nvim/default.nix index b7313c0..e6d9601 100644 --- a/home/modules/ide/nvim/default.nix +++ b/home/modules/ide/nvim/default.nix @@ -1,6 +1,4 @@ { - imports = [./lsp/v-analyzer.nix]; - programs.nixvim = { enable = true; @@ -18,9 +16,10 @@ ./plugins/starter.nix ./plugins/snippets.nix ./plugins/which-key.nix - ./plugins/conform.nix ./plugins/treesitter.nix ./plugins/term.nix + ./plugins/telescope.nix + ./plugins/conform.nix # lsp ./lsp/default.nix diff --git a/home/modules/ide/nvim/keymaps.nix b/home/modules/ide/nvim/keymaps.nix index db32a95..39b0064 100644 --- a/home/modules/ide/nvim/keymaps.nix +++ b/home/modules/ide/nvim/keymaps.nix @@ -1,57 +1,92 @@ { keymaps = [ { - key = "e"; - action.__raw = '' - function() - require("neo-tree.command").execute({ - toggle = true, - dir = vim.fn.getcwd() - }) - end - ''; + action = "Neotree focus"; + key = "e"; } { - key = "ff"; - mode = ["n"]; - action = "lua Snacks.picker.files()"; - options.desc = "find files"; - } - { - key = "gr"; - mode = ["n"]; - action = "lua Snacks.picker.grep()"; - options.desc = "find grep"; - } - { - key = "gl"; - mode = ["n"]; - action = "lua Snacks.picker.git_log()"; - options.desc = "git log"; - } - { - key = "gs"; - mode = ["n"]; - action = "lua Snacks.picker.git_status()"; - options.desc = "git status"; - } - { - key = "uC"; - mode = ["n"]; - action = "lua Snacks.picker.colorschemes()"; - options.desc = "colorschemes"; - } - { - key = ":"; - mode = ["n"]; - action = "lua Snacks.picker.command_history()"; - options.desc = "command history"; + mode = [ + "n" + "i" + "t" + ]; + key = ""; + action = "wincmd k"; + options = { + desc = "Move to window above"; + noremap = true; + silent = true; + }; + } + + { + mode = [ + "n" + "i" + "t" + ]; + key = ""; + action = "wincmd j"; + options = { + desc = "Move to window below"; + noremap = true; + silent = true; + }; } { + mode = [ + "n" + "i" + "t" + ]; key = ""; - mode = ["n"]; - action = "Neotree source=filesystem focus"; - options.desc = "switch focus"; + action = "wincmd h"; + options = { + desc = "Move to window left"; + noremap = true; + silent = true; + }; + } + + { + mode = [ + "n" + "i" + "t" + ]; + key = ""; + action = "wincmd l"; + options = { + desc = "Move to window right"; + noremap = true; + silent = true; + }; + } + + # telescope + { + action = "Telescope live_grep"; + key = "ts"; + } + { + action = "Telescope find_files"; + key = "tf"; + } + { + action = "Telescope git_commits"; + key = "tc"; + } + { + action = "Telescope oldfiles"; + key = "th"; + } + { + action = "Telescope buffers"; + key = "tb"; + } + { + action = "Telescope colorscheme"; + key = "ch"; } ]; } diff --git a/home/modules/ide/nvim/lsp/default.nix b/home/modules/ide/nvim/lsp/default.nix index bb29c6a..63fca76 100644 --- a/home/modules/ide/nvim/lsp/default.nix +++ b/home/modules/ide/nvim/lsp/default.nix @@ -4,6 +4,7 @@ ./go.nix ./v.nix ./web.nix + ./elixir.nix ]; plugins = { lsp = { @@ -62,6 +63,8 @@ }; }; lsp-lines.enable = true; - lsp-format.enable = true; + lsp-format = { + enable = true; + }; }; } diff --git a/home/modules/ide/nvim/lsp/elixir.nix b/home/modules/ide/nvim/lsp/elixir.nix new file mode 100644 index 0000000..c5823b5 --- /dev/null +++ b/home/modules/ide/nvim/lsp/elixir.nix @@ -0,0 +1,6 @@ +{ + plugins.lsp.servers.elixirls = { + enable = true; + }; + +} diff --git a/home/modules/ide/nvim/lsp/nixd.nix b/home/modules/ide/nvim/lsp/nixd.nix index f16e4dd..f44ba20 100644 --- a/home/modules/ide/nvim/lsp/nixd.nix +++ b/home/modules/ide/nvim/lsp/nixd.nix @@ -1,7 +1,21 @@ -{ +{pkgs, ...}: { plugins.lsp = { servers = { nixd.enable = true; }; }; + plugins.lsp-format = { + settings = { + go = { + exclude = ["gopls"]; + force = true; + order = ["goimports" "gopls"]; + sync = true; + }; + }; + }; + extraPackages = with pkgs; [ + gopls + gotools + ]; } diff --git a/home/modules/ide/nvim/lsp/v-analyzer.nix b/home/modules/ide/nvim/lsp/v-analyzer.nix deleted file mode 100644 index 3c60cd6..0000000 --- a/home/modules/ide/nvim/lsp/v-analyzer.nix +++ /dev/null @@ -1,31 +0,0 @@ -# from https://github.com/dimkauzh/nixos/blob/a60627bbf45d249b115f0ba0296e02676dd988ea/modules/home/programs/v-analyzer.nix -{pkgs, ...}: let - settingsFormat = pkgs.formats.toml {}; - - vAnalyzerSettings = { - custom_vroot = "${pkgs.vlang}/lib"; - enable_semantic_tokens = "full"; - - inlay_hints = { - enable = true; - enable_range_hints = true; - enable_type_hints = true; - enable_implicit_err_hints = true; - enable_parameter_name_hints = true; - enable_constant_type_hints = true; - enable_enum_field_value_hints = true; - }; - - code_lens = { - enable = true; - enable_run_lens = true; - enable_inheritors_lens = true; - enable_super_interfaces_lens = true; - enable_run_tests_lens = true; - }; - }; - - analyzerSettingsFile = settingsFormat.generate "config.toml" vAnalyzerSettings; -in { - home.file.".config/v-analyzer/config.toml".source = analyzerSettingsFile; -} diff --git a/home/modules/ide/nvim/options.nix b/home/modules/ide/nvim/options.nix index aa97c21..71fee5e 100644 --- a/home/modules/ide/nvim/options.nix +++ b/home/modules/ide/nvim/options.nix @@ -1,43 +1,44 @@ -{pkgs, ...}: { - opts = { +{ + globalOpts = { number = true; relativenumber = false; - colorcolumn = "0"; - shiftwidth = 2; - tabstop = 2; - wrap = false; - swapfile = false; # undotree - backup = false; # undotree - undofile = true; - hlsearch = false; - incsearch = true; - termguicolors = true; - scrolloff = 8; - signcolumn = "no"; - updatetime = 50; - foldlevelstart = 99; + signcolumn = "yes"; + ignorecase = true; + smartcase = true; + tabstop = 4; + shiftwidth = 4; + softtabstop = 0; + expandtab = true; + smarttab = true; + clipboard = "unnamedplus"; + cursorline = true; + ruler = true; + gdefault = true; + scrolloff = 5; }; - clipboard = { - register = "unnamedplus"; + opts = { + foldenable = true; + foldmethod = "expr"; + foldexpr = "v:lua.vim.treesitter.foldexpr()"; + foldtext = ""; + foldlevel = 99; + foldlevelstart = 99; + foldcolumn = "0"; + }; + + userCommands = { + Q.command = "q"; + Q.bang = true; + Wq.command = "q"; + Wq.bang = true; + WQ.command = "q"; + WQ.bang = true; + W.command = "q"; + W.bang = true; }; globals.mapleader = " "; - extraPackages = with pkgs; [ - # lsp - typescript - typescript-language-server - svelte-language-server - # misc - stylua - nixfmt-rfc-style - vlang - ]; - - extraPlugins = with pkgs; [ - vimPlugins.vim-crystal - ]; - extraConfigLua = builtins.readFile ./config.lua; } diff --git a/home/modules/ide/nvim/plugins/conform.nix b/home/modules/ide/nvim/plugins/conform.nix index 85e4333..c9f44da 100644 --- a/home/modules/ide/nvim/plugins/conform.nix +++ b/home/modules/ide/nvim/plugins/conform.nix @@ -8,16 +8,16 @@ }; formatters_by_ft = { - nix = ["alejandra"]; + nix = ["nixfmt"]; go = ["goimports"]; }; }; }; extraPackages = with pkgs; [ - alejandra - go + nixfmt gopls gotools ]; } + diff --git a/home/modules/ide/nvim/plugins/files.nix b/home/modules/ide/nvim/plugins/files.nix index 708972c..a1bb2a4 100644 --- a/home/modules/ide/nvim/plugins/files.nix +++ b/home/modules/ide/nvim/plugins/files.nix @@ -1,8 +1,4 @@ { - plugins.snacks = { - enable = true; - autoLoad = true; - }; plugins.neo-tree = { enable = true; settings = { diff --git a/home/modules/ide/nvim/plugins/telescope.nix b/home/modules/ide/nvim/plugins/telescope.nix new file mode 100644 index 0000000..189e5a3 --- /dev/null +++ b/home/modules/ide/nvim/plugins/telescope.nix @@ -0,0 +1,10 @@ +{ + plugins.telescope = { + enable = true; + extensions = { + fzf-native = { + enable = true; + }; + }; + }; +} diff --git a/home/modules/ide/nvim/plugins/treesitter.nix b/home/modules/ide/nvim/plugins/treesitter.nix index 3f288c1..0297548 100644 --- a/home/modules/ide/nvim/plugins/treesitter.nix +++ b/home/modules/ide/nvim/plugins/treesitter.nix @@ -1,29 +1,31 @@ {pkgs, ...}: { + extraPackages = [pkgs.tree-sitter]; + plugins.treesitter = { enable = true; + grammarPackages = pkgs.vimPlugins.nvim-treesitter.passthru.allGrammars; + settings = { - indent = { - enable = true; - }; + textobjects.enable = true; + highlight = { enable = true; + + disable = '' + function(lang, bufnr) + return vim.api.nvim_buf_line_count(bufnr) > 10000 + end + ''; }; - }; - nixvimInjections = true; - grammarPackages = pkgs.vimPlugins.nvim-treesitter.allGrammars; - }; + incremental_selection = { + enable = true; + }; - treesitter-context = { - enable = false; - }; - - treesitter-textobjects = { - enable = true; - settings.select = { - enable = true; - lookahead = true; + indent = { + enable = false; + }; }; }; } diff --git a/home/modules/terminal/st/config.h b/home/modules/terminal/st/config.h deleted file mode 100644 index 4b34c46..0000000 --- a/home/modules/terminal/st/config.h +++ /dev/null @@ -1,475 +0,0 @@ -/* See LICENSE file for copyright and license details. */ - -/* - * appearance - * - * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html - */ -static char *font = "Maple Mono NF:pixelsize=16:antialias=true:autohint=true"; -static int borderpx = 5; - -/* - * What program is execed by st depends of these precedence rules: - * 1: program passed with -e - * 2: scroll and/or utmp - * 3: SHELL environment variable - * 4: value of shell in /etc/passwd - * 5: value of shell in config.h - */ -static char *shell = "fish"; -char *utmp = NULL; -/* scroll program: to enable use a string like "scroll" */ -char *scroll = NULL; -char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400"; - -/* identification sequence returned in DA and DECID */ -char *vtiden = "\033[?6c"; - -/* Kerning / character bounding-box multipliers */ -static float cwscale = 1.0; -static float chscale = 1.0; - -/* - * word delimiter string - * - * More advanced example: L" `'\"()[]{}" - */ -wchar_t *worddelimiters = L" "; - -/* selection timeouts (in milliseconds) */ -static unsigned int doubleclicktimeout = 300; -static unsigned int tripleclicktimeout = 600; - -/* alt screens */ -int allowaltscreen = 1; - -/* allow certain non-interactive (insecure) window operations such as: - setting the clipboard text */ -int allowwindowops = 0; - -/* - * draw latency range in ms - from new content/keypress/etc until drawing. - * within this range, st draws when content stops arriving (idle). mostly it's - * near minlatency, but it waits longer for slow updates to avoid partial draw. - * low minlatency will tear/flicker more, as it can "detect" idle too early. - */ -static double minlatency = 2; -static double maxlatency = 33; - -/* - * blinking timeout (set to 0 to disable blinking) for the terminal blinking - * attribute. - */ -static unsigned int blinktimeout = 800; - -/* - * thickness of underline and bar cursors - */ -static unsigned int cursorthickness = 1; - -/* - * bell volume. It must be a value between -100 and 100. Use 0 for disabling - * it - */ -static int bellvolume = 0; - -/* default TERM value */ -char *termname = "st"; - -/* - * spaces per tab - * - * When you are changing this value, don't forget to adapt the »it« value in - * the st.info and appropriately install the st.info in the environment where - * you use this st version. - * - * it#$tabspaces, - * - * Secondly make sure your kernel is not expanding tabs. When running `stty - * -a` »tab0« should appear. You can tell the terminal to not expand tabs by - * running following command: - * - * stty tabs - */ -unsigned int tabspaces = 8; - -/* Terminal colors (16 first used in escape sequence) */ -static const char *colorname[] = { - /* 8 normal colors */ - "black", - "red3", - "green3", - "yellow3", - "blue2", - "magenta3", - "cyan3", - "gray90", - - /* 8 bright colors */ - "gray50", - "red", - "green", - "yellow", - "#5c5cff", - "magenta", - "cyan", - "white", - - [255] = 0, - - /* more colors can be added after 255 to use with DefaultXX */ - "#cccccc", - "#555555", - "gray90", /* default foreground colour */ - "black", /* default background colour */ -}; - - -/* - * Default colors (colorname index) - * foreground, background, cursor, reverse cursor - */ -unsigned int defaultfg = 258; -unsigned int defaultbg = 259; -unsigned int defaultcs = 256; -static unsigned int defaultrcs = 257; - -/* - * Default shape of cursor - * 2: Block ("█") - * 4: Underline ("_") - * 6: Bar ("|") - * 7: Snowman ("☃") - */ -static unsigned int cursorshape = 2; - -/* - * Default columns and rows numbers - */ - -static unsigned int cols = 80; -static unsigned int rows = 24; - -/* - * Default colour and shape of the mouse cursor - */ -static unsigned int mouseshape = XC_xterm; -static unsigned int mousefg = 7; -static unsigned int mousebg = 0; - -/* - * Color used to display font attributes when fontconfig selected a font which - * doesn't match the ones requested. - */ -static unsigned int defaultattr = 11; - -/* - * Force mouse select/shortcuts while mask is active (when MODE_MOUSE is set). - * Note that if you want to use ShiftMask with selmasks, set this to an other - * modifier, set to 0 to not use it. - */ -static uint forcemousemod = ShiftMask; - -/* - * Internal mouse shortcuts. - * Beware that overloading Button1 will disable the selection. - */ -static MouseShortcut mshortcuts[] = { - /* mask button function argument release */ - { XK_ANY_MOD, Button2, selpaste, {.i = 0}, 1 }, - { ShiftMask, Button4, ttysend, {.s = "\033[5;2~"} }, - { XK_ANY_MOD, Button4, ttysend, {.s = "\031"} }, - { ShiftMask, Button5, ttysend, {.s = "\033[6;2~"} }, - { XK_ANY_MOD, Button5, ttysend, {.s = "\005"} }, -}; - -/* Internal keyboard shortcuts. */ -#define MODKEY Mod1Mask -#define TERMMOD (ControlMask|ShiftMask) - -static Shortcut shortcuts[] = { - /* mask keysym function argument */ - { XK_ANY_MOD, XK_Break, sendbreak, {.i = 0} }, - { ControlMask, XK_Print, toggleprinter, {.i = 0} }, - { ShiftMask, XK_Print, printscreen, {.i = 0} }, - { XK_ANY_MOD, XK_Print, printsel, {.i = 0} }, - { TERMMOD, XK_Prior, zoom, {.f = +1} }, - { TERMMOD, XK_Next, zoom, {.f = -1} }, - { TERMMOD, XK_Home, zoomreset, {.f = 0} }, - { TERMMOD, XK_C, clipcopy, {.i = 0} }, - { TERMMOD, XK_V, clippaste, {.i = 0} }, - { TERMMOD, XK_Y, selpaste, {.i = 0} }, - { ShiftMask, XK_Insert, selpaste, {.i = 0} }, - { TERMMOD, XK_Num_Lock, numlock, {.i = 0} }, -}; - -/* - * Special keys (change & recompile st.info accordingly) - * - * Mask value: - * * Use XK_ANY_MOD to match the key no matter modifiers state - * * Use XK_NO_MOD to match the key alone (no modifiers) - * appkey value: - * * 0: no value - * * > 0: keypad application mode enabled - * * = 2: term.numlock = 1 - * * < 0: keypad application mode disabled - * appcursor value: - * * 0: no value - * * > 0: cursor application mode enabled - * * < 0: cursor application mode disabled - * - * Be careful with the order of the definitions because st searches in - * this table sequentially, so any XK_ANY_MOD must be in the last - * position for a key. - */ - -/* - * If you want keys other than the X11 function keys (0xFD00 - 0xFFFF) - * to be mapped below, add them to this array. - */ -static KeySym mappedkeys[] = { -1 }; - -/* - * State bits to ignore when matching key or button events. By default, - * numlock (Mod2Mask) and keyboard layout (XK_SWITCH_MOD) are ignored. - */ -static uint ignoremod = Mod2Mask|XK_SWITCH_MOD; - -/* - * This is the huge key array which defines all compatibility to the Linux - * world. Please decide about changes wisely. - */ -static Key key[] = { - /* keysym mask string appkey appcursor */ - { XK_KP_Home, ShiftMask, "\033[2J", 0, -1}, - { XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1}, - { XK_KP_Home, XK_ANY_MOD, "\033[H", 0, -1}, - { XK_KP_Home, XK_ANY_MOD, "\033[1~", 0, +1}, - { XK_KP_Up, XK_ANY_MOD, "\033Ox", +1, 0}, - { XK_KP_Up, XK_ANY_MOD, "\033[A", 0, -1}, - { XK_KP_Up, XK_ANY_MOD, "\033OA", 0, +1}, - { XK_KP_Down, XK_ANY_MOD, "\033Or", +1, 0}, - { XK_KP_Down, XK_ANY_MOD, "\033[B", 0, -1}, - { XK_KP_Down, XK_ANY_MOD, "\033OB", 0, +1}, - { XK_KP_Left, XK_ANY_MOD, "\033Ot", +1, 0}, - { XK_KP_Left, XK_ANY_MOD, "\033[D", 0, -1}, - { XK_KP_Left, XK_ANY_MOD, "\033OD", 0, +1}, - { XK_KP_Right, XK_ANY_MOD, "\033Ov", +1, 0}, - { XK_KP_Right, XK_ANY_MOD, "\033[C", 0, -1}, - { XK_KP_Right, XK_ANY_MOD, "\033OC", 0, +1}, - { XK_KP_Prior, ShiftMask, "\033[5;2~", 0, 0}, - { XK_KP_Prior, XK_ANY_MOD, "\033[5~", 0, 0}, - { XK_KP_Begin, XK_ANY_MOD, "\033[E", 0, 0}, - { XK_KP_End, ControlMask, "\033[J", -1, 0}, - { XK_KP_End, ControlMask, "\033[1;5F", +1, 0}, - { XK_KP_End, ShiftMask, "\033[K", -1, 0}, - { XK_KP_End, ShiftMask, "\033[1;2F", +1, 0}, - { XK_KP_End, XK_ANY_MOD, "\033[4~", 0, 0}, - { XK_KP_Next, ShiftMask, "\033[6;2~", 0, 0}, - { XK_KP_Next, XK_ANY_MOD, "\033[6~", 0, 0}, - { XK_KP_Insert, ShiftMask, "\033[2;2~", +1, 0}, - { XK_KP_Insert, ShiftMask, "\033[4l", -1, 0}, - { XK_KP_Insert, ControlMask, "\033[L", -1, 0}, - { XK_KP_Insert, ControlMask, "\033[2;5~", +1, 0}, - { XK_KP_Insert, XK_ANY_MOD, "\033[4h", -1, 0}, - { XK_KP_Insert, XK_ANY_MOD, "\033[2~", +1, 0}, - { XK_KP_Delete, ControlMask, "\033[M", -1, 0}, - { XK_KP_Delete, ControlMask, "\033[3;5~", +1, 0}, - { XK_KP_Delete, ShiftMask, "\033[2K", -1, 0}, - { XK_KP_Delete, ShiftMask, "\033[3;2~", +1, 0}, - { XK_KP_Delete, XK_ANY_MOD, "\033[P", -1, 0}, - { XK_KP_Delete, XK_ANY_MOD, "\033[3~", +1, 0}, - { XK_KP_Multiply, XK_ANY_MOD, "\033Oj", +2, 0}, - { XK_KP_Add, XK_ANY_MOD, "\033Ok", +2, 0}, - { XK_KP_Enter, XK_ANY_MOD, "\033OM", +2, 0}, - { XK_KP_Enter, XK_ANY_MOD, "\r", -1, 0}, - { XK_KP_Subtract, XK_ANY_MOD, "\033Om", +2, 0}, - { XK_KP_Decimal, XK_ANY_MOD, "\033On", +2, 0}, - { XK_KP_Divide, XK_ANY_MOD, "\033Oo", +2, 0}, - { XK_KP_0, XK_ANY_MOD, "\033Op", +2, 0}, - { XK_KP_1, XK_ANY_MOD, "\033Oq", +2, 0}, - { XK_KP_2, XK_ANY_MOD, "\033Or", +2, 0}, - { XK_KP_3, XK_ANY_MOD, "\033Os", +2, 0}, - { XK_KP_4, XK_ANY_MOD, "\033Ot", +2, 0}, - { XK_KP_5, XK_ANY_MOD, "\033Ou", +2, 0}, - { XK_KP_6, XK_ANY_MOD, "\033Ov", +2, 0}, - { XK_KP_7, XK_ANY_MOD, "\033Ow", +2, 0}, - { XK_KP_8, XK_ANY_MOD, "\033Ox", +2, 0}, - { XK_KP_9, XK_ANY_MOD, "\033Oy", +2, 0}, - { XK_Up, ShiftMask, "\033[1;2A", 0, 0}, - { XK_Up, Mod1Mask, "\033[1;3A", 0, 0}, - { XK_Up, ShiftMask|Mod1Mask,"\033[1;4A", 0, 0}, - { XK_Up, ControlMask, "\033[1;5A", 0, 0}, - { XK_Up, ShiftMask|ControlMask,"\033[1;6A", 0, 0}, - { XK_Up, ControlMask|Mod1Mask,"\033[1;7A", 0, 0}, - { XK_Up,ShiftMask|ControlMask|Mod1Mask,"\033[1;8A", 0, 0}, - { XK_Up, XK_ANY_MOD, "\033[A", 0, -1}, - { XK_Up, XK_ANY_MOD, "\033OA", 0, +1}, - { XK_Down, ShiftMask, "\033[1;2B", 0, 0}, - { XK_Down, Mod1Mask, "\033[1;3B", 0, 0}, - { XK_Down, ShiftMask|Mod1Mask,"\033[1;4B", 0, 0}, - { XK_Down, ControlMask, "\033[1;5B", 0, 0}, - { XK_Down, ShiftMask|ControlMask,"\033[1;6B", 0, 0}, - { XK_Down, ControlMask|Mod1Mask,"\033[1;7B", 0, 0}, - { XK_Down,ShiftMask|ControlMask|Mod1Mask,"\033[1;8B",0, 0}, - { XK_Down, XK_ANY_MOD, "\033[B", 0, -1}, - { XK_Down, XK_ANY_MOD, "\033OB", 0, +1}, - { XK_Left, ShiftMask, "\033[1;2D", 0, 0}, - { XK_Left, Mod1Mask, "\033[1;3D", 0, 0}, - { XK_Left, ShiftMask|Mod1Mask,"\033[1;4D", 0, 0}, - { XK_Left, ControlMask, "\033[1;5D", 0, 0}, - { XK_Left, ShiftMask|ControlMask,"\033[1;6D", 0, 0}, - { XK_Left, ControlMask|Mod1Mask,"\033[1;7D", 0, 0}, - { XK_Left,ShiftMask|ControlMask|Mod1Mask,"\033[1;8D",0, 0}, - { XK_Left, XK_ANY_MOD, "\033[D", 0, -1}, - { XK_Left, XK_ANY_MOD, "\033OD", 0, +1}, - { XK_Right, ShiftMask, "\033[1;2C", 0, 0}, - { XK_Right, Mod1Mask, "\033[1;3C", 0, 0}, - { XK_Right, ShiftMask|Mod1Mask,"\033[1;4C", 0, 0}, - { XK_Right, ControlMask, "\033[1;5C", 0, 0}, - { XK_Right, ShiftMask|ControlMask,"\033[1;6C", 0, 0}, - { XK_Right, ControlMask|Mod1Mask,"\033[1;7C", 0, 0}, - { XK_Right,ShiftMask|ControlMask|Mod1Mask,"\033[1;8C",0, 0}, - { XK_Right, XK_ANY_MOD, "\033[C", 0, -1}, - { XK_Right, XK_ANY_MOD, "\033OC", 0, +1}, - { XK_ISO_Left_Tab, ShiftMask, "\033[Z", 0, 0}, - { XK_Return, Mod1Mask, "\033\r", 0, 0}, - { XK_Return, XK_ANY_MOD, "\r", 0, 0}, - { XK_Insert, ShiftMask, "\033[4l", -1, 0}, - { XK_Insert, ShiftMask, "\033[2;2~", +1, 0}, - { XK_Insert, ControlMask, "\033[L", -1, 0}, - { XK_Insert, ControlMask, "\033[2;5~", +1, 0}, - { XK_Insert, XK_ANY_MOD, "\033[4h", -1, 0}, - { XK_Insert, XK_ANY_MOD, "\033[2~", +1, 0}, - { XK_Delete, ControlMask, "\033[M", -1, 0}, - { XK_Delete, ControlMask, "\033[3;5~", +1, 0}, - { XK_Delete, ShiftMask, "\033[2K", -1, 0}, - { XK_Delete, ShiftMask, "\033[3;2~", +1, 0}, - { XK_Delete, XK_ANY_MOD, "\033[P", -1, 0}, - { XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0}, - { XK_BackSpace, XK_NO_MOD, "\177", 0, 0}, - { XK_BackSpace, Mod1Mask, "\033\177", 0, 0}, - { XK_Home, ShiftMask, "\033[2J", 0, -1}, - { XK_Home, ShiftMask, "\033[1;2H", 0, +1}, - { XK_Home, XK_ANY_MOD, "\033[H", 0, -1}, - { XK_Home, XK_ANY_MOD, "\033[1~", 0, +1}, - { XK_End, ControlMask, "\033[J", -1, 0}, - { XK_End, ControlMask, "\033[1;5F", +1, 0}, - { XK_End, ShiftMask, "\033[K", -1, 0}, - { XK_End, ShiftMask, "\033[1;2F", +1, 0}, - { XK_End, XK_ANY_MOD, "\033[4~", 0, 0}, - { XK_Prior, ControlMask, "\033[5;5~", 0, 0}, - { XK_Prior, ShiftMask, "\033[5;2~", 0, 0}, - { XK_Prior, XK_ANY_MOD, "\033[5~", 0, 0}, - { XK_Next, ControlMask, "\033[6;5~", 0, 0}, - { XK_Next, ShiftMask, "\033[6;2~", 0, 0}, - { XK_Next, XK_ANY_MOD, "\033[6~", 0, 0}, - { XK_F1, XK_NO_MOD, "\033OP" , 0, 0}, - { XK_F1, /* F13 */ ShiftMask, "\033[1;2P", 0, 0}, - { XK_F1, /* F25 */ ControlMask, "\033[1;5P", 0, 0}, - { XK_F1, /* F37 */ Mod4Mask, "\033[1;6P", 0, 0}, - { XK_F1, /* F49 */ Mod1Mask, "\033[1;3P", 0, 0}, - { XK_F1, /* F61 */ Mod3Mask, "\033[1;4P", 0, 0}, - { XK_F2, XK_NO_MOD, "\033OQ" , 0, 0}, - { XK_F2, /* F14 */ ShiftMask, "\033[1;2Q", 0, 0}, - { XK_F2, /* F26 */ ControlMask, "\033[1;5Q", 0, 0}, - { XK_F2, /* F38 */ Mod4Mask, "\033[1;6Q", 0, 0}, - { XK_F2, /* F50 */ Mod1Mask, "\033[1;3Q", 0, 0}, - { XK_F2, /* F62 */ Mod3Mask, "\033[1;4Q", 0, 0}, - { XK_F3, XK_NO_MOD, "\033OR" , 0, 0}, - { XK_F3, /* F15 */ ShiftMask, "\033[1;2R", 0, 0}, - { XK_F3, /* F27 */ ControlMask, "\033[1;5R", 0, 0}, - { XK_F3, /* F39 */ Mod4Mask, "\033[1;6R", 0, 0}, - { XK_F3, /* F51 */ Mod1Mask, "\033[1;3R", 0, 0}, - { XK_F3, /* F63 */ Mod3Mask, "\033[1;4R", 0, 0}, - { XK_F4, XK_NO_MOD, "\033OS" , 0, 0}, - { XK_F4, /* F16 */ ShiftMask, "\033[1;2S", 0, 0}, - { XK_F4, /* F28 */ ControlMask, "\033[1;5S", 0, 0}, - { XK_F4, /* F40 */ Mod4Mask, "\033[1;6S", 0, 0}, - { XK_F4, /* F52 */ Mod1Mask, "\033[1;3S", 0, 0}, - { XK_F5, XK_NO_MOD, "\033[15~", 0, 0}, - { XK_F5, /* F17 */ ShiftMask, "\033[15;2~", 0, 0}, - { XK_F5, /* F29 */ ControlMask, "\033[15;5~", 0, 0}, - { XK_F5, /* F41 */ Mod4Mask, "\033[15;6~", 0, 0}, - { XK_F5, /* F53 */ Mod1Mask, "\033[15;3~", 0, 0}, - { XK_F6, XK_NO_MOD, "\033[17~", 0, 0}, - { XK_F6, /* F18 */ ShiftMask, "\033[17;2~", 0, 0}, - { XK_F6, /* F30 */ ControlMask, "\033[17;5~", 0, 0}, - { XK_F6, /* F42 */ Mod4Mask, "\033[17;6~", 0, 0}, - { XK_F6, /* F54 */ Mod1Mask, "\033[17;3~", 0, 0}, - { XK_F7, XK_NO_MOD, "\033[18~", 0, 0}, - { XK_F7, /* F19 */ ShiftMask, "\033[18;2~", 0, 0}, - { XK_F7, /* F31 */ ControlMask, "\033[18;5~", 0, 0}, - { XK_F7, /* F43 */ Mod4Mask, "\033[18;6~", 0, 0}, - { XK_F7, /* F55 */ Mod1Mask, "\033[18;3~", 0, 0}, - { XK_F8, XK_NO_MOD, "\033[19~", 0, 0}, - { XK_F8, /* F20 */ ShiftMask, "\033[19;2~", 0, 0}, - { XK_F8, /* F32 */ ControlMask, "\033[19;5~", 0, 0}, - { XK_F8, /* F44 */ Mod4Mask, "\033[19;6~", 0, 0}, - { XK_F8, /* F56 */ Mod1Mask, "\033[19;3~", 0, 0}, - { XK_F9, XK_NO_MOD, "\033[20~", 0, 0}, - { XK_F9, /* F21 */ ShiftMask, "\033[20;2~", 0, 0}, - { XK_F9, /* F33 */ ControlMask, "\033[20;5~", 0, 0}, - { XK_F9, /* F45 */ Mod4Mask, "\033[20;6~", 0, 0}, - { XK_F9, /* F57 */ Mod1Mask, "\033[20;3~", 0, 0}, - { XK_F10, XK_NO_MOD, "\033[21~", 0, 0}, - { XK_F10, /* F22 */ ShiftMask, "\033[21;2~", 0, 0}, - { XK_F10, /* F34 */ ControlMask, "\033[21;5~", 0, 0}, - { XK_F10, /* F46 */ Mod4Mask, "\033[21;6~", 0, 0}, - { XK_F10, /* F58 */ Mod1Mask, "\033[21;3~", 0, 0}, - { XK_F11, XK_NO_MOD, "\033[23~", 0, 0}, - { XK_F11, /* F23 */ ShiftMask, "\033[23;2~", 0, 0}, - { XK_F11, /* F35 */ ControlMask, "\033[23;5~", 0, 0}, - { XK_F11, /* F47 */ Mod4Mask, "\033[23;6~", 0, 0}, - { XK_F11, /* F59 */ Mod1Mask, "\033[23;3~", 0, 0}, - { XK_F12, XK_NO_MOD, "\033[24~", 0, 0}, - { XK_F12, /* F24 */ ShiftMask, "\033[24;2~", 0, 0}, - { XK_F12, /* F36 */ ControlMask, "\033[24;5~", 0, 0}, - { XK_F12, /* F48 */ Mod4Mask, "\033[24;6~", 0, 0}, - { XK_F12, /* F60 */ Mod1Mask, "\033[24;3~", 0, 0}, - { XK_F13, XK_NO_MOD, "\033[1;2P", 0, 0}, - { XK_F14, XK_NO_MOD, "\033[1;2Q", 0, 0}, - { XK_F15, XK_NO_MOD, "\033[1;2R", 0, 0}, - { XK_F16, XK_NO_MOD, "\033[1;2S", 0, 0}, - { XK_F17, XK_NO_MOD, "\033[15;2~", 0, 0}, - { XK_F18, XK_NO_MOD, "\033[17;2~", 0, 0}, - { XK_F19, XK_NO_MOD, "\033[18;2~", 0, 0}, - { XK_F20, XK_NO_MOD, "\033[19;2~", 0, 0}, - { XK_F21, XK_NO_MOD, "\033[20;2~", 0, 0}, - { XK_F22, XK_NO_MOD, "\033[21;2~", 0, 0}, - { XK_F23, XK_NO_MOD, "\033[23;2~", 0, 0}, - { XK_F24, XK_NO_MOD, "\033[24;2~", 0, 0}, - { XK_F25, XK_NO_MOD, "\033[1;5P", 0, 0}, - { XK_F26, XK_NO_MOD, "\033[1;5Q", 0, 0}, - { XK_F27, XK_NO_MOD, "\033[1;5R", 0, 0}, - { XK_F28, XK_NO_MOD, "\033[1;5S", 0, 0}, - { XK_F29, XK_NO_MOD, "\033[15;5~", 0, 0}, - { XK_F30, XK_NO_MOD, "\033[17;5~", 0, 0}, - { XK_F31, XK_NO_MOD, "\033[18;5~", 0, 0}, - { XK_F32, XK_NO_MOD, "\033[19;5~", 0, 0}, - { XK_F33, XK_NO_MOD, "\033[20;5~", 0, 0}, - { XK_F34, XK_NO_MOD, "\033[21;5~", 0, 0}, - { XK_F35, XK_NO_MOD, "\033[23;5~", 0, 0}, -}; - -/* - * Selection types' masks. - * Use the same masks as usual. - * Button1Mask is always unset, to make masks match between ButtonPress. - * ButtonRelease and MotionNotify. - * If no match is found, regular selection is used. - */ -static uint selmasks[] = { - [SEL_RECTANGULAR] = Mod1Mask, -}; - -/* - * Printable characters in ASCII, used to estimate the advance width - * of single wide characters. - */ -static char ascii_printable[] = - " !\"#$%&'()*+,-./0123456789:;<=>?" - "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_" - "`abcdefghijklmnopqrstuvwxyz{|}~"; - diff --git a/home/modules/terminal/st/default.nix b/home/modules/terminal/st/default.nix deleted file mode 100644 index 36b0aaf..0000000 --- a/home/modules/terminal/st/default.nix +++ /dev/null @@ -1,20 +0,0 @@ -{pkgs, ...}: { - home.packages = with pkgs; [ - (st.overrideAttrs (oldAttrs: rec { - buildInputs = oldAttrs.buildInputs ++ [harfbuzz]; - patches = [ - (fetchpatch { - url = "https://st.suckless.org/patches/scrollback/st-scrollback-ringbuffer-0.9.2.diff"; - sha256 = "1r23q4mi5bkam49ld5c3ccwaa1li7bbjx0ndjgm207p02az9h4cn"; - }) - (fetchpatch { - url = "https://st.suckless.org/patches/scrollback/st-scrollback-mouse-0.9.2.diff"; - sha256 = "068s5rjvvw2174y34i5xxvpw4jvjy58akd1kgf025h1153hmf7jy"; - }) - ]; - - configFile = writeText "config.def.h" (builtins.readFile ./config.h); - postPatch = "${oldAttrs.postPatch}\n cp ${configFile} config.def.h"; - })) - ]; -} diff --git a/home/modules/user/bemenu/default.nix b/home/modules/user/bemenu/default.nix deleted file mode 100644 index 2496ddb..0000000 --- a/home/modules/user/bemenu/default.nix +++ /dev/null @@ -1,12 +0,0 @@ -{ - programs.bemenu = { - enable = true; - settings = { - border = 0; - list = "5 down"; - width-factor = 1.0; - line-height = 25; - center = true; - }; - }; -} diff --git a/home/modules/user/stylix/default.nix b/home/modules/user/stylix/default.nix index 5e0dee0..8179725 100644 --- a/home/modules/user/stylix/default.nix +++ b/home/modules/user/stylix/default.nix @@ -3,7 +3,7 @@ enable = true; autoEnable = true; polarity = "dark"; - base16Scheme = ./pitchblack.yaml; + base16Scheme = "${pkgs.base16-schemes}/share/themes/kanagawa-dragon.yaml"; icons = { enable = true; diff --git a/home/modules/user/tofi/default.nix b/home/modules/user/tofi/default.nix deleted file mode 100644 index 7bff802..0000000 --- a/home/modules/user/tofi/default.nix +++ /dev/null @@ -1,16 +0,0 @@ -{lib, ...}: { - programs.tofi = { - enable = true; - settings = { - border-width = 0; - height = "100%"; - num-results = 5; - outline-width = 0; - padding-left = "35%"; - font-size = lib.mkForce 24; - padding-top = "35%"; - result-spacing = 25; - width = "100%"; - }; - }; -} diff --git a/home/modules/wm/mango/default.nix b/home/modules/wm/mango/default.nix index 4c2b857..a2293ba 100644 --- a/home/modules/wm/mango/default.nix +++ b/home/modules/wm/mango/default.nix @@ -11,209 +11,20 @@ in { enable = true; autostart_sh = '' - dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP + dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP systemctl --user start pipewire systemctl --user start xdg-desktop-portal - ${wallpaperScript}/bin/random-wallpaper & + systemctl --user import-environment WAYLAND_DISPLAY DISPLAY XDG_CURRENT_DESKTOP PATH + systemctl --user start mango-session.target + ${pkgs.waybar}/bin/waybar & + ${wallpaperScript}/bin/random-wallpaper & ''; - settings = '' - blur=0 - blur_layer=0 - blur_optimized=1 - blur_params_num_passes=2 - blur_params_radius=5 - blur_params_noise=0.02 - blur_params_brightness=0.9 - blur_params_contrast=0.9 - blur_params_saturation=1.2 - - shadows=0 - layer_shadows=0 - shadow_only_floating=1 - shadows_size=10 - shadows_blur=15 - shadows_position_x=0 - shadows_position_y=0 - shadowscolor=0x000000ff - - border_radius=0 - no_radius_when_single=0 - focused_opacity=1.0 - unfocused_opacity=0.99 - - animations=1 - layer_animations=1 - animation_type_open=slide - animation_type_close=slide - animation_fade_in=1 - animation_fade_out=1 - tag_animation_direction=1 - zoom_initial_ratio=0.3 - zoom_end_ratio=0.8 - fadein_begin_opacity=0.5 - fadeout_begin_opacity=0.8 - animation_duration_move=500 - animation_duration_open=400 - animation_duration_tag=350 - animation_duration_close=800 - animation_duration_focus=0 - animation_curve_open=0.46,1.0,0.29,1 - animation_curve_move=0.46,1.0,0.29,1 - animation_curve_tag=0.46,1.0,0.29,1 - animation_curve_close=0.08,0.92,0,1 - animation_curve_focus=0.46,1.0,0.29,1 - animation_curve_opafadeout=0.5,0.5,0.5,0.5 - animation_curve_opafadein=0.46,1.0,0.29,1 - - scroller_structs=0 - scroller_default_proportion=0.5 - scroller_focus_center=0 - scroller_prefer_center=0 - edge_scroller_pointer_focus=1 - scroller_default_proportion_single=1.0 - scroller_proportion_preset=0.5,0.8,1.0 - - new_is_master=1 - default_mfact=0.55 - default_nmaster=1 - smartgaps=0 - - enable_hotarea=0 - ov_tab_mode=0 - overviewgappi=5 - overviewgappo=30 - - no_border_when_single=0 - axis_bind_apply_timeout=100 - focus_on_activate=1 - idleinhibit_ignore_visible=0 - sloppyfocus=1 - warpcursor=1 - focus_cross_monitor=0 - focus_cross_tag=0 - enable_floating_snap=0 - snap_distance=30 - drag_tile_to_tile=1 - - repeat_rate=25 - repeat_delay=600 - numlockon=1 - xkb_rules_layout=es,ru - xkb_rules_options=grp:alt_space_toggle - - disable_trackpad=0 - tap_to_click=1 - tap_and_drag=1 - drag_lock=1 - trackpad_natural_scrolling=0 - disable_while_typing=1 - left_handed=0 - middle_button_emulation=0 - swipe_min_threshold=1 - - mouse_natural_scrolling=0 - - gappih=3 - gappiv=3 - gappoh=3 - gappov=3 - borderpx=0 - cursor_size=24 - rootcolor=0x000000ff - bordercolor=0x2a2a2aff - focuscolor=0x3a3a3aff - urgentcolor=0x5a5a5aff - - tagrule=id:1,layout_name:deck - tagrule=id:2,layout_name:scroller - tagrule=id:3,layout_name:scroller - tagrule=id:4,layout_name:scroller - tagrule=id:5,layout_name:scroller - tagrule=id:6,layout_name:scroller - tagrule=id:7,layout_name:scroller - tagrule=id:8,layout_name:scroller - tagrule=id:9,layout_name:scroller - - bind=SUPER,space,spawn,sh -c "WAYLAND_DISPLAY=$WAYLAND_DISPLAY bemenu-run" - bind=SUPER,t,spawn,foot - bind=SUPER,z,spawn,firefox - bind=SUPER,r,spawn,st - bind=SUPER,w,spawn,${wallpaperScript}/bin/random-wallpaper - - bind=SUPER+SHIFT,Print,spawn,~/bin/sss screen - bind=SUPER,Print,spawn,~/bin/sss area - - bind=SUPER,q,killclient, - bind=ALT,backslash,togglefloating, - bind=SUPER,s,toggle_scratchpad - - bind=SUPER,Tab,focusstack,next - bind=SUPER,Left,focusdir,left - bind=SUPER,Right,focusdir,right - bind=SUPER,Up,focusdir,up - bind=SUPER,Down,focusdir,down - - bind=CTRL+ALT,Left,resizewin,-50,+0 - bind=CTRL+ALT,Right,resizewin,+50,+0 - bind=CTRL+ALT,Up,resizewin,+0,-50 - bind=CTRL+ALT,Down,resizewin,+0,+50 - - bind=CTRL+SHIFT,Left,movewin,-50,+0 - bind=CTRL+SHIFT,Right,movewin,+50,+0 - bind=CTRL+SHIFT,Up,movewin,+0,-50 - bind=CTRL+SHIFT,Down,movewin,+0,+50 - - bind=SUPER,1,view,1,0 - bind=SUPER,2,view,2,0 - bind=SUPER,3,view,3,0 - bind=SUPER,4,view,4,0 - bind=SUPER,5,view,5,0 - bind=SUPER,6,view,6,0 - bind=SUPER,7,view,7,0 - bind=SUPER,8,view,8,0 - bind=SUPER,9,view,9,0 - bind=SUPER,0,view,10,0 - - bind=SUPER+SHIFT,1,tag,1,0 - bind=SUPER+SHIFT,2,tag,2,0 - bind=SUPER+SHIFT,3,tag,3,0 - bind=SUPER+SHIFT,4,tag,4,0 - bind=SUPER+SHIFT,5,tag,5,0 - bind=SUPER+SHIFT,6,tag,6,0 - bind=SUPER+SHIFT,7,tag,7,0 - bind=SUPER+SHIFT,8,tag,8,0 - bind=SUPER+SHIFT,9,tag,9,0 - bind=SUPER+SHIFT,0,tag,10,0 - - bind=ALT+SHIFT,Left,focusmon,left - bind=ALT+SHIFT,Right,focusmon,right - bind=SUPER+ALT,Left,tagmon,left - bind=SUPER+ALT,Right,tagmon,right - - bind=ALT+SHIFT,X,incgaps,1 - bind=ALT+SHIFT,Z,incgaps,-1 - bind=ALT+SHIFT,R,togglegaps - - mousebind=SUPER,btn_left,moveresize,curmove - mousebind=SUPER,btn_right,moveresize,curresize - mousebind=NONE,btn_left,toggleoverview,1 - - axisbind=SUPER,UP,viewtoleft_have_client - axisbind=SUPER,DOWN,viewtoright_have_client - - cursor_size=24 - cursor_theme=macOS - - exec=${wallpaperScript}/bin/random-wallpaper - exec-once=~/.config/mango/autostart.sh - ''; + settings = builtins.readFile ./mango.conf; }; home.sessionVariables = { XCURSOR_THEME = "macOS"; XCURSOR_SIZE = "24"; - XDG_CURRENT_DESKTOP = "mango"; - BEMENU_BACKEND = "wayland"; }; } diff --git a/home/modules/wm/mango/mango.conf b/home/modules/wm/mango/mango.conf new file mode 100644 index 0000000..8c85420 --- /dev/null +++ b/home/modules/wm/mango/mango.conf @@ -0,0 +1,236 @@ +# blur +blur=0 +blur_layer=0 +blur_optimized=1 +blur_params_num_passes=2 +blur_params_radius=5 +blur_params_noise=0.02 +blur_params_brightness=0.9 +blur_params_contrast=0.9 +blur_params_saturation=1.2 + +# shadows +shadows=0 +layer_shadows=0 +shadow_only_floating=1 +shadows_size=10 +shadows_blur=15 +shadows_position_x=0 +shadows_position_y=0 +shadowscolor=0x000000ff + +# colors +rootcolor=0x323232ff +bordercolor=0x262626ff +focuscolor=0x3a3a3aff +urgentcolor=0xad401fff + +# window appearance +border_radius=0 +no_radius_when_single=0 +focused_opacity=0.98 +unfocused_opacity=0.95 + +# animations +animations=1 +layer_animations=1 +animation_type_open=slide +animation_type_close=slide +animation_fade_in=1 +animation_fade_out=1 +tag_animation_direction=1 + +zoom_initial_ratio=0.92 +zoom_end_ratio=1.0 +fadein_begin_opacity=0.2 +fadeout_begin_opacity=0.9 + +# durations +animation_duration_move=180 +animation_duration_open=220 +animation_duration_tag=220 +animation_duration_close=180 +animation_duration_focus=120 + +# curves +animation_curve_open=0.22,1,0.36,1 +animation_curve_move=0.22,1,0.36,1 +animation_curve_tag=0.22,1,0.36,1 +animation_curve_close=0.4,0,0.2,1 +animation_curve_focus=0.22,1,0.36,1 +animation_curve_opafadeout=0.4,0,0.2,1 +animation_curve_opafadein=0.22,1,0.36,1 + +# scroller +scroller_structs=0 +scroller_default_proportion=0.8 +scroller_focus_center=0 +scroller_prefer_center=0 +scroller_prefer_overspread=1 +edge_scroller_pointer_focus=0 +scroller_proportion_preset=0.5,0.8,1.0 +scroller_ignore_proportion_single=0 +scroller_default_proportion_single=1.0 + +# layout +new_is_master=1 +default_mfact=0.55 +default_nmaster=1 +smartgaps=0 + +# overview +enable_hotarea=0 +ov_tab_mode=0 +overviewgappi=5 +overviewgappo=30 + +# window behavior +no_border_when_single=0 +axis_bind_apply_timeout=100 +focus_on_activate=1 +idleinhibit_ignore_visible=0 +sloppyfocus=1 +warpcursor=1 +focus_cross_monitor=0 +focus_cross_tag=0 + +enable_floating_snap=0 +snap_distance=30 +drag_tile_to_tile=1 + +# keyboard +repeat_rate=25 +repeat_delay=600 +numlockon=1 + +xkb_rules_layout=es,ru +xkb_rules_options=grp:alt_space_toggle + +# trackpad +disable_trackpad=0 +tap_to_click=1 +tap_and_drag=1 +drag_lock=1 +trackpad_natural_scrolling=0 +disable_while_typing=1 +left_handed=0 +middle_button_emulation=0 +swipe_min_threshold=1 + +# mouse +mouse_natural_scrolling=0 + +# gaps and borders +gappih=3 +gappiv=3 +gappoh=3 +gappov=3 +borderpx=1 + +# tag rules +tagrule=id:1,layout_name:tiling +tagrule=id:2,layout_name:scroller +tagrule=id:3,layout_name:scroller +tagrule=id:4,layout_name:scroller +tagrule=id:5,layout_name:scroller +tagrule=id:6,layout_name:scroller +tagrule=id:7,layout_name:scroller +tagrule=id:8,layout_name:scroller +tagrule=id:9,layout_name:scroller + +# application binds +bind=SUPER,space,spawn,wmenu-run +bind=SUPER,t,spawn,foot +bind=SUPER,z,spawn,firefox + +# screenshots +bind=SUPER+SHIFT,Print,spawn,~/bin/sss screen +bind=SUPER,Print,spawn,~/bin/sss area + +# wallpaper +bind=SUPER,w,spawn,random-wallpaper + +# window control +bind=SUPER,q,killclient, +bind=SUPER,v,togglefloating, +bind=SUPER,s,toggle_scratchpad + +# focus navigation +bind=SUPER,Tab,focusstack,next +bind=SUPER,Left,focusdir,left +bind=SUPER,Right,focusdir,right +bind=SUPER,Up,focusdir,up +bind=SUPER,Down,focusdir,down + +# resize windows +bind=CTRL+ALT,Left,resizewin,-50,+0 +bind=CTRL+ALT,Right,resizewin,+50,+0 +bind=CTRL+ALT,Up,resizewin,+0,-50 +bind=CTRL+ALT,Down,resizewin,+0,+50 + +# move windows +bind=CTRL+SHIFT,Left,movewin,-50,+0 +bind=CTRL+SHIFT,Right,movewin,+50,+0 +bind=CTRL+SHIFT,Up,movewin,+0,-50 +bind=CTRL+SHIFT,Down,movewin,+0,+50 + +# view tags +bind=SUPER,1,view,1,0 +bind=SUPER,2,view,2,0 +bind=SUPER,3,view,3,0 +bind=SUPER,4,view,4,0 +bind=SUPER,5,view,5,0 +bind=SUPER,6,view,6,0 +bind=SUPER,7,view,7,0 +bind=SUPER,8,view,8,0 +bind=SUPER,9,view,9,0 +bind=SUPER,0,view,10,0 + +# tag windows +bind=SUPER+SHIFT,1,tag,1,0 +bind=SUPER+SHIFT,2,tag,2,0 +bind=SUPER+SHIFT,3,tag,3,0 +bind=SUPER+SHIFT,4,tag,4,0 +bind=SUPER+SHIFT,5,tag,5,0 +bind=SUPER+SHIFT,6,tag,6,0 +bind=SUPER+SHIFT,7,tag,7,0 +bind=SUPER+SHIFT,8,tag,8,0 +bind=SUPER+SHIFT,9,tag,9,0 +bind=SUPER+SHIFT,0,tag,10,0 + +# monitor control +bind=ALT+SHIFT,Left,focusmon,left +bind=ALT+SHIFT,Right,focusmon,right +bind=SUPER+ALT,Left,tagmon,left +bind=SUPER+ALT,Right,tagmon,right + +# gaps control +bind=ALT+SHIFT,X,incgaps,1 +bind=ALT+SHIFT,Z,incgaps,-1 +bind=ALT+SHIFT,R,togglegaps + +# mouse bindings +mousebind=SUPER,btn_left,moveresize,curmove +mousebind=SUPER,btn_right,moveresize,curresize + +# axis bindings +axisbind=SUPER,UP,viewtoleft_have_client +axisbind=SUPER,DOWN,viewtoright_have_client + +# cursor +cursor_size=24 +cursor_theme=macOS + +# environment +env=XDG_CURRENT_DESKTOP,wlroots +env=XDG_SESSION_TYPE,wayland +env=GDK_BACKEND,wayland +env=SDL_VIDEODRIVER,wayland +env=CLUTTER_BACKEND,wayland +env=MOZ_ENABLE_WAYLAND,1 +env=OZONE_PLATFORM,wayland +env=ELECTRON_OZONE_PLATFORM_HINT,auto +env=QT_AUTO_SCREEN_SCALE_FACTOR,1 + +# autostart +exec-once=~/.config/mango/autostart.sh diff --git a/home/modules/wm/mango/style.css b/home/modules/wm/mango/style.css new file mode 100644 index 0000000..bd69574 --- /dev/null +++ b/home/modules/wm/mango/style.css @@ -0,0 +1,52 @@ +* { + border: none; + border-radius: 0; + font-family: "Maple Mono NF"; + font-size: 12px; + min-height: 0; +} + +window#waybar { + background: #000000; + color: #bbbbbb; + border-bottom: 1px solid #262626; +} + +/* workspaces */ +#workspaces { + margin: 0; + padding: 0; + border-bottom: 1px solid #262626; +} + +#workspaces button { + padding: 0 6px; + margin: 0; + background: transparent; + color: #bbbbbb; +} + +#workspaces button.active { + background: transparent; + color: #eeeeee; +} + +#window { + padding: 0 6px; + color: #bbbbbb; +} + +/* right modules */ +#cpu, +#memory, +#pulseaudio, +#clock { + padding: 0 6px; + color: #bbbbbb; +} + +/* remove weird Waybar defaults */ +tooltip { + background: #222222; + border: 1px solid #444444; +} diff --git a/home/modules/wm/mango/waybar.nix b/home/modules/wm/mango/waybar.nix new file mode 100644 index 0000000..a938588 --- /dev/null +++ b/home/modules/wm/mango/waybar.nix @@ -0,0 +1,53 @@ +{lib, ...}: { + programs.waybar = { + enable = true; + + style = lib.mkForce ./style.css; + settings = [ + { + layer = "top"; + position = "top"; + height = 22; + + modules-left = ["ext/workspaces"]; + modules-center = ["dwl/window"]; + modules-right = [ + "cpu" + "memory" + "pulseaudio" + "clock" + ]; + + "ext/workspaces" = { + disable-scroll = true; + all-outputs = true; + format = "{name}"; + }; + + "dwl/window" = { + format = "{title}"; + max-length = 80; + }; + + cpu = { + format = "cpu {usage}%"; + interval = 3; + }; + + memory = { + format = "mem {percentage}%"; + interval = 3; + }; + + pulseaudio = { + format = "vol {volume}%"; + format-muted = "vol mute"; + }; + + clock = { + format = "{:%Y-%m-%d %H:%M}"; + }; + } + ]; + }; +} diff --git a/home/packages.nix b/home/packages.nix index 73d3280..1135be6 100644 --- a/home/packages.nix +++ b/home/packages.nix @@ -8,5 +8,6 @@ zig kdePackages.dolphin gnome.gvfs + wmenu ]; } diff --git a/nixos/configuration.nix b/nixos/configuration.nix index f144ca7..06221ce 100644 --- a/nixos/configuration.nix +++ b/nixos/configuration.nix @@ -1,4 +1,5 @@ -{inputs, ...}: { +{ inputs, ... }: +{ imports = [ inputs.spicetify-nix.nixosModules.default @@ -16,6 +17,7 @@ # ./modules/gaming.nix ]; + services.omnisearch.enable = true; nix.settings.experimental-features = [ "nix-command" "flakes" diff --git a/nixos/modules/networking.nix b/nixos/modules/networking.nix index 845d215..9575e69 100644 --- a/nixos/modules/networking.nix +++ b/nixos/modules/networking.nix @@ -4,4 +4,18 @@ # Configure network proxy if necessary # networking.proxy.default = "http://user:password@proxy:port/"; # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; + + networking.hosts = { + "127.0.0.1" = ["ooo.ooo"]; + }; + + services.caddy = { + enable = true; + + virtualHosts."http://ooo.ooo".extraConfig = '' + reverse_proxy https://test.elisiei.xyz { + header_up Host test.elisiei.xyz + } + ''; + }; } diff --git a/nixos/modules/programs.nix b/nixos/modules/programs.nix index 04fa1c3..8016a32 100644 --- a/nixos/modules/programs.nix +++ b/nixos/modules/programs.nix @@ -8,6 +8,11 @@ security.polkit.enable = true; + virtualisation.podman = { + enable = true; + dockerCompat = true; + }; + environment.systemPackages = with pkgs; [ # essential curl @@ -20,7 +25,7 @@ git-credential-manager pipewire pulseaudio - xdg-desktop-portal-wlr + distrobox # notifications libnotify diff --git a/nixos/modules/user.nix b/nixos/modules/user.nix index cea5169..6ba9dde 100644 --- a/nixos/modules/user.nix +++ b/nixos/modules/user.nix @@ -1,5 +1,4 @@ -{ pkgs, ... }: -{ +{pkgs, ...}: { users.users.elisiei = { isNormalUser = true; description = "elisiei"; @@ -8,6 +7,7 @@ "wheel" "video" "audio" + "podman" ]; shell = pkgs.fishMinimal; }; diff --git a/nixos/modules/xserver.nix b/nixos/modules/xserver.nix index 8604d39..a14d9b4 100644 --- a/nixos/modules/xserver.nix +++ b/nixos/modules/xserver.nix @@ -15,7 +15,7 @@ package = config.boot.kernelPackages.nvidiaPackages.stable; open = false; # closed-source driver prime = { - offload.enable = true; + sync.enable = true; intelBusId = "PCI:0:2:0"; nvidiaBusId = "PCI:1:0:0"; }; @@ -41,6 +41,8 @@ enable = true; wlr.enable = true; extraPortals = with pkgs; [ + xdg-desktop-portal + xdg-desktop-portal-gtk xdg-desktop-portal-wlr ]; };