From 91208038b036d40583681dfa9b0583a6cbf1c521 Mon Sep 17 00:00:00 2001 From: luqmanishere Date: Thu, 25 Apr 2024 09:04:39 +0800 Subject: [PATCH] 90% migration to flake-parts --- .github/workflows/system.yml | 17 + .vscode/settings.json | 3 + archives/flake.nix | 222 ---- archives/home-manager/anyrun/config.ron | 45 - archives/home-manager/doom-emacs/config.el | 90 -- archives/home-manager/doom-emacs/init.el | 194 ---- archives/home-manager/doom-emacs/packages.el | 51 - .../doom-emacs/themes/catppuccin-theme.el | 1020 ----------------- archives/home-manager/dunst.nix | 76 -- archives/home-manager/emacs.nix | 97 -- archives/home-manager/graphical.nix | 184 --- archives/home-manager/hyprland.conf | 218 ---- archives/home-manager/hyprland.nix | 91 -- archives/home-manager/kitty.nix | 36 - archives/home-manager/luqman-desktop.nix | 76 -- archives/home-manager/luqman-kurumi.nix | 298 ----- archives/home-manager/luqman-sinon.nix | 332 ------ archives/home-manager/modules/default.nix | 8 - archives/home-manager/modules/modules.nix | 14 - archives/home-manager/modules/tools/fonts.nix | 32 - .../home-manager/modules/tools/starship.nix | 53 - archives/home-manager/modules/tools/task.nix | 69 -- archives/home-manager/mpd.nix | 98 -- archives/home-manager/neomutt.nix | 27 - .../home-manager/nvim/lazyvim-conf/.gitignore | 8 - .../nvim/lazyvim-conf/.neoconf.json | 15 - .../home-manager/nvim/lazyvim-conf/init.lua | 2 - .../nvim/lazyvim-conf/lua/config/autocmds.lua | 3 - .../nvim/lazyvim-conf/lua/config/keymaps.lua | 20 - .../nvim/lazyvim-conf/lua/config/lazy.lua | 48 - .../nvim/lazyvim-conf/lua/config/options.lua | 9 - .../nvim/lazyvim-conf/lua/plugins/example.lua | 267 ----- .../nvim/lazyvim-conf/lua/plugins/lsp.lua | 176 --- .../nvim/lazyvim-conf/lua/plugins/rust.lua | 21 - .../nvim/lazyvim-conf/lua/plugins/ui.lua | 52 - .../nvim/lazyvim-conf/stylua.toml | 3 - archives/home-manager/nvim/lazyvim-nvim.nix | 56 - archives/home-manager/rofi.nix | 39 - archives/home-manager/syncthing.nix | 26 - archives/home-manager/waybar.nix | 37 - archives/home-manager/wezterm.nix | 32 - archives/modules/home-manager/default.nix | 8 - .../modules/home-manager/secrets/module.nix | 22 - archives/modules/nixos/cloudflare-warp.nix | 114 -- archives/modules/nixos/default.nix | 10 - flake.lock | 321 +++--- flake.nix | 146 +-- .../browsers/firefox.nix | 0 home/configopts.nix | 4 + home/default.nix | 51 + .../editors/astronvim/config/.neoconf.json | 0 .../editors/astronvim/config/README.md | 0 .../editors/astronvim/config/init.lua | 0 .../astronvim/config/lua/community.lua | 0 .../astronvim/config/lua/lazy_setup.lua | 0 .../config/lua/plugins/astrocore.lua | 0 .../astronvim/config/lua/plugins/astrolsp.lua | 0 .../astronvim/config/lua/plugins/astroui.lua | 0 .../astronvim/config/lua/plugins/chezmoi.lua | 0 .../astronvim/config/lua/plugins/cmp.lua | 0 .../astronvim/config/lua/plugins/mason.lua | 0 .../astronvim/config/lua/plugins/neorg.lua | 0 .../astronvim/config/lua/plugins/neovide.lua | 0 .../astronvim/config/lua/plugins/none-ls.lua | 0 .../astronvim/config/lua/plugins/term.lua | 0 .../config/lua/plugins/treesitter.lua | 0 .../astronvim/config/lua/plugins/user.lua | 0 .../editors/astronvim/config/lua/polish.lua | 0 .../editors/astronvim/config/neovim.yml | 0 .../editors/astronvim/config/selene.toml | 0 .../editors/astronvim/config/stylua.toml | 0 .../editors/astronvim/default.nix | 4 +- .../home-manager => home}/games/general.nix | 1 + home/luqman-home.nix | 17 + home/nix.nix | 4 + home/prod/essentials.nix | 7 + .../home-manager => home}/prod/school.nix | 7 - .../home-manager => home}/secrets/default.nix | 8 +- .../home-manager => home}/secrets/secrets.nix | 0 .../secrets/taskd_ca.age | Bin .../secrets/taskd_cert.age | Bin .../secrets/taskd_credentials.age | Bin .../secrets/taskd_key.age | Bin .../terminals/config.kdl | 0 .../home-manager => home}/terminals/kitty.nix | 0 .../terminals/wezterm/default.nix | 0 .../terminals}/wezterm/wezterm.lua | 0 .../terminals/zellij.nix | 0 .../home-manager => home/tools}/a2ln.nix | 0 .../home-manager => home}/tools/fonts.nix | 0 .../home-manager => home}/tools/mpd.nix | 0 .../modules => home}/tools/oci.nix | 0 .../home-manager => home}/tools/shell.nix | 0 .../home-manager => home}/tools/starship.nix | 0 .../home-manager => home}/tools/task.nix | 0 .../wayland-shell/ags/ags-config/config.js | 0 .../wayland-shell/ags/default.nix | 0 .../wayland-shell/anyrun/default.nix | 0 .../wayland-shell}/anyrun/style.css | 0 .../wayland-shell/dunst.nix | 0 .../wayland-shell/hyprland/default.nix | 2 + .../wayland-shell/hyprland/hyprland.conf | 0 .../wayland-shell/rofi.nix | 0 .../wayland-shell}/waybar/config.json | 0 .../wayland-shell/waybar/default.nix | 0 .../wayland-shell}/waybar/style.css | 0 .../wayland-shell/wayper.nix | 0 nix/shell.nix | 6 +- nixos/asuna.nix | 370 ------ nixos/default.nix | 122 +- nixos/dev.nix | 8 + .../experimental}/protonvpn.nix | 0 .../systemd-secure-boot/default.nix | 0 .../systemd-boot-builder.py | 0 .../nixos => nixos/experimental}/wifi-ap.nix | 0 nixos/groups.nix | 3 + nixos/hosts/asuna/default.nix | 344 ------ nixos/hosts/asuna/disko.nix | 4 - nixos/hosts/asuna/hardware.nix | 90 -- nixos/hosts/asuna/nixpkgs-config.nix | 3 - nixos/hw-conf/asuna-hc.nix | 85 -- nixos/hw-conf/kurumi-hc.nix | 39 - nixos/modules/home-manager/luqman-home.nix | 19 - nixos/modules/home-manager/nix-config.nix | 12 - .../modules/home-manager/secrets/secrets.nix | 8 - .../modules/home-manager/secrets/taskd_ca.age | Bin 2517 -> 0 bytes .../home-manager/secrets/taskd_cert.age | Bin 2566 -> 0 bytes .../secrets/taskd_credentials.age | Bin 679 -> 0 bytes .../home-manager/secrets/taskd_key.age | Bin 11310 -> 0 bytes .../terminals/wezterm/wezterm.lua | 22 - nixos/modules/home-manager/tools/oci.nix | 48 - .../wayland-shell/anyrun/style.css | 19 - .../wayland-shell/waybar/config.json | 514 --------- .../wayland-shell/waybar/style.css | 264 ----- nixos/nix.nix | 46 + nixos/nixos-vm-hc.nix | 40 - nixos/nixos-vm.nix | 174 --- nixos/nixos-wsl.nix | 76 -- nixos/secureboot.nix | 13 + nixos/shells.nix | 3 + nixos/sinon.nix | 98 -- nixos/steam.nix | 7 + nixos/users.nix | 25 + nixos/wsl.nix | 27 + systems/asuna/default.nix | 291 +++++ systems/asuna/hardware.nix | 100 ++ {nixos => systems}/images/base-iso.nix | 0 {nixos => systems}/images/default.nix | 0 {nixos => systems}/kurumi.nix | 0 systems/sinon.nix | 50 + 150 files changed, 934 insertions(+), 6887 deletions(-) create mode 100644 .github/workflows/system.yml create mode 100644 .vscode/settings.json delete mode 100644 archives/flake.nix delete mode 100644 archives/home-manager/anyrun/config.ron delete mode 100644 archives/home-manager/doom-emacs/config.el delete mode 100644 archives/home-manager/doom-emacs/init.el delete mode 100644 archives/home-manager/doom-emacs/packages.el delete mode 100644 archives/home-manager/doom-emacs/themes/catppuccin-theme.el delete mode 100644 archives/home-manager/dunst.nix delete mode 100644 archives/home-manager/emacs.nix delete mode 100644 archives/home-manager/graphical.nix delete mode 100644 archives/home-manager/hyprland.conf delete mode 100644 archives/home-manager/hyprland.nix delete mode 100644 archives/home-manager/kitty.nix delete mode 100644 archives/home-manager/luqman-desktop.nix delete mode 100644 archives/home-manager/luqman-kurumi.nix delete mode 100644 archives/home-manager/luqman-sinon.nix delete mode 100644 archives/home-manager/modules/default.nix delete mode 100644 archives/home-manager/modules/modules.nix delete mode 100644 archives/home-manager/modules/tools/fonts.nix delete mode 100644 archives/home-manager/modules/tools/starship.nix delete mode 100644 archives/home-manager/modules/tools/task.nix delete mode 100644 archives/home-manager/mpd.nix delete mode 100644 archives/home-manager/neomutt.nix delete mode 100644 archives/home-manager/nvim/lazyvim-conf/.gitignore delete mode 100644 archives/home-manager/nvim/lazyvim-conf/.neoconf.json delete mode 100644 archives/home-manager/nvim/lazyvim-conf/init.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/config/autocmds.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/config/keymaps.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/config/lazy.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/config/options.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/plugins/example.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/plugins/lsp.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/plugins/rust.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/lua/plugins/ui.lua delete mode 100644 archives/home-manager/nvim/lazyvim-conf/stylua.toml delete mode 100644 archives/home-manager/nvim/lazyvim-nvim.nix delete mode 100644 archives/home-manager/rofi.nix delete mode 100644 archives/home-manager/syncthing.nix delete mode 100644 archives/home-manager/waybar.nix delete mode 100644 archives/home-manager/wezterm.nix delete mode 100644 archives/modules/home-manager/default.nix delete mode 100644 archives/modules/home-manager/secrets/module.nix delete mode 100644 archives/modules/nixos/cloudflare-warp.nix delete mode 100644 archives/modules/nixos/default.nix rename {nixos/modules/home-manager => home}/browsers/firefox.nix (100%) create mode 100644 home/configopts.nix create mode 100644 home/default.nix rename {nixos/modules/home-manager => home}/editors/astronvim/config/.neoconf.json (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/README.md (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/init.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/community.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/lazy_setup.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/astrocore.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/astrolsp.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/astroui.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/chezmoi.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/cmp.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/mason.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/neorg.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/neovide.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/none-ls.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/term.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/treesitter.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/plugins/user.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/lua/polish.lua (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/neovim.yml (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/selene.toml (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/config/stylua.toml (100%) rename {nixos/modules/home-manager => home}/editors/astronvim/default.nix (90%) rename {nixos/modules/home-manager => home}/games/general.nix (94%) create mode 100644 home/luqman-home.nix create mode 100644 home/nix.nix create mode 100644 home/prod/essentials.nix rename {nixos/modules/home-manager => home}/prod/school.nix (70%) rename {nixos/modules/home-manager => home}/secrets/default.nix (77%) rename {archives/modules/home-manager => home}/secrets/secrets.nix (100%) rename {archives/modules/home-manager => home}/secrets/taskd_ca.age (100%) rename {archives/modules/home-manager => home}/secrets/taskd_cert.age (100%) rename {archives/modules/home-manager => home}/secrets/taskd_credentials.age (100%) rename {archives/modules/home-manager => home}/secrets/taskd_key.age (100%) rename {nixos/modules/home-manager => home}/terminals/config.kdl (100%) rename {nixos/modules/home-manager => home}/terminals/kitty.nix (100%) rename {nixos/modules/home-manager => home}/terminals/wezterm/default.nix (100%) rename {archives/home-manager => home/terminals}/wezterm/wezterm.lua (100%) rename {nixos/modules/home-manager => home}/terminals/zellij.nix (100%) rename {archives/modules/home-manager => home/tools}/a2ln.nix (100%) rename {nixos/modules/home-manager => home}/tools/fonts.nix (100%) rename {nixos/modules/home-manager => home}/tools/mpd.nix (100%) rename {archives/home-manager/modules => home}/tools/oci.nix (100%) rename {nixos/modules/home-manager => home}/tools/shell.nix (100%) rename {nixos/modules/home-manager => home}/tools/starship.nix (100%) rename {nixos/modules/home-manager => home}/tools/task.nix (100%) rename {nixos/modules/home-manager => home}/wayland-shell/ags/ags-config/config.js (100%) rename {nixos/modules/home-manager => home}/wayland-shell/ags/default.nix (100%) rename {nixos/modules/home-manager => home}/wayland-shell/anyrun/default.nix (100%) rename {archives/home-manager => home/wayland-shell}/anyrun/style.css (100%) rename {nixos/modules/home-manager => home}/wayland-shell/dunst.nix (100%) rename {nixos/modules/home-manager => home}/wayland-shell/hyprland/default.nix (97%) rename {nixos/modules/home-manager => home}/wayland-shell/hyprland/hyprland.conf (100%) rename {nixos/modules/home-manager => home}/wayland-shell/rofi.nix (100%) rename {archives/home-manager => home/wayland-shell}/waybar/config.json (100%) rename {nixos/modules/home-manager => home}/wayland-shell/waybar/default.nix (100%) rename {archives/home-manager => home/wayland-shell}/waybar/style.css (100%) rename {nixos/modules/home-manager => home}/wayland-shell/wayper.nix (100%) delete mode 100644 nixos/asuna.nix create mode 100644 nixos/dev.nix rename {archives/modules/nixos => nixos/experimental}/protonvpn.nix (100%) rename {archives/modules/nixos => nixos/experimental}/systemd-secure-boot/default.nix (100%) rename {archives/modules/nixos => nixos/experimental}/systemd-secure-boot/systemd-boot-builder.py (100%) rename {archives/modules/nixos => nixos/experimental}/wifi-ap.nix (100%) create mode 100644 nixos/groups.nix delete mode 100644 nixos/hosts/asuna/default.nix delete mode 100644 nixos/hosts/asuna/disko.nix delete mode 100644 nixos/hosts/asuna/hardware.nix delete mode 100644 nixos/hosts/asuna/nixpkgs-config.nix delete mode 100644 nixos/hw-conf/asuna-hc.nix delete mode 100644 nixos/hw-conf/kurumi-hc.nix delete mode 100644 nixos/modules/home-manager/luqman-home.nix delete mode 100644 nixos/modules/home-manager/nix-config.nix delete mode 100644 nixos/modules/home-manager/secrets/secrets.nix delete mode 100644 nixos/modules/home-manager/secrets/taskd_ca.age delete mode 100644 nixos/modules/home-manager/secrets/taskd_cert.age delete mode 100644 nixos/modules/home-manager/secrets/taskd_credentials.age delete mode 100644 nixos/modules/home-manager/secrets/taskd_key.age delete mode 100644 nixos/modules/home-manager/terminals/wezterm/wezterm.lua delete mode 100644 nixos/modules/home-manager/tools/oci.nix delete mode 100644 nixos/modules/home-manager/wayland-shell/anyrun/style.css delete mode 100644 nixos/modules/home-manager/wayland-shell/waybar/config.json delete mode 100644 nixos/modules/home-manager/wayland-shell/waybar/style.css create mode 100644 nixos/nix.nix delete mode 100644 nixos/nixos-vm-hc.nix delete mode 100644 nixos/nixos-vm.nix delete mode 100644 nixos/nixos-wsl.nix create mode 100644 nixos/secureboot.nix create mode 100644 nixos/shells.nix delete mode 100644 nixos/sinon.nix create mode 100644 nixos/steam.nix create mode 100644 nixos/users.nix create mode 100644 nixos/wsl.nix create mode 100644 systems/asuna/default.nix create mode 100644 systems/asuna/hardware.nix rename {nixos => systems}/images/base-iso.nix (100%) rename {nixos => systems}/images/default.nix (100%) rename {nixos => systems}/kurumi.nix (100%) create mode 100644 systems/sinon.nix diff --git a/.github/workflows/system.yml b/.github/workflows/system.yml new file mode 100644 index 0000000..7f40019 --- /dev/null +++ b/.github/workflows/system.yml @@ -0,0 +1,17 @@ +name: 'Build Hosts' +on: + push: + +jobs: + asuna: + runs-on: ubuntu-latest + environment: systemconfig + steps: + - uses: actions/checkout@v4 + - uses: DeterminateSystems/nix-installer-action@main + - uses: cachix/cachix-action@v14 + with: + name: nix-conf + authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' + - run: nix build .#nixosConfigurations.asuna.config.system.build.toplevel + - run: nix-shell --run "echo OK" \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..6b6fd46 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "nix.formatterPath": "alejandra" +} \ No newline at end of file diff --git a/archives/flake.nix b/archives/flake.nix deleted file mode 100644 index 0630a85..0000000 --- a/archives/flake.nix +++ /dev/null @@ -1,222 +0,0 @@ -{ - description = "solemnattic's nix config"; - - inputs = { - # Nixpkgs unstable - nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; - flake-parts.url = "github:hercules-ci/flake-parts"; - haumea = { - url = "github:nix-community/haumea/v0.2.2"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - - impermanence.url = "github:nix-community/impermanence"; - lanzaboote = { - url = "github:nix-community/lanzaboote/v0.3.0"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - - # Home manager - home-manager.url = "github:nix-community/home-manager"; - home-manager.inputs.nixpkgs.follows = "nixpkgs"; - - hyprland = { - url = "github:hyprwm/Hyprland/v0.37.1"; - inputs.nixpkgs.follows = "nixpkgs"; # MESA/OpenGL HW workaround - }; - hypridle = { - url = "github:hyprwm/hypridle/4395339a2dc410bcf49f3e24f9ed3024fdb25b0a"; - }; - hyprlock = { - url = "github:hyprwm/hyprlock/2ae79757d5e5c48de2f4284992a6bfa265853a2d"; - }; - - wayper.url = "github:luqmanishere/wayper"; - anyrun.url = "github:Kirottu/anyrun"; - anyrun.inputs.nixpkgs.follows = "nixpkgs"; - xremap-flake.url = "github:xremap/nix-flake"; - ags.url = "github:Aylur/ags/v1.8.0"; - - agenix.url = "github:ryantm/agenix"; - - nix-doom-emacs.url = "github:nix-community/nix-doom-emacs"; - emacs-overlay.url = "github:nix-community/emacs-overlay"; - - devenv.url = "github:cachix/devenv/rust-rewrite"; - nil.url = "github:oxalica/nil"; - alejandra = { - url = "github:kamadorueda/alejandra/3.0.0"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - - prismlauncher.url = "github:PrismLauncher/PrismLauncher"; - - nixos-wsl.url = "github:nix-community/NixOS-WSL"; - # hardware.url = "github:nixos/nixos-hardware"; - - # Shameless plug: looking for a way to nixify your themes and make - # everything match nicely? Try nix-colors! - # nix-colors.url = "github:misterio77/nix-colors"; - }; - - nixConfig = { - extra-trusted-public-keys = "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="; - extra-substituters = "https://devenv.cachix.org"; - }; - - outputs = { - self, - nixpkgs, - home-manager, - devenv, - ... - } @ inputs: let - inherit (self) outputs; - forAllSystems = nixpkgs.lib.genAttrs [ - "aarch64-linux" - "i686-linux" - "x86_64-linux" - "aarch64-darwin" - "x86_64-darwin" - ]; - in { - # Your custom packages - # Acessible through 'nix build', 'nix shell', etc - packages = forAllSystems (system: let - pkgs = nixpkgs.legacyPackages.${system}; - in - import ./pkgs {inherit pkgs;}); - # Devshell for bootstrapping - # Acessible through 'nix develop' or 'nix-shell' (legacy) - devShells = - forAllSystems - ( - system: let - pkgs = nixpkgs.legacyPackages.${system}; - in { - default = - devenv.lib.mkShell - { - inherit inputs pkgs; - modules = [ - ({pkgs, ...}: { - packages = with pkgs; [ - hello - inputs.home-manager.packages.${system}.default - inputs.nil.packages.${system}.default - inputs.alejandra.packages.${system}.default - git - neovim - curl - wget - aria2 - ]; - enterShell = '' - hello - ''; - - processes.run.exec = "hello"; - }) - ]; - }; - } - ); - - # Your custom packages and modifications, exported as overlays - overlays = import ./overlays {inherit inputs;}; - # Reusable nixos modules you might want to export - # These are usually stuff you would upstream into nixpkgs - nixosModules = import ./modules/nixos; - # Reusable home-manager modules you might want to export - # These are usually stuff you would upstream into home-manager - homeManagerModules = import ./modules/home-manager; - - # NixOS configuration entrypoint - # Available through 'nixos-rebuild --flake .#your-hostname' - nixosConfigurations = { - nixos-vm = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs outputs;}; - modules = [ - # > Our main nixos configuration file < - ./nixos/nixos-vm.nix - ]; - }; - asuna = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs outputs;}; - modules = [ - self.nixosModules.cloudflare-warp - #nixosModules.systemd-secure-boot - inputs.lanzaboote.nixosModules.lanzaboote - inputs.impermanence.nixosModules.impermanence - # inputs.hyprland.nixosModules.default - inputs.home-manager.nixosModules.home-manager - ./nixos/asuna.nix - { - home-manager = { - useUserPackages = true; - # useGlobalPkgs = true; - extraSpecialArgs = {inherit inputs outputs;}; - users.luqman = ./home-manager/luqman-desktop.nix; - }; - } - ]; - }; - sinon = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs outputs;}; - modules = [ - inputs.home-manager.nixosModules.home-manager - ./nixos/sinon.nix - - { - home-manager = { - useUserPackages = true; - extraSpecialArgs = {inherit inputs outputs;}; - users.luqman = ./home-manager/luqman-sinon.nix; - }; - } - ]; - }; - kurumi = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs outputs;}; - modules = [ - inputs.home-manager.nixosModules.home-manager - ./nixos/kurumi.nix - - { - home-manager = { - useUserPackages = true; - extraSpecialArgs = {inherit inputs outputs;}; - users.luqman = ./home-manager/luqman-kurumi.nix; - }; - } - ]; - }; - }; - - # Standalone home-manager configuration entrypoint - # Available through 'home-manager --flake .#your-username@your-hostname' - homeConfigurations = { - "luqman@nixos-vm" = home-manager.lib.homeManagerConfiguration { - pkgs = - nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance - extraSpecialArgs = {inherit inputs outputs;}; - modules = [ - ./home-manager/luqman-desktop.nix - ]; - }; - "luqman@asuna" = home-manager.lib.homeManagerConfiguration { - pkgs = nixpkgs.legacyPackages.x86_64-linux; - #nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance - extraSpecialArgs = {inherit inputs outputs;}; - modules = [ - ./home-manager/luqman-desktop.nix - ]; - }; - "luqman@sinon" = home-manager.lib.homeManagerConfiguration { - pkgs = nixpkgs.legacyPackages.x86_64-linux; - extraSpecialArgs = {inherit inputs outputs;}; - modules = [./home-manager/luqman-sinon.nix]; - }; - }; - }; -} diff --git a/archives/home-manager/anyrun/config.ron b/archives/home-manager/anyrun/config.ron deleted file mode 100644 index 47131be..0000000 --- a/archives/home-manager/anyrun/config.ron +++ /dev/null @@ -1,45 +0,0 @@ -Config( - // `width` and `vertical_offset` use an enum for the value it can be either: - // Absolute(n): The absolute value in pixels - // Fraction(n): A fraction of the width or height of the full screen (depends on exclusive zones and the settings related to them) window respectively - - // How wide the input box and results are. - width: Absolute(800), - - // Where Anyrun is located on the screen: Top, Center - position: Center, - - // How much the runner is shifted vertically - vertical_offset: Absolute(-300), - - // Hide match and plugin info icons - hide_icons: false, - - // ignore exclusive zones, f.e. Waybar - ignore_exclusive_zones: false, - - // Layer shell layer: Background, Bottom, Top, Overlay - layer: Overlay, - - // Hide the plugin info panel - hide_plugin_info: false, - - // Close window when a click outside the main box is received - close_on_click: false, - - // Show search results immediately when Anyrun starts - show_results_immediately: false, - - // Limit amount of entries shown in total - max_entries: None, - - // List of plugins to be loaded by default, can be specified with a relative path to be loaded from the - // `/plugins` directory or with an absolute path to just load the file the path points to. - plugins: [ - "libapplications.so", - "libsymbols.so", - "libshell.so", - "libtranslate.so", - "librink.so" - ], -) diff --git a/archives/home-manager/doom-emacs/config.el b/archives/home-manager/doom-emacs/config.el deleted file mode 100644 index 0528fd4..0000000 --- a/archives/home-manager/doom-emacs/config.el +++ /dev/null @@ -1,90 +0,0 @@ -;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- - -;; Place your private configuration here! Remember, you do not need to run 'doom -;; sync' after modifying this file! - - -;; Some functionality uses this to identify you, e.g. GPG configuration, email -;; clients, file templates and snippets. It is optional. -(setq user-full-name "luqmanishere" - user-mail-address "luqmanulhakim1720@gmail.com") - -;; Doom exposes five (optional) variables for controlling fonts in Doom: -;; -;; - `doom-font' -- the primary font to use -;; - `doom-variable-pitch-font' -- a non-monospace font (where applicable) -;; - `doom-big-font' -- used for `doom-big-font-mode'; use this for -;; presentations or streaming. -;; - `doom-unicode-font' -- for unicode glyphs -;; - `doom-serif-font' -- for the `fixed-pitch-serif' face -;; -;; See 'C-h v doom-font' for documentation and more examples of what they -;; accept. For example: -;; -;;(setq doom-font (font-spec :family "Fira Code" :size 12 :weight 'semi-light) -;; doom-variable-pitch-font (font-spec :family "Fira Sans" :size 13)) -;; -;; If you or Emacs can't find your font, use 'M-x describe-font' to look them -;; up, `M-x eval-region' to execute elisp code, and 'M-x doom/reload-font' to -;; refresh your font settings. If Emacs still can't find your font, it likely -;; wasn't installed correctly. Font issues are rarely Doom issues! - -;; There are two ways to load a theme. Both assume the theme is installed and -;; available. You can either set `doom-theme' or manually load a theme with the -;; `load-theme' function. This is the default: -(setq doom-font (font-spec :family "JetBrains Mono" :size 16 :weight 'medium)) -(setq doom-theme 'doom-tokyo-night) - -;;(setq doom-theme 'catppuccin) -;;(load-theme 'catppuccin t t) -;;(setq catppuccin-flavor 'macchiato) ;; or 'latte, 'macchiato, or 'mocha -;;(catppuccin-reload) - -;; This determines the style of line numbers in effect. If set to `nil', line -;; numbers are disabled. For relative line numbers, set this to `relative'. -(setq display-line-numbers-type 'relative) - -;; If you use `org' and don't want your org files in the default location below, -;; change `org-directory'. It must be set before org loads! -(setq org-directory "~/org/") - -(setq evil-escape-key-sequence "kj") - -(setq lsp-rust-analyzer-server-display-inlay-hints t) -(setq lsp-ui-doc-show-with-mouse t) -(setq lsp-ui-doc-show-with-cursor t) - -(keychain-refresh-environment) - - -;; Whenever you reconfigure a package, make sure to wrap your config in an -;; `after!' block, otherwise Doom's defaults may override your settings. E.g. -;; -;; (after! PACKAGE -;; (setq x y)) -;; -;; The exceptions to this rule: -;; -;; - Setting file/directory variables (like `org-directory') -;; - Setting variables which explicitly tell you to set them before their -;; package is loaded (see 'C-h v VARIABLE' to look up their documentation). -;; - Setting doom variables (which start with 'doom-' or '+'). -;; -;; Here are some additional functions/macros that will help you configure Doom. -;; -;; - `load!' for loading external *.el files relative to this one -;; - `use-package!' for configuring packages -;; - `after!' for running code after a package has loaded -;; - `add-load-path!' for adding directories to the `load-path', relative to -;; this file. Emacs searches the `load-path' when you load packages with -;; `require' or `use-package'. -;; - `map!' for binding new keys -;; -;; To get information about any of these functions/macros, move the cursor over -;; the highlighted symbol at press 'K' (non-evil users must press 'C-c c k'). -;; This will open documentation for it, including demos of how they are used. -;; Alternatively, use `C-h o' to look up a symbol (functions, variables, faces, -;; etc). -;; -;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how -;; they are implemented. diff --git a/archives/home-manager/doom-emacs/init.el b/archives/home-manager/doom-emacs/init.el deleted file mode 100644 index ba52455..0000000 --- a/archives/home-manager/doom-emacs/init.el +++ /dev/null @@ -1,194 +0,0 @@ -;;; init.el -*- lexical-binding: t; -*- - -;; This file controls what Doom modules are enabled and what order they load -;; in. Remember to run 'doom sync' after modifying it! - -;; NOTE Press 'SPC h d h' (or 'C-h d h' for non-vim users) to access Doom's -;; documentation. There you'll find a link to Doom's Module Index where all -;; of our modules are listed, including what flags they support. - -;; NOTE Move your cursor over a module's name (or its flags) and press 'K' (or -;; 'C-c c k' for non-vim users) to view its documentation. This works on -;; flags as well (those symbols that start with a plus). -;; -;; Alternatively, press 'gd' (or 'C-c c d') on a module to browse its -;; directory (for easy access to its source code). - -(doom! :input - ;;bidi ; (tfel ot) thgir etirw uoy gnipleh - ;;chinese - ;;japanese - ;;layout ; auie,ctsrnm is the superior home row - - :completion - company ; the ultimate code completion backend - ;;helm ; the *other* search engine for love and life - ;;ido ; the other *other* search engine... - ;;ivy ; a search engine for love and life - (vertico +icons) ; the search engine of the future - - :ui - ;;deft ; notational velocity for Emacs - doom ; what makes DOOM look the way it does - doom-dashboard ; a nifty splash screen for Emacs - ;;doom-quit ; DOOM quit-message prompts when you quit Emacs - (emoji +unicode) ; ๐Ÿ™‚ - hl-todo ; highlight TODO/FIXME/NOTE/DEPRECATED/HACK/REVIEW - ;;hydra - indent-guides ; highlighted indent columns - ligatures ; ligatures and symbols to make your code pretty again - minimap ; show a map of the code on the side - modeline ; snazzy, Atom-inspired modeline, plus API - nav-flash ; blink cursor line after big motions - ;;neotree ; a project drawer, like NERDTree for vim - ophints ; highlight the region an operation acts on - (popup +defaults) ; tame sudden yet inevitable temporary windows - tabs ; a tab bar for Emacs - (treemacs +lsp) ; a project drawer, like neotree but cooler - unicode ; extended unicode support for various languages - (vc-gutter +pretty) ; vcs diff in the fringe - vi-tilde-fringe ; fringe tildes to mark beyond EOB - ;;window-select ; visually switch windows - workspaces ; tab emulation, persistence & separate workspaces - ;;zen ; distraction-free coding or writing - - :editor - (evil +everywhere); come to the dark side, we have cookies - file-templates ; auto-snippets for empty files - fold ; (nigh) universal code folding - (format +onsave) ; automated prettiness - ;;god ; run Emacs commands without modifier keys - ;;lispy ; vim for lisp, for people who don't like vim - ;;multiple-cursors ; editing in many places at once - ;;objed ; text object editing for the innocent - parinfer ; turn lisp into python, sort of - ;;rotate-text ; cycle region at point between text candidates - snippets ; my elves. They type so I don't have to - word-wrap ; soft wrapping with language-aware indent - - :emacs - dired ; making dired pretty [functional] - electric ; smarter, keyword-based electric-indent - (ibuffer +icons) ; interactive buffer management - undo ; persistent, smarter undo for your inevitable mistakes - vc ; version-control and Emacs, sitting in a tree - - :term - ;;eshell ; the elisp shell that works everywhere - ;;shell ; simple shell REPL for Emacs - ;;term ; basic terminal emulator for Emacs - vterm ; the best terminal emulation in Emacs - - :checkers - syntax ; tasing you for every semicolon you forget - (spell +flyspell) ; tasing you for misspelling mispelling - grammar ; tasing grammar mistake every you make - - :tools - ;;ansible - ;;biblio ; Writes a PhD for you (citation needed) - (debugger +lsp) ; FIXME stepping through code, to help you add bugs - direnv - docker - editorconfig ; let someone else argue about tabs vs spaces - ;;ein ; tame Jupyter notebooks with emacs - (eval +overlay) ; run code, run (also, repls) - ;;gist ; interacting with github gists - (lookup +docsets) ; navigate your code and its documentation - (lsp +peek) ; M-x vscode - (magit +forge) ; a git porcelain for Emacs - make ; run make tasks from Emacs - ;;pass ; password manager for nerds - pdf ; pdf enhancements - ;;prodigy ; FIXME managing external services & code builders - rgb ; creating color strings - ;;taskrunner ; taskrunner for all your projects - ;;terraform ; infrastructure as code - ;;tmux ; an API for interacting with tmux - tree-sitter ; syntax and parsing, sitting in a tree... - ;;upload ; map local to remote projects via ssh/ftp - - :os - (:if IS-MAC macos) ; improve compatibility with macOS - tty ; improve the terminal Emacs experience - - :lang - ;;agda ; types of types of types of types... - ;;beancount ; mind the GAAP - (cc +lsp) ; C > C++ == 1 - ;;clojure ; java with a lisp - ;;common-lisp ; if you've seen one lisp, you've seen them all - ;;coq ; proofs-as-programs - ;;crystal ; ruby at the speed of c - ;;csharp ; unity, .NET, and mono shenanigans - data ; config/data formats - ;;(dart +flutter) ; paint ui and not much else - ;;dhall - ;;elixir ; erlang done right - ;;elm ; care for a cup of TEA? - emacs-lisp ; drown in parentheses - ;;erlang ; an elegant language for a more civilized age - ;;ess ; emacs speaks statistics - ;;factor - ;;faust ; dsp, but you get to keep your soul - ;;fortran ; in FORTRAN, GOD is REAL (unless declared INTEGER) - ;;fsharp ; ML stands for Microsoft's Language - ;;fstar ; (dependent) types and (monadic) effects and Z3 - ;;gdscript ; the language you waited for - ;;(go +lsp) ; the hipster dialect - ;;(graphql +lsp) ; Give queries a REST - ;;(haskell +lsp) ; a language that's lazier than I am - ;;hy ; readability of scheme w/ speed of python - ;;idris ; a language you can depend on - json ; At least it ain't XML - ;;(java +lsp) ; the poster child for carpal tunnel syndrome - ;;javascript ; all(hope(abandon(ye(who(enter(here)))))) - ;;julia ; a better, faster MATLAB - ;;kotlin ; a better, slicker Java(Script) - ;;latex ; writing papers in Emacs has never been so fun - ;;lean ; for folks with too much to prove - ;;ledger ; be audit you can be - lua ; one-based indices? one-based indices - markdown ; writing docs for people to ignore - ;;nim ; python + lisp at the speed of c - (nix +lsp +tree-sitter) ; I hereby declare "nix geht mehr!" - ;;ocaml ; an objective camel - org ; organize your plain life in plain text - ;;php ; perl's insecure younger brother - ;;plantuml ; diagrams for confusing people more - ;;purescript ; javascript, but functional - python ; beautiful is better than ugly - ;;qt ; the 'cutest' gui framework ever - ;;racket ; a DSL for DSLs - ;;raku ; the artist formerly known as perl6 - ;;rest ; Emacs as a REST client - ;;rst ; ReST in peace - ;;(ruby +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"} - (rust +lsp +tree-sitter) ; Fe2O3.unwrap().unwrap().unwrap().unwrap() - ;;scala ; java, but good - ;;(scheme +guile) ; a fully conniving family of lisps - sh ; she sells {ba,z,fi}sh shells on the C xor - ;;sml - ;;solidity ; do you need a blockchain? No. - ;;swift ; who asked for emoji variables? - ;;terra ; Earth and Moon in alignment for performance. - ;;web ; the tubes - ;;yaml ; JSON, but readable - ;;zig ; C, but simpler - - :email - ;;(mu4e +org +gmail) - ;;notmuch - ;;(wanderlust +gmail) - - :app - calendar - ;;emms - everywhere ; *leave* Emacs!? You must be joking - ;;irc ; how neckbeards socialize - (rss +org) ; emacs as an RSS reader - twitter ; twitter client https://twitter.com/vnought - - :config - ;;literate - (default +bindings +smartparens)) diff --git a/archives/home-manager/doom-emacs/packages.el b/archives/home-manager/doom-emacs/packages.el deleted file mode 100644 index 028f708..0000000 --- a/archives/home-manager/doom-emacs/packages.el +++ /dev/null @@ -1,51 +0,0 @@ -;; -*- no-byte-compile: t; -*- -;;; $DOOMDIR/packages.el - -;; To install a package with Doom you must declare them here and run 'doom sync' -;; on the command line, then restart Emacs for the changes to take effect -- or -;; use 'M-x doom/reload'. - - -;; To install SOME-PACKAGE from MELPA, ELPA or emacsmirror: -;(package! some-package) - -;; To install a package directly from a remote git repo, you must specify a -;; `:recipe'. You'll find documentation on what `:recipe' accepts here: https://github.com/radian-software/straight.el#the-recipe-format -;(package! another-package -; :recipe (:host github :repo "username/repo")) - -;; If the package you are trying to install does not contain a PACKAGENAME.el -;; file, or is located in a subdirectory of the repo, you'll need to specify -;; `:files' in the `:recipe': -;(package! this-package -; :recipe (:host github :repo "username/repo" -; :files ("some-file.el" "src/lisp/*.el"))) - -;; If you'd like to disable a package included with Doom, you can do so here -;; with the `:disable' property: -;(package! builtin-package :disable t) - -;; You can override the recipe of a built in package without having to specify -;; all the properties for `:recipe'. These will inherit the rest of its recipe -;; from Doom or MELPA/ELPA/Emacsmirror: -;(package! builtin-package :recipe (:nonrecursive t)) -;(package! builtin-package-2 :recipe (:repo "myfork/package")) - -;; Specify a `:branch' to install a package from a particular branch or tag. -;; This is required for some packages whose default branch isn't 'master' (which -;; our package manager can't deal with; see radian-software/straight.el#279) -;(package! builtin-package :recipe (:branch "develop")) - -;; Use `:pin' to specify a particular commit to install. -;(package! builtin-package :pin "1a2b3c4d5e") - - -;; Doom's packages are pinned to a specific commit and updated from release to -;; release. The `unpin!' macro allows you to unpin single packages... -;(unpin! pinned-package) -;; ...or multiple packages -;(unpin! pinned-package another-pinned-package) -;; ...Or *all* packages (NOT RECOMMENDED; will likely break things) -;(unpin! t) - -(package! keychain-environment) diff --git a/archives/home-manager/doom-emacs/themes/catppuccin-theme.el b/archives/home-manager/doom-emacs/themes/catppuccin-theme.el deleted file mode 100644 index a27c12a..0000000 --- a/archives/home-manager/doom-emacs/themes/catppuccin-theme.el +++ /dev/null @@ -1,1020 +0,0 @@ -;;; catppuccin-theme.el --- Catppuccin for Emacs - ๐Ÿ„ Soothing pastel theme for Emacs -*- lexical-binding: t; no-byte-compile: t; -*- - -;; Copyright 2022-present, All rights reserved -;; -;; Code licensed under the MIT license - -;; Maintainer: Carsten Kragelund -;; Author: nyxkrage -;; Original-Author: film42 -;; Version: 1.0.0 -;; Package-Requires: ((emacs "25.1")) -;; URL: https://github.com/catppuccin/emacs - -;;; Commentary: - -;; ๐Ÿ„ Soothing pastel theme for Emacs - -;;; Code: -(deftheme catppuccin) - -;;;; Configuration options: - -(defgroup catppuccin nil - "Catppuccin theme options. - -The theme has to be reloaded after changing anything in this group." - :group 'faces) - -(defcustom catppuccin-enlarge-headings t - "Use different font sizes for some headings and titles." - :type 'boolean - :group 'catppuccin) - -(defcustom catppuccin-height-title-1 1.3 - "Header 1 font size" - :type 'number - :group 'catppuccin) - -(defcustom catppuccin-height-title-2 1.2 - "Header 2 font size." - :type 'number - :group 'catppuccin) - -(defcustom catppuccin-height-title-3 1.2 - "Header 3 font size." - :type 'number - :group 'catppuccin) - -(defcustom catppuccin-height-doc-title 1.44 - "Documentation Title font size." - :type 'number - :group 'catppuccin) - -(defcustom catppuccin-flavor 'mocha - "The flavor to use for the Catppuccin theme -Must be one of `mocha`, `macchiato`, `frappe`, or `latte`" - :type '(choice (const :tag "Mocha" mocha) - (const :tag "Macchiato" macchiato) - (const :tag "Frappe" frappe) - (const :tag "Latte" latte)) - :group 'catppuccin) - -(defcustom catppuccin-mocha-colors '((rosewater . "#f5e0dc") - (flamingo . "#f2cdcd") - (pink . "#f5c2e7") - (mauve . "#cba6f7") - (red . "#f38ba8") - (maroon . "#eba0ac") - (peach . "#fab387") - (yellow . "#f9e2af") - (green . "#a6e3a1") - (teal . "#94e2d5") - (sky . "#89dceb") - (sapphire . "#74c7ec") - (blue . "#89b4fa") - (lavender . "#b4befe") - (text . "#cdd6f4") - (subtext1 . "#bac2de") - (subtext0 . "#a6adc8") - (overlay2 . "#9399b2") - (overlay1 . "#7f849c") - (overlay0 . "#6c7086") - (surface2 . "#585b70") - (surface1 . "#45475a") - (surface0 . "#313244") - (base . "#1e1e2e") - (mantle . "#181825") - (crust . "#11111b")) - "Colors used for catppuccin-mocha" - :tag "Mocha Colors" - :options '(rosewater flamingo pink mauve red maroon peach yellow green teal sky sapphire blue lavender text subtext1 subtext0 overlay2 overlay1 overlay0 surface2 surface1 surface0 base mantle crust) - :type '(alist :key-type symbol :value-type string) - :group 'catppuccin) - -(defcustom catppuccin-macchiato-colors '((rosewater . "#f4dbd6") - (flamingo . "#f0c6c6") - (pink . "#f5bde6") - (mauve . "#c6a0f6") - (red . "#ed8796") - (maroon . "#ee99a0") - (peach . "#f5a97f") - (yellow . "#eed49f") - (green . "#a6da95") - (teal . "#8bd5ca") - (sky . "#91d7e3") - (sapphire . "#7dc4e4") - (blue . "#8aadf4") - (lavender . "#b7bdf8") - (text . "#cad3f5") - (subtext1 . "#b8c0e0") - (subtext0 . "#a5adcb") - (overlay2 . "#939ab7") - (overlay1 . "#8087a2") - (overlay0 . "#6e738d") - (surface2 . "#5b6078") - (surface1 . "#494d64") - (surface0 . "#363a4f") - (base . "#24273a") - (mantle . "#1e2030") - (crust . "#181926")) - "Colors used for catppuccin-macchiato" - :tag "Macchiato Colors" - :options '(rosewater flamingo pink mauve red maroon peach yellow green teal sky sapphire blue lavender text subtext1 subtext0 overlay2 overlay1 overlay0 surface2 surface1 surface0 base mantle crust) - :type '(alist :key-type symbol :value-type string) - :group 'catppuccin) - -(defcustom catppuccin-frappe-colors '((rosewater . "#f2d5cf") - (flamingo . "#eebebe") - (pink . "#f4b8e4") - (mauve . "#ca9ee6") - (red . "#e78284") - (maroon . "#ea999c") - (peach . "#ef9f76") - (yellow . "#e5c890") - (green . "#a6d189") - (teal . "#81c8be") - (sky . "#99d1db") - (sapphire . "#85c1dc") - (blue . "#8caaee") - (lavender . "#babbf1") - (text . "#c6d0f5") - (subtext1 . "#b5bfe2") - (subtext0 . "#a5adce") - (overlay2 . "#949cbb") - (overlay1 . "#838ba7") - (overlay0 . "#737994") - (surface2 . "#626880") - (surface1 . "#51576d") - (surface0 . "#414559") - (base . "#303446") - (mantle . "#292c3c") - (crust . "#232634")) - "Colors used for catppuccin-frappe" - :tag "Frappe Colors" - :options '(rosewater flamingo pink mauve red maroon peach yellow green teal sky sapphire blue lavender text subtext1 subtext0 overlay2 overlay1 overlay0 surface2 surface1 surface0 base mantle crust) - :type '(alist :key-type symbol :value-type string) - :group 'catppuccin) - -(defcustom catppuccin-latte-colors '((rosewater . "#dc8a78") - (flamingo . "#dd7878") - (pink . "#ea76cb") - (mauve . "#8839ef") - (red . "#d20f39") - (maroon . "#e64553") - (peach . "#fe640b") - (yellow . "#df8e1d") - (green . "#40a02b") - (teal . "#179299") - (sky . "#04a5e5") - (sapphire . "#209fb5") - (blue . "#1e66f5") - (lavender . "#7287fd") - (text . "#4c4f69") - (subtext1 . "#5c5f77") - (subtext0 . "#6c6f85") - (overlay2 . "#7c7f93") - (overlay1 . "#8c8fa1") - (overlay0 . "#9ca0b0") - (surface2 . "#acb0be") - (surface1 . "#bcc0cc") - (surface0 . "#ccd0da") - (base . "#eff1f5") - (mantle . "#e6e9ef") - (crust . "#dce0e8")) - "Colors used for catppuccin-latte" - :tag "Latte Colors" - :options '(rosewater flamingo pink mauve red maroon peach yellow green teal sky sapphire blue lavender text subtext1 subtext0 overlay2 overlay1 overlay0 surface2 surface1 surface0 base mantle crust) - :type '(alist :key-type symbol :value-type string) - :group 'catppuccin) - -;;;; Internal functions, not documented - -(defun catppuccin-quantize-color (color) - (let ((i 1) - (str "#")) - (while (<= i 5) - (setq str - (concat - str - (format - "%02x" - (* (round - (/ - (string-to-number (substring color i (+ i 2)) 16) - 17)) - 17)))) - (setq i (+ i 2))) - str)) -;;;; User functions - -(defun catppuccin-reload () - "Reload the Catppuccin theme, useful for after having set custom colors with `catppuccin-set-color`" - (interactive) - (disable-theme 'catppuccin) - (load-theme 'catppuccin t)) - -(defun catppuccin-set-color (color value &optional flavor) - "Set the COLOR of FLAVOR or the current flavor to VALUE" - (interactive "SChange color: \nsSet %s to: ") - (setcdr (assoc color (symbol-value (intern-soft (concat "catppuccin-" (symbol-name (or flavor catppuccin-flavor)) "-colors")))) value)) - -(defun catppuccin-get-color (color &optional flavor) - "Get the COLOR of FLAVOR or the current flavor" - (interactive "SThe color to get: ") - (alist-get color (symbol-value (intern-soft (concat "catppuccin-" (symbol-name (or flavor catppuccin-flavor)) "-colors"))))) - -;;;; Theme definition: -(let ((colors '((undef "#ff00ff" "#ff00ff") - (ctp-rosewater (catppuccin-get-color 'rosewater) (catppuccin-quantize-color (catppuccin-get-color 'rosewater))) - (ctp-flamingo (catppuccin-get-color 'flamingo) (catppuccin-quantize-color (catppuccin-get-color 'flamingo))) - (ctp-pink (catppuccin-get-color 'pink) (catppuccin-quantize-color (catppuccin-get-color 'pink))) - (ctp-mauve (catppuccin-get-color 'mauve) (catppuccin-quantize-color (catppuccin-get-color 'mauve))) - (ctp-red (catppuccin-get-color 'red) (catppuccin-quantize-color (catppuccin-get-color 'red))) - (ctp-maroon (catppuccin-get-color 'maroon) (catppuccin-quantize-color (catppuccin-get-color 'maroon))) - (ctp-peach (catppuccin-get-color 'peach) (catppuccin-quantize-color (catppuccin-get-color 'peach))) - (ctp-yellow (catppuccin-get-color 'yellow) (catppuccin-quantize-color (catppuccin-get-color 'yellow))) - (ctp-green (catppuccin-get-color 'green) (catppuccin-quantize-color (catppuccin-get-color 'green))) - (ctp-teal (catppuccin-get-color 'teal) (catppuccin-quantize-color (catppuccin-get-color 'teal))) - (ctp-sky (catppuccin-get-color 'sky) (catppuccin-quantize-color (catppuccin-get-color 'sky))) - (ctp-sapphire (catppuccin-get-color 'sapphire) (catppuccin-quantize-color (catppuccin-get-color 'sapphire))) - (ctp-blue (catppuccin-get-color 'blue) (catppuccin-quantize-color (catppuccin-get-color 'blue))) - (ctp-lavender (catppuccin-get-color 'lavender) (catppuccin-quantize-color (catppuccin-get-color 'lavender))) - (ctp-text (catppuccin-get-color 'text) (catppuccin-quantize-color (catppuccin-get-color 'text))) - (ctp-subtext1 (catppuccin-get-color 'subtext1) (catppuccin-quantize-color (catppuccin-get-color 'subtext1))) - (ctp-subtext0 (catppuccin-get-color 'subtext0) (catppuccin-quantize-color (catppuccin-get-color 'subtext0))) - (ctp-overlay2 (catppuccin-get-color 'overlay2) (catppuccin-quantize-color (catppuccin-get-color 'overlay2))) - (ctp-overlay1 (catppuccin-get-color 'overlay1) (catppuccin-quantize-color (catppuccin-get-color 'overlay1))) - (ctp-overlay0 (catppuccin-get-color 'overlay0) (catppuccin-quantize-color (catppuccin-get-color 'overlay0))) - (ctp-surface2 (catppuccin-get-color 'surface2) (catppuccin-quantize-color (catppuccin-get-color 'surface2))) - (ctp-surface1 (catppuccin-get-color 'surface1) (catppuccin-quantize-color (catppuccin-get-color 'surface1))) - (ctp-surface0 (catppuccin-get-color 'surface0) (catppuccin-quantize-color (catppuccin-get-color 'surface0))) - (ctp-base (catppuccin-get-color 'base) (catppuccin-quantize-color (catppuccin-get-color 'base))) - (ctp-mantle (catppuccin-get-color 'mantle) (catppuccin-quantize-color (catppuccin-get-color 'mantle))) - (ctp-crust (catppuccin-get-color 'crust) (catppuccin-quantize-color (catppuccin-get-color 'crust))) - - ;; TODO: automatically lighten base to create ctp-current - (ctp-current (if (eq catppuccin-flavor 'latte) "#ffffff" "#262637")))) - (faces '(;; default / basic faces - (cursor :background ,ctp-rosewater) - (default :background ,ctp-base :foreground ,ctp-text) - (default-italic :slant italic) - (hl-todo :foreground ,ctp-peach) - (error :foreground ,ctp-maroon) - (ffap :foreground ,undef) - (fringe :background ,ctp-base :foreground ,ctp-surface1) - (header-line :inherit 'mode-line) - (highlight :foreground ,ctp-text :background ,ctp-current) - (hl-line :background ,ctp-current :extend t) - (info-quoted-name :foreground ,undef) - (info-string :foreground ,ctp-green) - (lazy-highlight :foreground ,ctp-subtext1 :background ,ctp-surface1) - (link :foreground ,ctp-rosewater :underline t) - (link-unvisited :foreground ,ctp-mauve :underline t) - (linum :foreground ,ctp-surface1 :background ,ctp-base) - (line-number :foreground ,ctp-surface1 :background ,ctp-base) - (match :background ,ctp-surface1 :foreground ,ctp-text) - (menu :background ,ctp-current :inverse-video nil :foreground ,ctp-text) - (minibuffer-prompt :weight normal :foreground ,ctp-subtext0) - (mode-line :background ,ctp-mantle nil :foreground ,ctp-text) - (mode-line-inactive - :background ,ctp-crust :inverse-video nil :foreground ,ctp-overlay0) - (read-multiple-choice-face :inherit completions-first-difference) - (region :background ,ctp-surface0 :extend t) - (shadow :foreground ,ctp-surface2) - (success :foreground ,ctp-green) - (warning :foreground ,ctp-peach) - (tooltip :foreground ,ctp-overlay2 :background ,ctp-surface0) - (trailing-whitespace :inherit warning) - (window-divider :foreground ,ctp-mantle) - (vertical-border :foreground ,ctp-mantle) - ;; solaire-mode - (solaire-default-face :background ,ctp-mantle :foreground ,ctp-text) - (solaire-fringe-face :background ,ctp-mantle :foreground ,ctp-surface1) - (solaire-line-number-face :foreground ,ctp-surface1 :background ,ctp-mantle) - (solaire-mode-line-face :background ,ctp-crust nil :foreground ,ctp-text) - (solaire-mode-line-inactive-face - :background ,ctp-crust :inverse-video nil :foreground ,ctp-subtext1) - (solaire-header-line-face :inherit 'solaire-mode-line-face) - - ;; evil - (evil-ex-lazy-highlight :inherit lazy-highlight) - (evil-ex-substitute-matches :foreground ,ctp-red :underline t) - (evil-ex-substitute-replacement :foreground ,ctp-green :underline t) - - ;; syntax / font-lock - (font-lock-builtin-face :foreground ,ctp-lavender) - (font-lock-comment-face :inherit shadow) - (font-lock-comment-delimiter-face :inherit shadow) - (font-lock-constant-face :foreground ,ctp-peach) - (font-lock-doc-face :inherit font-lock-comment-face) - (font-lock-function-name-face :foreground ,ctp-blue) - (font-lock-keyword-face :foreground ,ctp-mauve) - (font-lock-negation-char-face :foreground ,undef) - (font-lock-preprocessor-face :foreground ,ctp-yellow) - (font-lock-reference-face :inherit font-lock-constant-face) ;; obsolete - (font-lock-regexp-grouping-backslash :foreground ,undef) - (font-lock-regexp-grouping-construct :foreground ,undef) - (font-lock-string-face :foreground ,ctp-green) - (font-lock-type-face :inherit font-lock-builtin-face) - (font-lock-variable-name-face :foreground ,ctp-text) - (font-lock-warning-face :inherit warning) - ;; auto-complete - (ac-completion-face :underline t :foreground ,undef) - ;; company - ;; TODO: find undef'ed faces - (company-echo-common :foreground ,ctp-base :background ,ctp-text) - (company-preview :background ,ctp-current :foreground ,undef) - (company-preview-common :inherit company-preview - :foreground ,undef) - (company-preview-search :inherit company-preview - :foreground ,undef) - (company-scrollbar-bg :background ,ctp-surface0) - (company-scrollbar-fg :foreground ,undef) - (company-tooltip :inherit tooltip) - (company-tooltip-search :foreground ,undef - :underline t) - (company-tooltip-search-selection :background ,undef - :foreground ,ctp-base) - (company-tooltip-selection :inherit match) - (company-tooltip-mouse :background ,ctp-base) - (company-tooltip-common :foreground ,ctp-text :weight bold) - ;;(company-tooltip-common-selection :inherit company-tooltip-common) - (company-tooltip-annotation :foreground ,undef) - ;;(company-tooltip-annotation-selection :inherit company-tooltip-annotation) - ;; completions (minibuffer.el) - (completions-annotations :inherit font-lock-comment-face) - (completions-common-part :foreground ,undef) - (completions-first-difference :foreground ,undef) - ;; diff-hl - (diff-hl-change :foreground ,ctp-peach :background ,ctp-peach) - (diff-hl-delete :foreground ,ctp-red :background ,ctp-red) - (diff-hl-insert :foreground ,ctp-green :background ,ctp-green) - ;; diff-refine - (diff-refine-removed :weight bold) - (diff-refine-added :weight bold) - ;; git-gutter - (git-gutter:modified :foreground ,ctp-peach) - (git-gutter:deleted :foreground ,ctp-red) - (git-gutter:added :foreground ,ctp-green) - (git-gutter:seperator :inherit font-lock-comment-face) - (git-gutter:unchanged :foreground ,ctp-surface0) - ;; git-gutter fringe - (git-gutter-fr:modified :inherit git-gutter:modified) - (git-gutter-fr:deleted :inherit git-gutter:deleted) - (git-gutter-fr:added :inherit git-gutter:added) - ;; dired - (dired-flagged :foreground ,ctp-maroon :weight bold) - (dired-marked :weight bold) - (dired-mark :inherit dired-marked) - (dired-header :foreground ,ctp-sapphire :weight bold) - (dired-ignored :inherit font-lock-comment-face) - (dired-special :foreground ,ctp-yellow) - (dired-symlink :foreground ,ctp-pink) - (dired-warning :inherit warning) - (dired-directory :foreground ,ctp-blue) - (dired-perm-write :foreground ,ctp-green) - (dired-broken-symlink :foreground ,ctp-text :background ,ctp-red) - ;; dired+ (kept for legacy support) - ;; TODO (maybe): Show deprecation warning - ;; This doesn't make sense to keep around - (diredp-compressed-file-name :inherit dired-file-name) - (diredp-compressed-file-suffix :foreground ,ctp-green) - (diredp-date-time :foreground ,ctp-subtext0) - (diredp-deletion-file-name :inherit dired-flagged) - (diredp-deletion :inherit dired-flagged) - (diredp-dir-heading :inherit dired-header) - (diredp-dir-name :inherit dired-directory) - (diredp-dir-priv :inherit dired-directory) - (diredp-executable-tag :foreground ,ctp-red) - (diredp-file-suffix :inherit dired-file-name) - (diredp-flag-mark-line :inherit dired-marked) - (diredp-flag-mark :inherit dired-mark) - (diredp-ignored-file-name :foreground ,ctp-text) - (diredp-mode-line-flagged :foreground ,undef) - (diredp-mode-line-marked :foreground ,undef) - (diredp-no-priv :foreground ,ctp-surface2) - (diredp-number :foreground ,ctp-yellow) - (diredp-other-priv :inherit diredp-exec-priv) - (diredp-rare-priv :inherit diredp-exec-priv) - (diredp-read-priv :foreground ,ctp-sky) - (diredp-write-priv :inherit dired-perm-write) - (diredp-exec-priv :foreground ,ctp-red) - (diredp-symlink :inherit dired-symlink) - (diredp-link-priv :inherit dired-symlink) - (diredp-autofile-name :foreground ,undef) - (diredp-tagged-autofile-name :foreground ,undef) - ;; diredfl (more modernly published dired+) - (diredfl-file-name :inherit dired-file-name) - (diredfl-compressed-file-name :inherit dired-file-name) - (diredfl-compressed-file-suffix :foreground ,ctp-green) - (diredfl-date-time :foreground ,ctp-subtext0) - (diredfl-deletion-file-name :inherit dired-flagged) - (diredfl-deletion :inherit dired-flagged) - (diredfl-dir-heading :inherit dired-header) - (diredfl-dir-name :inherit dired-directory) - (diredfl-dir-priv :inherit dired-directory) - (diredfl-executable-tag :foreground ,ctp-red) - (diredfl-file-suffix :inherit dired-file-name) - (diredfl-flag-mark-line :inherit dired-marked) - (diredfl-flag-mark :inherit dired-mark) - (diredfl-ignored-file-name :foreground ,ctp-text) - (diredfl-mode-line-flagged :foreground ,undef) - (diredfl-mode-line-marked :foreground ,undef) - (diredfl-no-priv :foreground ,ctp-surface2) - (diredfl-number :foreground ,ctp-yellow) - (diredfl-other-priv :inherit diredfl-exec-priv) - (diredfl-rare-priv :inherit diredfl-exec-priv) - (diredfl-read-priv :foreground ,ctp-sky) - (diredfl-write-priv :inherit dired-perm-write) - (diredfl-exec-priv :foreground ,ctp-red) - (diredfl-symlink :inherit dired-symlink) - (diredfl-link-priv :inherit dired-symlink) - (diredfl-autofile-name :foreground ,undef) - (diredfl-tagged-autofile-name :foreground ,undef) - ;; eldoc-box - (eldoc-box-border :background ,ctp-current) - (eldoc-box-body :background ,ctp-current) - ;; elfeed - (elfeed-search-date-face :foreground ,ctp-subtext0) - (elfeed-search-title-face :foreground ,ctp-text) - (elfeed-search-unread-title-face :foreground ,ctp-rosewater) - (elfeed-search-feed-face :foreground ,ctp-text :weight bold) - (elfeed-search-tag-face :foreground ,ctp-green) - (elfeed-search-last-update-face :weight bold) - (elfeed-search-unread-count-face :foreground ,ctp-pink) - (elfeed-search-filter-face :foreground ,ctp-green :weight bold) - (elfeed-log-date-face :inherit elfeed-search-date-face) - (elfeed-log-error-level-face :inherit error) - (elfeed-log-warn-level-face :foreground ,ctp-peach) - (elfeed-log-info-level-face :weight bold) - (elfeed-log-debug-level-face :weight bold) - ;; elpher - (elpher-gemini-heading1 :weight bold :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-1))) - (elpher-gemini-heading2 :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-2))) - (elpher-gemini-heading3 :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-3))) - (elpher-gemini-preformatted :inherit fixed-pitch - :foreground ,ctp-green) - ;; enh-ruby - (enh-ruby-heredoc-delimiter-face :foreground ,ctp-yellow) - (enh-ruby-op-face :inherit haskell-operator-face) - (enh-ruby-regexp-delimiter-face :foreground ,ctp-yellow) - (enh-ruby-string-delimiter-face :foreground ,ctp-yellow) - ;; flyspell - (flyspell-duplicate :underline (:style wave :color ,ctp-teal)) - (flyspell-incorrect :underline (:style wave :color ,ctp-maroon)) - ;; font-latex - (font-latex-bold-face :foreground ,ctp-red :weight bold) - (font-latex-italic-face :foreground ,ctp-yellow :slant italic) - (font-latex-match-reference-keywords :foreground ,ctp-teal) - (font-latex-match-variable-keywords :foreground ,ctp-text) - (font-latex-string-face :foreground ,ctp-green) - (font-latex-warning-face :inherit warning) - ;; TODO: More latex faces to be themed, especially sections - ;; gemini - (gemini-heading-face-1 :weight bold :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-1))) - (gemini-heading-face-2 :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-2))) - (gemini-heading-face-3 :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-3))) - (gemini-heading-face-rest :foreground ,ctp-blue) - (gemini-quote-face :foreground ,ctp-green) - ;; go-test - (go-test--ok-face :inherit success) - (go-test--error-face :inherit error) - (go-test--warning-face :inherit warning) - (go-test--pointer-face :foreground ,ctp-pink) - (go-test--standard-face :foreground ,ctp-teal) - ;; haskell-mode - (haskell-operator-face :foreground ,ctp-sky) - (haskell-constructor-face :foreground ,ctp-mauve) - ;; helm - ;; TODO: Theme helm - (helm-bookmark-w3m :foreground ,undef) - (helm-buffer-not-saved :foreground ,undef) - (helm-buffer-process :foreground ,undef) - (helm-buffer-saved-out :foreground ,undef) - (helm-buffer-size :foreground ,undef) - (helm-candidate-number :foreground ,undef) - (helm-ff-directory :foreground ,undef) - (helm-ff-dotted-directory :foreground ,undef) - (helm-ff-executable :foreground ,undef) - (helm-ff-file :foreground ,undef) - (helm-ff-invalid-symlink :foreground ,undef) - (helm-ff-prefix :foreground ,undef) - (helm-ff-symlink :foreground ,undef) - (helm-grep-cmd-line :foreground ,undef) - (helm-grep-file :foreground ,undef) - (helm-grep-finish :foreground ,undef) - (helm-grep-lineno :foreground ,undef) - (helm-grep-match :inherit match) - (helm-grep-running :foreground ,undef) - (helm-header :foreground ,undef) - (helm-moccur-buffer :foreground ,undef) - (helm-selection :underline nil) - (helm-selection-line) - (helm-separator :foreground ,undef) - (helm-source-go-package-godoc-description :foreground ,undef) - (helm-source-header :foreground ,undef) - (helm-time-zone-current :foreground ,undef) - (helm-time-zone-home :foreground ,undef) - (helm-visible-mark :foreground ,undef) - ;; highlight-indentation minor mode - (highlight-indentation-face :background ,ctp-subtext1) - ;; icicle - ;; TODO: Verify this looks proper - (icicle-whitespace-highlight :background ,ctp-text) - (icicle-special-candidate :foreground ,ctp-subtext1) - (icicle-extra-candidate :foreground ,ctp-subtext1) - (icicle-search-main-regexp-others :foreground ,ctp-text) - (icicle-search-current-input :foreground ,ctp-pink) - (icicle-search-context-level-8 :foreground ,ctp-blue) - (icicle-search-context-level-7 :foreground ,ctp-blue) - (icicle-search-context-level-6 :foreground ,ctp-blue) - (icicle-search-context-level-5 :foreground ,ctp-blue) - (icicle-search-context-level-4 :foreground ,ctp-blue) - (icicle-search-context-level-3 :foreground ,ctp-blue) - (icicle-search-context-level-2 :foreground ,ctp-blue) - (icicle-search-context-level-1 :foreground ,ctp-blue) - (icicle-search-main-regexp-current :foreground ,ctp-text) - (icicle-saved-candidate :foreground ,ctp-text) - (icicle-proxy-candidate :foreground ,ctp-text) - (icicle-mustmatch-completion :foreground ,ctp-mauve) - (icicle-multi-command-completion :foreground ,ctp-subtext0) - (icicle-msg-emphasis :foreground ,ctp-green) - (icicle-mode-line-help :foreground ,ctp-overlay2) - (icicle-match-highlight-minibuffer :foreground ,ctp-mauve) - (icicle-match-highlight-Completions :foreground ,ctp-green) - (icicle-key-complete-menu-local :foreground ,ctp-text) - (icicle-key-complete-menu :foreground ,ctp-text) - (icicle-input-completion-fail-lax :foreground ,ctp-maroon) - (icicle-input-completion-fail :foreground ,ctp-maroon) - (icicle-historical-candidate-other :foreground ,ctp-text) - (icicle-historical-candidate :foreground ,ctp-text) - (icicle-current-candidate-highlight :foreground ,ctp-pink) - (icicle-Completions-instruction-2 :foreground ,ctp-overlay2) - (icicle-Completions-instruction-1 :foreground ,ctp-overlay2) - (icicle-completion :foreground ,ctp-text) - (icicle-complete-input :foreground ,ctp-peach) - (icicle-common-match-highlight-Completions :foreground ,ctp-mauve) - (icicle-candidate-part :foreground ,ctp-text) - (icicle-annotation :foreground ,ctp-overlay2) - ;; icomplete - (icompletep-determined :foreground ,ctp-blue) - ;; ido - (ido-first-match :foreground ,ctp-green) - (ido-only-match :foreground ,ctp-green) - (ido-subdir :inherit dired-directory) - (ido-virtual :foreground ,ctp-sapphire) - (ido-incomplete-regexp :inherit warning) - (ido-indicator :foreground ,ctp-text :weight bold) - ;; ivy - (ivy-current-match :background ,ctp-blue :foreground ,ctp-mantle :bold t) - (ivy-action :background nil :foreground ,ctp-lavender) - (ivy-grep-line-number :background nil :foreground ,ctp-peach) - (ivy-minibuffer-match-face-1 :background nil :foreground ,ctp-blue :bold t) - (ivy-minibuffer-match-face-2 :background nil :foreground ,ctp-sapphire) - (ivy-minibuffer-match-face-3 :background nil :foreground ,ctp-lavender) - (ivy-minibuffer-match-face-4 :background nil :foreground ,ctp-mauve) - (ivy-minibuffer-match-highlight :foreground ,ctp-blue) - (ivy-grep-info :foreground ,ctp-blue) - (ivy-grep-line-number :foreground ,ctp-mauve) - (ivy-confirm-face :foreground ,ctp-green) - (ivy-remote :foreground ,ctp-mauve) - (ivy-match-required-face :foreground ,ctp-red) - ;; isearch - (isearch :inherit match :weight bold) - (isearch-fail :inherit error) - ;; jde-java - (jde-java-font-lock-constant-face :inherit font-lock-constant-face) - (jde-java-font-lock-modifier-face :inherit font-lock-keyword-face) - (jde-java-font-lock-number-face :foreground ,ctp-text) - (jde-java-font-lock-package-face :foreground ,ctp-text) - (jde-java-font-lock-private-face :inherit font-lock-keyword-face) - (jde-java-font-lock-public-face :inherit font-lock-keyword-face) - ;; js2-mode - (js2-external-variable :foreground ,ctp-red) - (js2-function-param :inherit tree-sitter-hl-face:variable.parameter) - (js2-jsdoc-html-tag-delimiter :inherit web-mode-html-tag-bracket-face) - (js2-jsdoc-html-tag-name :inherit web-mode-html-tag-face) - (js2-jsdoc-value :foreground ,ctp-text) - (js2-private-function-call :inherit tree-sitter-hl-face:function.call) - (js2-private-member :inherit font-lock-variable-name-face) - ;; js3-mode - (js3-error-face :inherit error) - (js3-external-variable-face :foreground ,ctp-text) - (js3-function-param-face :inherit js2-function-param) - (js3-instance-member-face :inherit font-lock-variable-name-face) - (js3-jsdoc-tag-face :inherit web-mode-html-tag-face) - (js3-warning-face :inherit warning) - ;; lsp - (lsp-ui-peek-peek :background ,ctp-base) - (lsp-ui-peek-list :background ,ctp-surface2) - (lsp-ui-peek-filename :foreground ,ctp-text) - (lsp-ui-peek-line-number :foreground ,ctp-surface1) - (lsp-ui-peek-highlight :inherit highlight :distant-foreground ,ctp-base) - (lsp-ui-peek-header :foreground ,ctp-sapphire, :weight bold) - (lsp-ui-peek-footer :inherit lsp-ui-peek-header) - (lsp-ui-peek-selection :inherit match) - (lsp-ui-sideline-symbol :foreground ,ctp-subtext0) - (lsp-ui-sideline-current-symbol :foreground ,ctp-text :weight bold) - (lsp-ui-sideline-code-action :foreground ,ctp-yellow) - (lsp-ui-sideline-symbol-info :slant italic :height 0.99) - (lsp-ui-doc-background :background ,ctp-base) - (lsp-ui-doc-header :foreground ,ctp-sapphire) - ;; magit - (magit-branch-local :foreground ,ctp-teal) - (magit-branch-remote :foreground ,ctp-green) - (magit-tag :foreground ,ctp-peach) - (magit-section-heading :foreground ,ctp-blue :weight bold) - (magit-section-highlight :background ,ctp-surface0 :extend t) - (magit-diff-context-highlight :background ,ctp-surface0 - :foreground ,ctp-text - :extend t) - (magit-diff-revision-summary :foreground ,ctp-blue - :weight bold) - (magit-diff-revision-summary-highlight :foreground ,ctp-blue - :weight bold) - (magit-diff-added :foreground ,ctp-green - :extend t) - (magit-diff-added-highlight :background ,ctp-surface1 - :foreground ,ctp-green - :extend t) - (magit-diff-removed :foreground ,ctp-red - :extend t) - (magit-diff-removed-highlight :background ,ctp-surface1 - :foreground ,ctp-red - :extend t) - (magit-diff-file-heading :foreground ,ctp-text) - (magit-diff-file-heading-highlight :inherit magit-section-highlight) - (magit-diffstat-added :foreground ,ctp-green) - (magit-diffstat-removed :foreground ,ctp-red) - (magit-hash :foreground ,ctp-subtext0) - (diff-header :background ,undef) - (diff-hunk-header :foreground ,ctp-text :background ,ctp-surface2) - (magit-diff-hunk-heading :inherit diff-hunk-header) - (magit-diff-hunk-heading-highlight :inherit diff-hunk-header :weight bold) - (magit-item-highlight :background ,undef) - (magit-log-author :foreground ,ctp-subtext0) - (magit-process-ng :foreground ,ctp-peach :weight bold) - (magit-process-ok :foreground ,ctp-green :weight bold) - ;; markdown - (markdown-blockquote-face :foreground ,ctp-green) - (markdown-code-face :foreground ,ctp-text) - (markdown-footnote-face :foreground ,ctp-yellow) - (markdown-header-face :weight normal) - (markdown-header-face-1 - :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-1))) - (markdown-header-face-2 - :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-2))) - (markdown-header-face-3 - :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-3))) - (markdown-header-face-4 :foreground ,ctp-blue) - (markdown-header-face-5 :foreground ,ctp-blue) - (markdown-header-face-6 :foreground ,ctp-blue) - (markdown-inline-code-face :foreground ,ctp-green) - (markdown-plain-url-face :inherit link) - (markdown-pre-face :foreground ,ctp-green) - (markdown-table-face :foreground ,ctp-text) - (markdown-list-face :foreground ,ctp-mauve) - (markdown-language-keyword-face :inherit font-lock-comment-face) - ;; message - (message-header-to :foreground ,ctp-text :weight bold) - (message-header-cc :foreground ,ctp-text :weight bold) - (message-header-subject :foreground ,ctp-blue) - (message-header-newsgroups :foreground ,ctp-mauve) - (message-header-other :foreground ,ctp-mauve) - (message-header-name :foreground ,ctp-green) - (message-header-xheader :foreground ,ctp-lavender) - (message-separator :inherit font-lock-comment-face) - (message-cited-text :foreground ,ctp-green) - (message-cited-text-1 :foreground ,ctp-yellow) - (message-cited-text-2 :inherit font-lock-comment-face) - (message-cited-text-3 :inherit font-lock-comment-face) - (message-cited-text-4 :inherit font-lock-comment-face) - (message-mml :foreground ,ctp-green :weight normal) - ;; mini-modeline - (mini-modeline-mode-line :inherit mode-line :height 0.1 :box nil) - ;; mu4e - (mu4e-unread-face :foreground ,ctp-rosewater) - (mu4e-view-url-number-face :foreground ,ctp-yellow) - (mu4e-highlight-face :background ,ctp-base - :weight bold - :extend t) - (mu4e-header-highlight-face :background ,ctp-current - :foreground ,ctp-text - :underline nil :weight bold - :extend t) - (mu4e-header-key-face :inherit message-mml) - (mu4e-header-marks-face :foreground ,ctp-mauve) - (mu4e-cited-1-face :foreground ,ctp-green) - (mu4e-cited-2-face :foreground ,ctp-yellow) - (mu4e-cited-3-face :inherit font-lock-comment-face) - (mu4e-cited-4-face :inherit font-lock-comment-face) - (mu4e-cited-5-face :inherit font-lock-comment-face) - ;; neotree - (neo-banner-face :foreground ,ctp-blue :weight bold) - ;;(neo-button-face :underline nil) - (neo-dir-link-face :inherit link) - (neo-expand-btn-face :foreground ,ctp-text) - (neo-file-link-face :inherit link) - (neo-header-face :weight bold) - (neo-root-dir-face :foreground ,ctp-blue :weight bold) - (neo-vc-added-face :foreground ,ctp-green) - (neo-vc-conflict-face :inherit error) - (neo-vc-default-face :inherit default) - (neo-vc-edited-face :foreground ,ctp-peach) - (neo-vc-ignored-face :inherit font-lock-comment-face) - (neo-vc-missing-face :foreground ,ctp-maroon) - (neo-vc-needs-merge-face :foreground ,ctp-maroon - :weight bold) - ;;(neo-vc-needs-update-face :underline t) - (neo-vc-removed-face :foreground ,ctp-red) - (neo-vc-unlocked-changes-face :foreground ,ctp-red) - ;;(neo-vc-unregistered-face nil) - (neo-vc-up-to-date-face :foreground ,ctp-text) - (neo-vc-user-face :foreground ,ctp-mauve) - ;; org - (org-agenda-date :foreground ,ctp-subtext0 :weight normal) - (org-agenda-date-today :foreground ,ctp-subtext0 :weight bold) - (org-agenda-date-weekend :inherit org-agenda-date) - (org-agenda-date-weekend-today :inherit org-agenda-date :weight bold) - (org-agenda-dimmed-todo-face :inherit font-lock-comment-face) - (org-agenda-done :foreground ,ctp-green) - (org-agenda-structure :foreground ,ctp-subtext0) - (org-block :foreground ,ctp-green) - (org-code :foreground ,ctp-green) - (org-column :background ,ctp-surface0) - (org-column-title :inherit org-column :weight bold :underline t) - (org-date :inherit org-agenda-date) - (org-document-info :foreground ,ctp-sapphire) - (org-document-info-keyword :inherit font-lock-comment-face) - (org-document-title :weight bold :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-doc-title))) - (org-done :inherit font-lock-comment-face) - (org-ellipsis :inherit font-lock-comment-face) - (org-footnote :foreground ,ctp-mauve) - (org-formula :foreground ,ctp-pink) - (org-headline-done :inherit org-done) - (org-hide :foreground ,ctp-crust :background ,ctp-base) - (org-level-1 :inherit bold :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-1))) - (org-level-2 :inherit bold :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-2))) - (org-level-3 :weight normal :foreground ,ctp-blue - ,@(when catppuccin-enlarge-headings - (list :height catppuccin-height-title-3))) - (org-level-4 :weight normal :foreground ,ctp-blue) - (org-level-5 :weight normal :foreground ,ctp-blue) - (org-level-6 :weight normal :foreground ,ctp-blue) - (org-level-7 :weight normal :foreground ,ctp-blue) - (org-level-8 :weight normal :foreground ,ctp-blue) - (org-link :inherit link) - (org-priority :foreground ,ctp-yellow) - (org-quote :inherit markdown-blockquote-face) - (org-scheduled :foreground ,ctp-green) - (org-scheduled-previously :foreground ,ctp-teal) - (org-scheduled-today :foreground ,ctp-green :weight bold) - (org-sexp-date :foreground ,ctp-subtext0) - (org-special-keyword :inherit font-lock-keyword-face) - (org-table :foreground ,ctp-surface2) - (org-tag :foreground ,ctp-mauve :weight bold) - (org-todo :foreground ,ctp-peach) - (org-upcoming-deadline :foreground ,ctp-maroon) - (org-verbatim :inherit org-quote) - (org-warning :inherit warning) - ;; outline - (outline-1 :foreground ,ctp-blue) - (outline-2 :foreground ,ctp-blue) - (outline-3 :foreground ,ctp-blue) - (outline-4 :foreground ,ctp-blue) - (outline-5 :foreground ,ctp-blue) - (outline-6 :foreground ,ctp-blue) - ;; perspective - (persp-selected-face :weight bold :foreground ,ctp-pink) - ;; rainbow-delimiters - (rainbow-delimiters-depth-1-face :foreground ,ctp-red) - (rainbow-delimiters-depth-2-face :foreground ,ctp-peach) - (rainbow-delimiters-depth-3-face :foreground ,ctp-yellow) - (rainbow-delimiters-depth-4-face :foreground ,ctp-green) - (rainbow-delimiters-depth-5-face :foreground ,ctp-sapphire) - (rainbow-delimiters-depth-6-face :foreground ,ctp-red) - (rainbow-delimiters-depth-7-face :foreground ,ctp-peach) - (rainbow-delimiters-depth-8-face :foreground ,ctp-yellow) - (rainbow-delimiters-unmatched-face :inherit warning) - ;; rst (reStructuredText) - (rst-level-1 :foreground ,ctp-blue) - (rst-level-2 :foreground ,ctp-blue) - (rst-level-3 :foreground ,ctp-blue) - (rst-level-4 :foreground ,ctp-blue) - (rst-level-5 :foreground ,ctp-blue) - (rst-level-6 :foreground ,ctp-blue) - (rst-level-7 :foreground ,ctp-blue) - (rst-level-8 :foreground ,ctp-blue) - ;; show-paren - (show-paren-match :foreground ,ctp-pink - :weight bold) - (show-paren-match-expression :inherit match) - (show-paren-mismatch :inherit warning) - ;; slime - (slime-repl-inputed-output-face :foreground ,ctp-mauve) - ;; spam - (spam :inherit gnus-summary-normal-read :foreground ,ctp-peach - :strike-through t :slant oblique) - ;; tab-bar & tab-line (since Emacs 27.1) - (tab-bar :foreground ,ctp-subtext0 :background ,ctp-base) - (tab-bar-tab :foreground ,ctp-text :background ,ctp-current) - (tab-bar-tab-inactive :foreground ,ctp-subtext0 :background ,ctp-base) - (tab-line :inherit tab-bar) - (tab-line-tab :inherit tab-bar-tab) - (tab-line-tab-inactive :inherit tab-bar-tab-inactive) - (tab-line-tab-current :inherit tab-line-tab) - (tab-line-highlight :background ,ctp-surface1) - ;; centaur-tabs - (centaur-tabs-default :foreground ,ctp-subtext0, :background ,ctp-base) - (centaur-tabs-unselected :foreground ,ctp-subtext0 :background ,ctp-mantle) - (centaur-tabs-selected :foreground ,ctp-text :background ,ctp-current) - (centaur-tabs-unselected-modified :foreground ,ctp-maroon :background ,ctp-mantle) - (centaur-tabs-selected-modified :foreground ,ctp-red :background ,ctp-current) - (centaur-tabs-close-unselected :foreground ,ctp-subtext0 :background ,ctp-mantle) - (centaur-tabs-close-selected :foreground ,ctp-text :background ,ctp-current) - (centaur-tabs-name-mouse-face :foreground ,ctp-text :background ,ctp-surface1) - (centaur-tabs-close-mouse-face :foreground ,ctp-red :background ,ctp-surface1) - (centaur-tabs-modified-marker-selected :inherit centaur-tabs-selected-modified) - (centaur-tabs-modified-marker-unselected :inherit centaur-tabs-unselected-modified) - ;; term - (term :foreground ,ctp-text :background ,ctp-base) - (term-color-black ,@(if (eq catppuccin-flavor 'latte) - (list :foreground ctp-subtext1 :background ctp-subtext1) - (list :foreground ctp-surface1 :background ctp-surface1))) - (term-color-black-white ,@(if (eq catppuccin-flavor 'latte) - (list :foreground ctp-subtext0 :background ctp-subtext0) - (list :foreground ctp-surface2 :background ctp-surface2))) - (term-color-red :foreground ,ctp-red :background ,ctp-red) - (term-color-bright-red :foreground ,ctp-red :background ,ctp-red) - (term-color-green :foreground ,ctp-green :background ,ctp-green) - (term-color-bright-green :foreground ,ctp-green :background ,ctp-green) - (term-color-yellow :foreground ,ctp-yellow :background ,ctp-yellow) - (term-color-bright-yellow :foreground ,ctp-yellow :background ,ctp-yellow) - (term-color-blue :foreground ,ctp-blue :background ,ctp-blue) - (term-color-bright-blue :foreground ,ctp-blue :background ,ctp-blue) - (term-color-magenta :foreground ,ctp-pink :background ,ctp-pink) - (term-color-bright-magenta :foreground ,ctp-pink :background ,ctp-pink) - (term-color-cyan :foreground ,ctp-teal :background ,ctp-teal) - (term-color-bright-cyan :foreground ,ctp-teal :background ,ctp-teal) - (term-color-white ,@(if (eq catppuccin-flavor 'latte) - (list :foreground ctp-surface2 :background ctp-surface2) - (list :foreground ctp-subtext1 :background ctp-subtext1))) - (term-color-bright-white ,@(if (eq catppuccin-flavor 'latte) - (list :foreground ctp-surface1 :background ctp-surface1) - (list :foreground ctp-subtext0 :background ctp-subtext0))) - ;; tree-sitter - (tree-sitter-hl-face:attribute :inherit font-lock-constant-face) - (tree-sitter-hl-face:comment :inherit font-lock-comment-face) - (tree-sitter-hl-face:constant :inherit font-lock-constant-face) - (tree-sitter-hl-face:constant.builtin :inherit font-lock-builtin-face) - (tree-sitter-hl-face:constructor :inherit font-lock-constant-face) - (tree-sitter-hl-face:escape :foreground ,undef) - (tree-sitter-hl-face:function :inherit font-lock-function-name-face) - (tree-sitter-hl-face:function.builtin :inherit font-lock-builtin-face) - (tree-sitter-hl-face:function.call :inherit font-lock-function-name-face - :weight normal) - (tree-sitter-hl-face:function.macro :inherit font-lock-preprocessor-face) - (tree-sitter-hl-face:function.special :inherit font-lock-preprocessor-face) - (tree-sitter-hl-face:keyword :inherit font-lock-keyword-face) - (tree-sitter-hl-face:punctuation :foreground ,undef) - (tree-sitter-hl-face:punctuation.bracket :foreground ,ctp-text) - (tree-sitter-hl-face:punctuation.delimiter :foreground ,ctp-text) - (tree-sitter-hl-face:punctuation.special :foreground ,undef) - (tree-sitter-hl-face:string :inherit font-lock-string-face) - (tree-sitter-hl-face:string.special :foreground ,undef) - (tree-sitter-hl-face:tag :inherit font-lock-keyword-face) - (tree-sitter-hl-face:type :inherit font-lock-type-face) - (tree-sitter-hl-face:type.parameter :foreground ,ctp-sapphire) - (tree-sitter-hl-face:variable :inherit font-lock-variable-name-face) - (tree-sitter-hl-face:variable.parameter :foreground ,ctp-red) - ;; undo-tree - (undo-tree-visualizer-current-face :foreground ,ctp-peach) - (undo-tree-visualizer-default-face :foreground ,ctp-subtext0) - (undo-tree-visualizer-register-face :foreground ,ctp-mauve) - (undo-tree-visualizer-unmodified-face :foreground ,ctp-text) - ;; web-mode - (web-mode-builtin-face :inherit font-lock-builtin-face) - (web-mode-comment-face :inherit font-lock-comment-face) - (web-mode-constant-face :inherit font-lock-constant-face) - (web-mode-css-property-name-face :inherit font-lock-constant-face) - (web-mode-doctype-face :inherit font-lock-comment-face) - (web-mode-function-name-face :inherit font-lock-function-name-face) - (web-mode-html-attr-name-face :foreground ,ctp-blue) - (web-mode-html-attr-value-face :foreground ,ctp-green) - (web-mode-html-tag-face :foreground ,ctp-mauve) - (web-mode-keyword-face :foreground ,undef) - (web-mode-string-face :inherit font-lock-string-face) - (web-mode-type-face :inherit font-lock-type-face) - (web-mode-warning-face :inherit warning) - ;; which-func - (which-func :inherit font-lock-function-name-face) - ;; which-key - (which-key-key-face :inherit font-lock-builtin-face) - (which-key-command-description-face :inherit default) - (which-key-separator-face :inherit font-lock-comment-delimiter-face) - (which-key-local-map-description-face :foreground ,ctp-green) - ;; whitespace - (whitespace-big-indent :foreground ,ctp-peach) - (whitespace-empty :inherit warning) - (whitespace-hspace :background ,undef :foreground ,undef) - (whitespace-indentation :foreground ,ctp-surface0) - (whitespace-line :underline (:style wave :color ,ctp-mauve)) - (whitespace-newline :inherit font-lock-comment-face) - (whitespace-space :inherit font-lock-comment-face) - (whitespace-space-after-tab :inherit warning) - (whitespace-space-before-tab :inherit warning) - (whitespace-tab :inherit whitespace-newline) - (whitespace-trailing :inherit trailing-whitespace) - ;; yard-mode - (yard-tag-face :inherit font-lock-builtin-face) - (yard-directive-face :inherit font-lock-builtin-face)))) - - (apply #'custom-theme-set-faces - 'catppuccin - (let* ((expand-with-func - (lambda (func spec) - (let (reduced-color-list) - (dolist (col colors reduced-color-list) - (push (list (car col) (funcall func col)) - reduced-color-list)) - (eval `(let ,reduced-color-list - (backquote ,spec)))))) - whole-theme) - (pcase-dolist (`(,face . ,spec) faces) - (push `(,face - ((((min-colors 16777216)) ; fully graphical envs - ,(funcall expand-with-func 'cadr spec)) - (t ; terminal with 256 colors - ,(funcall expand-with-func 'caddr spec)))) - whole-theme)) - whole-theme)) - - (apply #'custom-theme-set-variables - 'catppuccin - (let ((get-func - (pcase (display-color-cells) - ((pred (<= 16777216)) 'car) ; fully graphical envs - (_ 'cadr)))) ; terminal withs 256 colors - `((ansi-color-names-vector - [,(funcall get-func (alist-get (if (eq catppuccin-flavor 'latte) 'ctp-subtext1 'ctp-surface1) colors)) - ,(funcall get-func (alist-get 'ctp-red colors)) - ,(funcall get-func (alist-get 'ctp-green colors)) - ,(funcall get-func (alist-get 'ctp-yellow colors)) - ,(funcall get-func (alist-get 'ctp-blue colors)) - ,(funcall get-func (alist-get 'ctp-pink colors)) - ,(funcall get-func (alist-get 'ctp-teal colors)) - ,(funcall get-func (alist-get (if (eq catppuccin-flavor 'latte) 'ctp-surface2 'ctp-subtext1) colors))])) - `((rustic-ansi-faces - (vector - ,(funcall get-func (alist-get (if (eq catppuccin-flavor 'latte) 'ctp-subtext1 'ctp-surface1) colors)) - ,(funcall get-func (alist-get 'ctp-red colors)) - ,(funcall get-func (alist-get 'ctp-green colors)) - ,(funcall get-func (alist-get 'ctp-yellow colors)) - ,(funcall get-func (alist-get 'ctp-blue colors)) - ,(funcall get-func (alist-get 'ctp-pink colors)) - ,(funcall get-func (alist-get 'ctp-teal colors)) - ,(funcall get-func (alist-get (if (eq catppuccin-flavor 'latte) 'ctp-surface2 'ctp-subtext1) colors)))))))) - - - - -;;;###autoload -(when load-file-name - (add-to-list 'custom-theme-load-path - (file-name-as-directory (file-name-directory load-file-name)))) - -(provide-theme 'catppuccin) - -;; Unbind functions used for internal use -(fmakunbound 'catppuccin-quantize-color) - -;; Local Variables: -;; indent-tabs-mode: nil -;; End: - -;;; catppuccin-theme.el ends here diff --git a/archives/home-manager/dunst.nix b/archives/home-manager/dunst.nix deleted file mode 100644 index d29e703..0000000 --- a/archives/home-manager/dunst.nix +++ /dev/null @@ -1,76 +0,0 @@ -{ - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.dunst; -in { - imports = []; - options.dunst = { - enable = mkOption { - default = false; - description = "Enable the dunst notification manager"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home = { - packages = [ - ]; - }; - - services.dunst = { - enable = true; - settings = { - global = { - monitor = 0; - follow = "mouse"; - idle-threshold = 30; - dmenu = "${pkgs.rofi}/bin/rofi -dmenu -i -p ''"; - layer = "overlay"; - notification_limit = 5; - progress_bar = true; - - origin = "top-right"; - width = "(0,500)"; - height = 150; - offset = "80x30"; - - mouse_left_click = "do_action"; - mouse_right_click = "context"; - mouse_middle_click = "close_all"; - - corner-radius = 10; - frame_color = "#89B4FA"; - separator_color = "frame"; - max_icon_size = 100; - min_icon_size = 100; - gap_size = 2; - font = "Noto Sans Display Nerd Font 12"; - }; - - urgency_low = { - background = "#1E1E2E"; - foreground = "#CDD6F4"; - timeout = 5; - }; - - urgency_normal = { - background = "#1E1E2E"; - foreground = "#CDD6F4"; - timeout = 5; - }; - - urgency_critical = { - background = "#1E1E2E"; - foreground = "#CDD6F4"; - frame_color = "#FAB387"; - timeout = 5; - }; - }; - }; - }; -} diff --git a/archives/home-manager/emacs.nix b/archives/home-manager/emacs.nix deleted file mode 100644 index 9272934..0000000 --- a/archives/home-manager/emacs.nix +++ /dev/null @@ -1,97 +0,0 @@ -# this module was adapted from hlissner, the creator of Doom Emacs -{ - config, - lib, - pkgs, - inputs, - ... -}: -with lib; let - cfg = config.modules.editors.emacs; - configDir = config.dotfiles.configDir; -in { - options.modules.editors.emacs = { - enable = mkOption { - description = "enable emacs config"; - default = false; - type = types.bool; - }; - doom = rec { - enable = mkOption { - description = "Enable doom-emacs"; - default = false; - type = types.bool; - }; - repoUrl = mkOption { - description = "doom repo url"; - type = types.str; - default = "https://github.com/doomemacs/doomemacs"; - }; - doomConfigFiles = mkOption { - description = "path to doom config files"; - type = types.nullOr types.path; - default = null; - }; - }; - }; - - config = mkIf cfg.enable { - nixpkgs.overlays = [inputs.emacs-overlay.overlay]; - - home.packages = with pkgs; [ - ## Emacs itself - binutils # native-comp needs 'as', provided by this - # 28.2 + native-comp - emacsUnstablePgtk - - # emacs - cmake - ## Doom dependencies - git - (ripgrep.override {withPCRE2 = true;}) - gnutls # for TLS connectivity - - ## Optional dependencies - fd # faster projectile indexing - imagemagick # for image-dired - /* - (mkIf (config.programs.gnupg.agent.enable) - */ - /* - pinentry_emacs) # in-emacs gnupg prompts - */ - zstd # for undo-fu-session/undo-tree compression - - ## Module dependencies - # :checkers spell - (aspellWithDicts (ds: with ds; [en en-computers en-science])) - # :tools editorconfig - editorconfig-core-c # per-project style config - # :tools lookup & :lang org +roam - sqlite - # :lang latex & :lang org (latex previews) - texlive.combined.scheme-medium - # :lang beancount - beancount - #fava # HACK Momentarily broken on nixos-unstable - - emacs-all-the-icons-fonts - ]; - - #env.PATH = [ "$XDG_CONFIG_HOME/emacs/bin" ]; - home.sessionPath = ["$XDG_CONFIG_HOME/emacs/bin"]; - - # modules.shell.zsh.rcFiles = [ "${configDir}/emacs/aliases.zsh" ]; - - #fonts.fonts = [ pkgs.emacs-all-the-icons-fonts ]; - - home.activation = mkIf cfg.doom.enable { - installDoomEmacs = '' - if [ ! -d "$HOME/.config/emacs" ]; then - ${pkgs.git}/bin/git clone --depth=1 --single-branch "${cfg.doom.repoUrl}" "$HOME/.config/emacs" - fi - ''; - }; - xdg.configFile."doom".source = cfg.doom.doomConfigFiles; - }; -} diff --git a/archives/home-manager/graphical.nix b/archives/home-manager/graphical.nix deleted file mode 100644 index b6b699c..0000000 --- a/archives/home-manager/graphical.nix +++ /dev/null @@ -1,184 +0,0 @@ -{ - inputs, - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.graphical; -in { - imports = [ - ./kitty.nix - ./wezterm.nix - ./hyprland.nix - ./dunst.nix - ./rofi.nix - ./modules/tools/fonts.nix - ]; - options.graphical = { - enable = mkOption { - default = false; - description = "Enable graphical setup"; - type = types.bool; - }; - }; - config = mkIf (cfg.enable) { - home = { - packages = with pkgs; [ - #desktop apps - tdesktop - chromium - microsoft-edge - pavucontrol - obsidian - zathura - foliate - (vivaldi.override { - proprietaryCodecs = true; - enableWidevine = true; - }) - libreoffice - logseq - - prismlauncher - #inputs.prismlauncher.packages.${pkgs.system}.prismlauncher - #osu-lazer - gamescope - mangohud - scrcpy - - grim - slurp - ]; - }; - - fonts.fontconfig.enable = true; - modules.tools.fonts.enable = true; - - services.easyeffects.enable = true; - - # TODO: Mmove to gtk module - # configure gnome shell - dconf = { - enable = true; - settings = { - "org/gnome/shell" = { - disable-user-extensions = false; - enabled-extensions = [ - #"user-theme@gnome-shell-extensions.gcampax.github.com" - "workspace-indicator@gnome-shell-extensions.gcampax.github.com" - #"appindicatorsupport@rgcjonas.gmail.com" - "pop-shell@system76.com" - ]; - }; - "org/gnome/shell/extensions/user-theme" = { - name = config.gtk.theme.name; - }; - #"org/gnome/desktop/interface" = { - # monospace-font-name = "MesloLGS Nerd Font Mono 10"; - # color-scheme = "prefer-dark"; - #}; - "org/gnome/desktop/peripherals/touchpad" = { - tap-to-click = true; - two-finger-scrolling-enabled = true; - }; - "org/gnome/mutter" = { - edge-tiling = true; - workspaces-only-on-primary = true; - dynamic-workspaces = false; - }; - "org/gnome/desktop/wm/preferences" = { - num-workspaces = 4; - focus-mode = "sloppy"; - }; - "org/gnome/settings-daemon/plugins/color" = { - night-light-enabled = true; - night-light-temperature = "uint32 3500"; - night-light-schedule-automatic = true; - }; - "org/gnome/eog/ui" = { - image-gallery = true; - }; - # Enable and configure pop-shell - # (see https://github.com/pop-os/shell/blob/master_jammy/scripts/configure.sh) - "org/gnome/shell/extensions/pop-shell" = { - active-hint = true; - }; - "org/gnome/desktop/wm/keybindings" = { - minimize = ["comma"]; - maximize = []; - unmaximize = []; - switch-to-workspace-left = []; - switch-to-workspace-right = []; - move-to-monitor-up = []; - move-to-monitor-down = []; - move-to-monitor-left = []; - move-to-monitor-right = []; - move-to-workspace-down = []; - move-to-workspace-up = []; - switch-to-workspace-down = ["Down" "j"]; - switch-to-workspace-up = ["Up" "k"]; - toggle-maximized = ["f"]; - close = ["q" "F4"]; - switch-to-workspace-1 = ["1"]; - switch-to-workspace-2 = ["2"]; - switch-to-workspace-3 = ["3"]; - switch-to-workspace-4 = ["4"]; - move-to-workspace-1 = ["1"]; - move-to-workspace-2 = ["2"]; - move-to-workspace-3 = ["3"]; - move-to-workspace-4 = ["4"]; - }; - "org/gnome/shell/keybindings" = { - open-application-menu = []; - toggle-message-tray = ["v"]; - toggle-overview = []; - switch-to-application-1 = []; - switch-to-application-2 = []; - switch-to-application-3 = []; - switch-to-application-4 = []; - switch-to-application-5 = []; - switch-to-application-6 = []; - switch-to-application-7 = []; - switch-to-application-8 = []; - switch-to-application-9 = []; - }; - "org/gnome/mutter/keybindings" = { - toggle-tiled-left = []; - toggle-tiled-right = []; - }; - "org/gnome/settings-daemon/plugins/media-keys" = { - custom-keybindings = [ - "/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/" - ]; - screensaver = "@as ['Escape']"; - rotate-video-lock-static = []; - home = ["e"]; - email = []; - www = []; - terminal = []; - }; - "org/gnome/mutter/wayland/keybindings" = { - restore-shortcuts = []; - }; - "org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = { - binding = "z"; - command = "alacritty"; # TODO: use configured "default" - name = "Open Alacritty"; - }; - }; - }; - gtk = { - enable = true; - iconTheme = { - name = "Adwaita"; - package = pkgs.gnome.adwaita-icon-theme; - }; - theme = { - name = "Pop"; - package = pkgs.pop-gtk-theme; - }; - }; - }; -} diff --git a/archives/home-manager/hyprland.conf b/archives/home-manager/hyprland.conf deleted file mode 100644 index e12c9e3..0000000 --- a/archives/home-manager/hyprland.conf +++ /dev/null @@ -1,218 +0,0 @@ -input { - follow_mouse=1 - - touchpad { - natural_scroll=yes - disable_while_typing = true - tap-to-click = true - } - - sensitivity = 0 -} - -general { - gaps_in = 5 - gaps_out = 25 - border_size = 2 - - col.active_border=rgb(f5bde6) #pin - col.inactive_border=rgb(7dc4e4) #blu - - apply_sens_to_raw = 1 - - layout = master -} - -decoration { - rounding = 10 - - blur { - enabled = true - size = 8 - passes = 1 - new_optimizations = true - } - - active_opacity = 0.95 - inactive_opacity = 0.85 - fullscreen_opacity = 1.0 -} - -animations { - enabled = true - first_launch_animation = true -} - -animation = windows,1,7,default -animation = border,1,10,default -animation = fade,1,10,default -animation = workspaces,1,6,default - -master { - new_is_master = true - mfact = 0.7 - no_gaps_when_only = false - always_center_master = true -} - -gestures { - workspace_swipe=true - workspace_swipe_fingers=4 -} - -#monitor = ,preferred,auto,1 -monitor = eDP-1,preferred,auto,1 -monitor = HDMI-A-1, 1920x1080,auto,1 -monitor = DP-1,preferred,auto,1 -monitor = DP-1,transform,1 -monitor=eDP-1,addreserved,0,0,0,50 - -workspace=1,monitor:eDP-1 -workspace=3,monitor:eDP-1 -workspace=5,monitor:eDP-1 -workspace=7,monitor:eDP-1 -workspace=9,monitor:eDP-1 -workspace=2,monitor:HDMI-A-1 -workspace=4,monitor:HDMI-A-1 -workspace=6,monitor:HDMI-A-1 -workspace=8,monitor:HDMI-A-1 -workspace=0,monitor:HDMI-A-1 -workspace=2,monitor:DP-1 -workspace=4,monitor:DP-1 -workspace=6,monitor:DP-1 -workspace=8,monitor:DP-1 -workspace=0,monitor:DP-1 - -windowrule = float,Minecraft -windowrule = float,lutris -windowrule = opaque,Minecraft -windowrule = float,steam -windowrule = opaque,steam -windowrule = float,dota2 -windowrule = opaque,dota2 -windowrule = opaque,Waydroid -windowrule = float,Waydroid -windowrule = float, title:Picture in picture -windowrule = pin, title:Picture in picture -windowrule = float, title:muzik - music manager - -windowrulev2 = float,title:(Picture-in-Picture) -windowrulev2 = pin,title:(Picture-in-Picture) -windowrulev2 = opaque,title:(Picture-in-Picture) - -# Binds -bind = ALT, Tab, cyclenext -bind = ALT, Tab, bringactivetotop - -bind=SUPER,Q,exec,kitty -bind=SUPER,RETURN,exec,alacritty -bind=SUPER,C,killactive, -bind=SUPERSHIFT,Q,exit, -bind=SUPER,E,exec,dolphin -bind=SUPER,R,exec,$HOME/.config/rofi/bin/launcher -bind=ALT,SPACE,exec,anyrun -bind=SUPER,P,pseudo, -bind=SUPERSHIFT,P,pin -bind = SUPER,F,fullscreen -bind=SUPERSHIFT,F,fakefullscreen - - -# reload waybar config -bind = SUPERSHIFT,B,exec,killall -SIGUSR2 waybar -# hide/show waybar -bind = SUPERSHIFT,N,exec,killall -SIGUSR1 waybar - -bind = SUPERSHIFT,L,exec,loginctl lock-session - -bind = SUPERSHIFT,S,exec,grim -g "$(slurp)" - -bind = SUPER,T,exec,/home/luqman/scripts/autoclicktrigger.sh -# audio keybinds -bind = ,XF86AudioRaiseVolume,exec,wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+ -bind = ,XF86AudioLowerVolume,exec,wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%- -bind = ,XF86AudioMute,exec,wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle -bind = ,XF86AudioMicMute,exec,wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle - -bind = ,XF86MonBrightnessUp,exec,light -A 5 -bind = ,XF86MonBrightnessDown,exec,light -U 5 - -bind=SUPER,J,togglefloating, -bind=SUPERSHIFT,O,toggleopaque, -bind=SUPERSHIFT,J,workspaceopt,allfloat - -bind=SUPER,G,togglegroup -bind=SUPER,grave,changegroupactive,f - -bind=SUPER,left,movefocus,l -bind=SUPER,right,movefocus,r -bind=SUPER,up,movefocus,u -bind=SUPER,down,movefocus,d - -bind=SUPER,h,movefocus,l -bind=SUPER,l,movefocus,r -bind=SUPER,k,movefocus,u -bind=SUPER,j,movefocus,d - -# move windows around -#bind = SUPERSHIFT,H,movewindow,l -#bind = SUPERSHIFT,J,movewindow,d -#bind = SUPERSHIFT,K,movewindow,u -#bind = SUPERSHIFT,L,movewindow,r - -bind=SUPER,1,workspace,1 -bind=SUPER,2,workspace,2 -bind=SUPER,3,workspace,3 -bind=SUPER,4,workspace,4 -bind=SUPER,5,workspace,5 -bind=SUPER,6,workspace,6 -bind=SUPER,7,workspace,7 -bind=SUPER,8,workspace,8 -bind=SUPER,9,workspace,9 -bind=SUPER,0,workspace,10 - -bind=ALT,1,movetoworkspace,1 -bind=ALT,2,movetoworkspace,2 -bind=ALT,3,movetoworkspace,3 -bind=ALT,4,movetoworkspace,4 -bind=ALT,5,movetoworkspace,5 -bind=ALT,6,movetoworkspace,6 -bind=ALT,7,movetoworkspace,7 -bind=ALT,8,movetoworkspace,8 -bind=ALT,9,movetoworkspace,9 -bind=ALT,0,movetoworkspace,10 - -bind=SUPER,mouse_down,workspace,e+1 -bind=SUPER,mouse_up,workspace,e-1 - -bindm = SUPER, mouse:272, movewindow -bindm = SUPER, mouse:273, resizewindow - -# resize windows -bind=ALT,R,submap,resize -submap=resize -binde=,right,resizeactive,10 0 -binde=,left,resizeactive,-10 0 -binde=,up,resizeactive,0 -10 -binde=,down,resizeactive,0 10 -bind=,escape,submap,reset -bind=,enter,submap,reset -submap=reset - - -bind=SUPERSHIFT,M,submap,audio -submap=audio -binde=,p,exec,playerctl play-pause -binde=,escape,submap,reset -submap=reset - -# master layout keybinds -bind=SUPER,m,layoutmsg,swapwithmaster -bind = ALT,Tab,layoutmsg,cyclenext - -bind=SUPERSHIFT,Z,movecurrentworkspacetomonitor,+1 - -exec-once = wl-paste --type text --watch cliphist store #Stores only text data -exec-once = wl-paste --type image --watch cliphist store #Stores only image data -exec-once=/usr/bin/dunst -exec-once=/usr/lib/polkit-kde-authentication-agent-1 -bind = SUPER, V, exec, cliphist list | rofi -dmenu | cliphist decode | wl-copy diff --git a/archives/home-manager/hyprland.nix b/archives/home-manager/hyprland.nix deleted file mode 100644 index 3ee5e5a..0000000 --- a/archives/home-manager/hyprland.nix +++ /dev/null @@ -1,91 +0,0 @@ -{ - inputs, - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.hyprland; -in { - imports = [ - inputs.hyprland.homeManagerModules.default - inputs.hypridle.homeManagerModules.default - inputs.hyprlock.homeManagerModules.default - ./waybar.nix - ]; - - options.hyprland = { - enable = mkOption { - default = false; - description = "Enable hyprland configuration, with swayidle and swaylock"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home = { - packages = with pkgs; [ - cliphist - wl-clipboard - wlr-randr - swayidle - swaylock-effects - grim - slurp - inputs.anyrun.packages.${system}.anyrun-with-all-plugins - ]; - pointerCursor = { - gtk.enable = true; - package = pkgs.bibata-cursors; - name = "Bibata-Modern-Ice"; - size = 22; - }; - }; - - wayland.windowManager.hyprland = { - enable = true; - systemd.enable = true; - extraConfig = builtins.readFile ./hyprland.conf; - # package = pkgs.hyprland-hidpi; - }; - - programs.hyprlock = { - enable = true; - general = { - disable_loading_bar = false; - }; - backgrounds = [ - { - path = "/home/luqman/wallpapers/notseiso/horizontal/suisei-member-july.png"; - } - ]; - }; - - services.hypridle = { - enable = true; - lockCmd = "pidof hyprlock || ${inputs.hyprlock.packages.${pkgs.system}.hyprlock}/bin/hyprlock"; - beforeSleepCmd = "loginctl lock-sesion"; - afterSleepCmd = "${pkgs.hyprland}/bin/hyprctl dispatch dpms on"; - listeners = [ - # turn off screen after 5 minutes - { - timeout = 300; - onTimeout = "${pkgs.hyprland}/bin/hyprctl dispatch dpms off"; - onResume = "${pkgs.hyprland}/bin/hyprctl dispatch dpms on"; - } - { - timeout = 360; - onTimeout = "pidof hyprlock || loginctl lock-session"; - } - { - timeout = 15; - onTimeout = "pidof hyprlock && ${pkgs.hyprland}/bin/hyprctl dispatch dpms off"; - onResume = "${pkgs.hyprland}/bin/hyprctl dispatch dpms on"; - } - ]; - }; - - xdg.configFile."anyrun".source = ./anyrun; - }; -} diff --git a/archives/home-manager/kitty.nix b/archives/home-manager/kitty.nix deleted file mode 100644 index f0131ba..0000000 --- a/archives/home-manager/kitty.nix +++ /dev/null @@ -1,36 +0,0 @@ -{ - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.kitty-conf; -in { - imports = []; - - options.kitty-conf = { - enable = mkOption { - default = false; - description = "Enable the great kitty terminal config"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home = { - packages = with pkgs; [ - kitty - ]; - }; - - programs.kitty = { - enable = true; - font = { - name = "Iosevka SolemnAttic"; - size = 16.0; - }; - theme = "Catppuccin-Mocha"; - }; - }; -} diff --git a/archives/home-manager/luqman-desktop.nix b/archives/home-manager/luqman-desktop.nix deleted file mode 100644 index 344587b..0000000 --- a/archives/home-manager/luqman-desktop.nix +++ /dev/null @@ -1,76 +0,0 @@ -{ - inputs, - outputs, - pkgs, - ... -}: { - # You can import other home-manager modules here - imports = [ - # If you want to use modules your own flake exports (from modules/home-manager): - # outputs.homeManagerModules.example - - # Or modules exported from other flakes (such as nix-colors): - # inputs.nix-colors.homeManagerModules.default - ./modules - ./nvim/lazyvim-nvim.nix - ./graphical.nix - ./emacs.nix - ./mpd.nix - ./syncthing.nix - ./modules/tools/oci.nix - ./neomutt.nix - ./modules/editors/astronvim/astronvim.nix - ./modules/terminals/zellij.nix - outputs.homeManagerModules.a2ln - inputs.nix-doom-emacs.hmModule - ]; - - # Add stuff for your user as you see fit: - home.packages = with pkgs; [ - starship - fish - - git - delta - age - - # FIXME: seperate cli, desktop profiles - fzf - ripgrep - fd - bat - helix - keychain - tmux - discord - ]; - - dunst.enable = true; - rofi.enable = true; - services.a2ln.enable = true; - mpd.enable = true; - syncthing.enable = true; - neomutt.enable = true; - - modules.tools.oci-script.enable = true; - - modules.editors.emacs = { - enable = false; - # doom.enable = false; - doom.doomConfigFiles = ./doom-emacs; - }; - - /* - xdg = { - mime.enable = true; - mimeApps = { - enable = true; - }; - }; - */ - # Nicely reload system units when changing configs - systemd.user.startServices = "sd-switch"; - - # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion - home.stateVersion = "22.11"; -} diff --git a/archives/home-manager/luqman-kurumi.nix b/archives/home-manager/luqman-kurumi.nix deleted file mode 100644 index daf982a..0000000 --- a/archives/home-manager/luqman-kurumi.nix +++ /dev/null @@ -1,298 +0,0 @@ -{ - inputs, - outputs, - config, - pkgs, - ... -}: { - # You can import other home-manager modules here - imports = [ - # If you want to use modules your own flake exports (from modules/home-manager): - # outputs.homeManagerModules.example - - # Or modules exported from other flakes (such as nix-colors): - # inputs.nix-colors.homeManagerModules.default - ./mpd.nix - ./task.nix - ./neomutt.nix - ./modules/editors/astronvim/astronvim.nix - ./modules/terminals/zellij.nix - outputs.homeManagerModules.a2ln - ]; - - nixpkgs = { - # You can add overlays here - overlays = [ - # Add overlays your own flake exports (from overlays and pkgs dir): - outputs.overlays.modifications - outputs.overlays.additions - inputs.nil.overlays.default - inputs.alejandra.overlays.default - #inputs.emacs-overlay.overlays.default - # You can also add overlays exported from other flakes: - # neovim-nightly-overlay.overlays.default - - # Or define it inline, for example: - # (final: prev: { - # hi = final.hello.overrideAttrs (oldAttrs: { - # patches = [ ./change-hello-to-hi.patch ]; - # }); - # }) - ]; - # Configure your nixpkgs instance - config = { - allowUnfree = true; - # Workaround for https://github.com/nix-community/home-manager/issues/2942 - allowUnfreePredicate = _: true; - permittedInsecurePackages = ["electron-11.5.0"]; - }; - }; - - home = { - username = "luqman"; - homeDirectory = "/home/luqman"; - sessionVariables = { - COLORTERM = "truecolor"; - XDG_CONFIG_HOME = "${config.home.homeDirectory}/.config"; - MEOW = "cat"; - }; - }; - - # Add stuff for your user as you see fit: - home.packages = with pkgs; [ - starship - fish - - git - delta - age - - # FIXME: seperate cli, desktop profiles - fzf - ripgrep - fd - bat - helix - keychain - tmux - discord - ]; - - # home manager please manage yourself - programs.home-manager.enable = true; - - programs.starship = { - enable = true; - enableFishIntegration = true; - }; - - programs.fzf = { - enable = true; - enableFishIntegration = true; - defaultOptions = [ - "--preview 'bat --color=always {}'" - ]; - }; - - programs.fish = { - enable = true; - shellAliases = { - ls = "eza --git --group-directories-first --time-style=long-iso"; - l = "ls -1"; - sl = "ls"; - ll = "ls -al"; - la = "ls -lbhHigUmuSa"; - tree = "eza --tree"; - - ip = "ip --color=auto"; - - tm = "tmux attach -t main || tmux new -s main"; - }; - shellAbbrs = { - psg = "ps ax | grep -i"; - }; - interactiveShellInit = " - set -U XDG_DATA_DIRS $XDG_DATA_DIRS /var/lib/flatpak/exports/share /home/luqman/.local/share/flatpak/exports/share - "; - }; - - programs.direnv = { - enable = true; - enableZshIntegration = true; - nix-direnv.enable = true; - }; - - programs.git = { - enable = true; - userName = "luqmanishere"; - userEmail = "luqmanulhakim1720@gmail.com"; - extraConfig = let - deltaCommand = "${pkgs.delta}/bin/delta"; - in { - core = { - pager = "${deltaCommand} --diff-so-fancy"; - }; - delta = { - navigate = true; - light = false; - side-by-side = true; - }; - merge = { - conflictstyle = "diff3"; - }; - diff = { - colorMoved = "default"; - }; - interactive = { - diffFilter = "${deltaCommand} --color-only"; - }; - }; - }; - - programs.helix = { - enable = true; - settings = { - theme = "catppuccin_mocha"; - editor = { - cursorline = true; - lsp.display-messages = true; - indent-guides.render = true; - }; - }; - }; - - programs.eza = { - enable = true; - }; - - programs.zoxide = { - enable = true; - enableFishIntegration = true; - }; - - programs.bat = { - enable = true; - themes = { - Catppuccin-mocha = builtins.readFile (pkgs.fetchFromGitHub - { - owner = "catppuccin"; - repo = "bat"; - rev = "ba4d16880d63e656acced2b7d4e034e4a93f74b1"; - sha256 = "6WVKQErGdaqb++oaXnY3i6/GuH2FhTgK0v4TN4Y0Wbw="; - } - + "/Catppuccin-mocha.tmTheme"); - }; - config = { - theme = "Catppuccin-mocha"; - }; - }; - - programs.tmux = { - enable = true; - baseIndex = 1; - clock24 = true; - historyLimit = 10000; - #mouse = true; - sensibleOnTop = true; - prefix = "`"; - mouse = true; - plugins = with pkgs.tmuxPlugins; [ - yank - { - plugin = dracula; - extraConfig = '' - set -g @dracula-plugins "battery cpu-usage ram-usage network time" - set -g @dracula-show-powerline true - set -g @dracula-show-flags true - set -g @dracula-military-time true - set -g @dracula-show-left-icon session - ''; - } - sensible - resurrect - continuum - fzf-tmux-url - extrakto - better-mouse-mode - (mkTmuxPlugin { - pluginName = "tmux-session-wizard"; - version = "unstable-2021-06-20"; - src = pkgs.fetchFromGitHub { - owner = "27medkamal"; - repo = "tmux-session-wizard"; - rev = "1b547d2b8e6435c3b825e8e7616911d74ea6ec4d"; - sha256 = "4EquWiR8ercuhC/+qNUQQn8WfrjZiDCU0Z3/yeHJlBA="; - }; - rtpFilePath = "session-wizard.tmux"; - }) - ]; - extraConfig = '' - set -g default-terminal "tmux-256color" - set -ag terminal-overrides ",xterm-256color:RGB" - bind a last-window - - # Switch panes with hjkl - bind -r h select-pane -L - bind -r j select-pane -D - bind -r k select-pane -U - bind -r l select-pane -R - - # resize panes - bind -r H resize-pane -L 5 - bind -r J resize-pane -D 5 - bind -r K resize-pane -U 5 - bind -r L resize-pane -R 5 - - # split panes using | and - - bind | split-window -h - bind - split-window -v - unbind '"' - unbind % - - # switch panes using Alt-arrow without prefix - bind -n M-Left select-pane -L - bind -n M-Right select-pane -R - bind -n M-Up select-pane -U - bind -n M-Down select-pane -D - - ## Quickly switch panes - unbind ^J - bind ^J select-pane -t :.+ - - bind r source-file ~/.config/tmux/tmux.conf \; display "Config reloaded" - - set -g allow-passthrough on - ''; - }; - - programs.keychain = { - enable = true; - enableZshIntegration = true; - enableFishIntegration = true; - inheritType = "any"; - agents = ["gpg" "ssh"]; - keys = ["gitvm"]; - }; - - programs.neovim = { - enable = true; - defaultEditor = true; - }; - modules.editors.astronvim.enable = true; - modules.editors.astronvim.userConfig.enable = true; - - neomutt.enable = true; - - modules.cli.taskwarrior.enable = true; - modules.terminals.zellij.enable = true; - - xdg.userDirs.enable = true; - xdg.enable = true; - xdg.configHome = "${config.home.homeDirectory}/.config"; - - # Nicely reload system units when changing configs - systemd.user.startServices = "sd-switch"; - - # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion - home.stateVersion = "22.11"; -} diff --git a/archives/home-manager/luqman-sinon.nix b/archives/home-manager/luqman-sinon.nix deleted file mode 100644 index cc9f7f4..0000000 --- a/archives/home-manager/luqman-sinon.nix +++ /dev/null @@ -1,332 +0,0 @@ -{ - inputs, - outputs, - config, - pkgs, - ... -}: { - # You can import other home-manager modules here - imports = [ - # If you want to use modules your own flake exports (from modules/home-manager): - # outputs.homeManagerModules.example - - # Or modules exported from other flakes (such as nix-colors): - # inputs.nix-colors.homeManagerModules.default - ./modules/editors/astronvim/astronvim.nix - ./modules/tools/fonts.nix - ./modules/tools/oci.nix - ./mpd.nix - ./neomutt.nix - ./syncthing.nix - ./task.nix - outputs.homeManagerModules.a2ln - ]; - - nixpkgs = { - # You can add overlays here - overlays = [ - # Add overlays your own flake exports (from overlays and pkgs dir): - outputs.overlays.modifications - outputs.overlays.additions - inputs.nil.overlays.default - inputs.alejandra.overlays.default - #inputs.emacs-overlay.overlays.default - # You can also add overlays exported from other flakes: - # neovim-nightly-overlay.overlays.default - - # Or define it inline, for example: - # (final: prev: { - # hi = final.hello.overrideAttrs (oldAttrs: { - # patches = [ ./change-hello-to-hi.patch ]; - # }); - # }) - ]; - # Configure your nixpkgs instance - config = { - allowUnfree = true; - # Workaround for https://github.com/nix-community/home-manager/issues/2942 - allowUnfreePredicate = _: true; - permittedInsecurePackages = ["electron-11.5.0"]; - }; - }; - - home = { - username = "luqman"; - homeDirectory = "/home/luqman"; - sessionVariables = { - COLORTERM = "truecolor"; - XDG_CONFIG_HOME = "${config.home.homeDirectory}/.config"; - MEOW = "cat"; - }; - }; - - # Add stuff for your user as you see fit: - home.packages = with pkgs; [ - exa - starship - fish - - git - delta - age - - # FIXME: seperate cli, desktop profiles - fzf - ripgrep - fd - bat - helix - keychain - tmux - # discord - ]; - - # home manager please manage yourself - programs.home-manager.enable = true; - - programs.firefox = { - enable = true; - }; - - programs.starship = { - enable = true; - enableFishIntegration = true; - }; - - programs.fzf = { - enable = true; - enableFishIntegration = true; - defaultOptions = [ - "--preview 'bat --color=always {}'" - ]; - }; - - programs.fish = { - enable = true; - shellAliases = { - ls = "exa --git --group-directories-first --time-style=long-iso"; - l = "ls -1"; - sl = "ls"; - ll = "ls -al"; - la = "ls -lbhHigUmuSa"; - tree = "exa --tree"; - - ip = "ip --color=auto"; - - tm = "tmux attach -t main || tmux new -s main"; - }; - shellAbbrs = { - psg = "ps ax | grep -i"; - }; - interactiveShellInit = " - set -U XDG_DATA_DIRS $XDG_DATA_DIRS /var/lib/flatpak/exports/share /home/luqman/.local/share/flatpak/exports/share - "; - }; - - programs.direnv = { - enable = true; - enableZshIntegration = true; - nix-direnv.enable = true; - }; - - programs.git = { - enable = true; - userName = "luqmanishere"; - userEmail = "luqmanulhakim1720@gmail.com"; - extraConfig = let - deltaCommand = "${pkgs.delta}/bin/delta"; - in { - core = { - pager = "${deltaCommand} --diff-so-fancy"; - }; - delta = { - navigate = true; - light = false; - side-by-side = true; - }; - merge = { - conflictstyle = "diff3"; - }; - diff = { - colorMoved = "default"; - }; - interactive = { - diffFilter = "${deltaCommand} --color-only"; - }; - }; - }; - - programs.helix = { - enable = true; - settings = { - theme = "catppuccin_mocha"; - editor = { - cursorline = true; - lsp.display-messages = true; - indent-guides.render = true; - }; - }; - }; - - programs.exa = { - enable = true; - }; - - programs.zoxide = { - enable = true; - enableFishIntegration = true; - }; - - programs.bat = { - enable = true; - themes = { - Catppuccin-mocha = builtins.readFile (pkgs.fetchFromGitHub - { - owner = "catppuccin"; - repo = "bat"; - rev = "ba4d16880d63e656acced2b7d4e034e4a93f74b1"; - sha256 = "6WVKQErGdaqb++oaXnY3i6/GuH2FhTgK0v4TN4Y0Wbw="; - } - + "/Catppuccin-mocha.tmTheme"); - }; - config = { - theme = "Catppuccin-mocha"; - }; - }; - - programs.tmux = { - enable = true; - baseIndex = 1; - clock24 = true; - historyLimit = 10000; - #mouse = true; - sensibleOnTop = true; - prefix = "`"; - mouse = true; - plugins = with pkgs.tmuxPlugins; [ - yank - { - plugin = dracula; - extraConfig = '' - set -g @dracula-plugins "battery cpu-usage ram-usage network time" - set -g @dracula-show-powerline true - set -g @dracula-show-flags true - set -g @dracula-military-time true - set -g @dracula-show-left-icon session - ''; - } - sensible - resurrect - continuum - fzf-tmux-url - extrakto - better-mouse-mode - (mkTmuxPlugin { - pluginName = "tmux-session-wizard"; - version = "unstable-2021-06-20"; - src = pkgs.fetchFromGitHub { - owner = "27medkamal"; - repo = "tmux-session-wizard"; - rev = "1b547d2b8e6435c3b825e8e7616911d74ea6ec4d"; - sha256 = "4EquWiR8ercuhC/+qNUQQn8WfrjZiDCU0Z3/yeHJlBA="; - }; - rtpFilePath = "session-wizard.tmux"; - }) - ]; - extraConfig = '' - set -g default-terminal "tmux-256color" - set -ag terminal-overrides ",xterm-256color:RGB" - bind a last-window - - # Switch panes with hjkl - bind -r h select-pane -L - bind -r j select-pane -D - bind -r k select-pane -U - bind -r l select-pane -R - - # resize panes - bind -r H resize-pane -L 5 - bind -r J resize-pane -D 5 - bind -r K resize-pane -U 5 - bind -r L resize-pane -R 5 - - # split panes using | and - - bind | split-window -h - bind - split-window -v - unbind '"' - unbind % - - # switch panes using Alt-arrow without prefix - bind -n M-Left select-pane -L - bind -n M-Right select-pane -R - bind -n M-Up select-pane -U - bind -n M-Down select-pane -D - - ## Quickly switch panes - unbind ^J - bind ^J select-pane -t :.+ - - bind r source-file ~/.config/tmux/tmux.conf \; display "Config reloaded" - - set -g allow-passthrough on - ''; - }; - - programs.keychain = { - enable = true; - enableZshIntegration = true; - enableFishIntegration = true; - inheritType = "any"; - agents = ["gpg" "ssh"]; - keys = ["gitmain" "general"]; - }; - - programs.neovim = { - enable = true; - defaultEditor = true; - }; - modules.editors.astronvim.enable = true; - modules.editors.astronvim.userConfig.enable = true; - - modules.tools.fonts.enable = false; - - #graphical.enable = true; - #hyprland.enable = true; - /* - wayper = { - enable = true; - systemdIntegration = { - enable = true; - #target = "hyprland-session.target"; - }; - }; - */ - # kitty-conf.enable = true; - # wezterm-conf.enable = true; - #dunst.enable = true; - #rofi.enable = true; - #waybar.enable = true; - #services.a2ln.enable = true; - mpd.enable = true; - syncthing.enable = true; - neomutt.enable = true; - - #modules.tools.oci-script.enable = true; - - modules.cli.taskwarrior.enable = true; - - xdg.userDirs.enable = true; - xdg.enable = true; - xdg.configHome = "${config.home.homeDirectory}/.config"; - xdg = { - mime.enable = true; - mimeApps = { - enable = true; - }; - }; - # Nicely reload system units when changing configs - systemd.user.startServices = "sd-switch"; - - # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion - home.stateVersion = "22.11"; -} diff --git a/archives/home-manager/modules/default.nix b/archives/home-manager/modules/default.nix deleted file mode 100644 index 6b84d65..0000000 --- a/archives/home-manager/modules/default.nix +++ /dev/null @@ -1,8 +0,0 @@ -{ - imports = [ - ./browsers/firefox.nix - ./tools/task.nix - ./wayland-shell/ags/default.nix - ./wayland-shell/wayper.nix - ]; -} diff --git a/archives/home-manager/modules/modules.nix b/archives/home-manager/modules/modules.nix deleted file mode 100644 index b5f0939..0000000 --- a/archives/home-manager/modules/modules.nix +++ /dev/null @@ -1,14 +0,0 @@ -{ - inputs, - pkgs, - lib, - config, - ... -}: { - modules = inputs.haumea.lib.load { - src = ./modules; - inputs = { - inherit pkgs lib inputs config; - }; - }; -} diff --git a/archives/home-manager/modules/tools/fonts.nix b/archives/home-manager/modules/tools/fonts.nix deleted file mode 100644 index df62fa9..0000000 --- a/archives/home-manager/modules/tools/fonts.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ - pkgs, - lib, - config, - ... -}: -with lib; let - cfg = config.modules.tools.fonts; -in { - imports = []; - - options.modules.tools.fonts.enable = mkEnableOption "enable fonts"; - - config = mkIf (cfg.enable) { - home.packages = with pkgs; [ - # fonts - noto-fonts - noto-fonts-cjk - noto-fonts-emoji - liberation_ttf - fira-code - fira-code-symbols - jetbrains-mono - (nerdfonts.override {fonts = ["JetBrainsMono" "FiraCode" "Noto"];}) - self.packages.${pkgs.system}.iosevka-solemnattic - - fontconfig - ]; - - fonts.fontconfig.enable = true; - }; -} diff --git a/archives/home-manager/modules/tools/starship.nix b/archives/home-manager/modules/tools/starship.nix deleted file mode 100644 index 6fae190..0000000 --- a/archives/home-manager/modules/tools/starship.nix +++ /dev/null @@ -1,53 +0,0 @@ -{ - lib, - config, - ... -}: -with lib; let - cfg = config.modules.tools.starship; -in { - imports = []; - - options.modules.tools.starship.enable = mkEnableOption "enable the starship prompt"; - - config = mkIf (cfg.enable) { - programs.starship = mkMerge [ - { - enable = true; - enableTransience = true; - settings = { - add_newline = true; - continuation_prompt = "โ–ถโ–ถ "; - format = concatStrings [ - "[โ•ญโ”€](white) $username$hostname$directory$package$java$python$git_branch$battery$cmd_duration $line_break" - "[โ•ฐโ”€](white) $shell$character " - ]; - line_break = { - disabled = false; - }; - shell = { - disabled = false; - fish_indicator = "๐ŸŸ"; - }; - os = { - disabled = false; - }; - time = { - disabled = false; - format = "[$time]($style) "; - }; - username = { - show_always = true; - format = "[$user]($style)@"; - }; - hostname = { - ssh_only = false; - }; - }; - } - (mkIf (config.programs.fish.enable) { - enableFishIntegration = true; - }) - ]; - }; -} diff --git a/archives/home-manager/modules/tools/task.nix b/archives/home-manager/modules/tools/task.nix deleted file mode 100644 index 8e8501f..0000000 --- a/archives/home-manager/modules/tools/task.nix +++ /dev/null @@ -1,69 +0,0 @@ -{ - config, - lib, - pkgs, - outputs, - ... -}: -with lib; let - cfg = config.modules.tools.taskwarrior; -in { - imports = [outputs.homeManagerModules.secrets]; - - options.modules.tools.taskwarrior = { - enable = mkOption { - description = "Enable taskwarrior"; - default = false; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home.packages = with pkgs; [ - taskwarrior-tui - ]; - programs.taskwarrior = { - enable = true; - colorTheme = "dark-256"; - config = { - news.version = "2.6.0"; - default.command = "act"; - - report.act = { - description = "Unblocked tasks by project"; - columns = "id,project,priority,description.count,tags,due.relative"; - labels = "ID,Proj,Pri,Desc,Tags,Due"; - sort = "project+/,priority-,entry+"; - filter = "status:pending project!=misc -WAITING -BLOCKED -someday -notify_only"; - }; - - report.booklist = { - description = "Book list"; - columns = "id,description,tags,entry"; - labels = "ID,Desc,Tags,Entered"; - sort = "entry+"; - filter = "status:pending -WAITING -BLOCKED proj:misc.booklist"; - }; - - report.next = { - description = "What to work on next"; - columns = "id,project,description,tags"; - labels = "ID,Proj,Desc,Tags"; - filter = "+today status:pending -WAITING -BLOCKED -notify_only"; - }; - - taskd.trust = "strict"; - taskd.server = "app.wingtask.com:53589"; - taskd.key = config.age.secrets.taskd_key.path; - taskd.ca = config.age.secrets.taskd_ca.path; - taskd.certificate = config.age.secrets.taskd_cert.path; - # taskd.credentials = config.age.secrets.taskd_credentials.path; - }; - extraConfig = '' - include ${config.age.secrets.taskd_credentials.path} - ''; - }; - - services.taskwarrior-sync.enable = true; - }; -} diff --git a/archives/home-manager/mpd.nix b/archives/home-manager/mpd.nix deleted file mode 100644 index 2b27d4f..0000000 --- a/archives/home-manager/mpd.nix +++ /dev/null @@ -1,98 +0,0 @@ -{ - config, - lib, - pkgs, - inputs, - ... -}: -with lib; let - cfg = config.mpd; -in { - imports = []; - - options = { - mpd = { - enable = mkOption { - description = "Enable mpd music daemon service"; - default = true; - type = types.bool; - }; - }; - }; - - config = mkIf (cfg.enable) { - home.packages = with pkgs; [ - mpc-cli - playerctl - ]; - services.mpd = { - enable = true; - #musicDirectory = home.homeDirectory/Music; - - # allow remote control of mpd - network = { - listenAddress = "any"; - port = 6600; - startWhenNeeded = true; - }; - - extraConfig = '' - # visualizer - audio_output { - type "fifo" - name "my_fifo" - path "/tmp/mpd.fifo" - format "44100:16:2" - } - - # output to pulse on linux - audio_output { - type "pulse" - name "my pulse output" - } - ''; - }; - - # tui for mpd - programs.ncmpcpp = { - enable = true; - package = pkgs.ncmpcpp.override { - outputsSupport = true; - visualizerSupport = true; - clockSupport = true; - taglibSupport = true; - }; - settings = { - visualizer_data_source = "/tmp/mpd.fifo"; - visualizer_output_name = "my_fifo"; - visualizer_in_stereo = "yes"; - visualizer_type = "spectrum"; - visualizer_look = "+|"; - }; - }; - - # mpris2 support for mpd - services.mpdris2 = { - enable = true; - notifications = true; - mpd = { - host = "localhost"; - port = 6600; - }; - }; - - # show current playing in discord - services.mpd-discord-rpc.enable = true; - services.mpd-discord-rpc.settings = { - id = 1084861522888642661; - format = { - large_image = "suisei"; - small_image = "suisei3"; - large_text = "Sui-chan wa, kyou mo kawaii!!"; - small_text = "Hoshiyomi gang"; - }; - }; - - services.playerctld.enable = true; - }; -} diff --git a/archives/home-manager/neomutt.nix b/archives/home-manager/neomutt.nix deleted file mode 100644 index ad59070..0000000 --- a/archives/home-manager/neomutt.nix +++ /dev/null @@ -1,27 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: -with lib; let - cfg = config.neomutt; -in { - imports = []; - - options.neomutt = { - enable = mkOption { - default = false; - description = "Enable neomutt"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home.packages = with pkgs; [urlscan lynx]; - programs.neomutt = { - enable = true; - }; - programs.gpg.enable = true; - }; -} diff --git a/archives/home-manager/nvim/lazyvim-conf/.gitignore b/archives/home-manager/nvim/lazyvim-conf/.gitignore deleted file mode 100644 index cc5457a..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -tt.* -.tests -doc/tags -debug -.repro -foo.* -*.log -data diff --git a/archives/home-manager/nvim/lazyvim-conf/.neoconf.json b/archives/home-manager/nvim/lazyvim-conf/.neoconf.json deleted file mode 100644 index aa1b504..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/.neoconf.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "neodev": { - "library": { - "enabled": true, - "plugins": true - } - }, - "neoconf": { - "plugins": { - "sumneko_lua": { - "enabled": true - } - } - } -} diff --git a/archives/home-manager/nvim/lazyvim-conf/init.lua b/archives/home-manager/nvim/lazyvim-conf/init.lua deleted file mode 100644 index 2514f9e..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/init.lua +++ /dev/null @@ -1,2 +0,0 @@ --- bootstrap lazy.nvim, LazyVim and your plugins -require("config.lazy") diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/config/autocmds.lua b/archives/home-manager/nvim/lazyvim-conf/lua/config/autocmds.lua deleted file mode 100644 index 27e9e06..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/config/autocmds.lua +++ /dev/null @@ -1,3 +0,0 @@ --- Autocmds are automatically loaded on the VeryLazy event --- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua --- Add any additional autocmds here diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/config/keymaps.lua b/archives/home-manager/nvim/lazyvim-conf/lua/config/keymaps.lua deleted file mode 100644 index 0391c09..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/config/keymaps.lua +++ /dev/null @@ -1,20 +0,0 @@ --- Keymaps are automatically loaded on the VeryLazy event --- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua --- Add any additional keymaps here - -local function map(mode, lhs, rhs, opts) - local keys = require("lazy.core.handler").handlers.keys - ---@cast keys LazyKeysHandler - -- do not create the keymap if a lazy keys handler exists - if not keys.active[keys.parse({ lhs, mode = mode }).id] then - opts = opts or {} - opts.silent = opts.silent ~= false - if opts.remap and not vim.g.vscode then - opts.remap = nil - end - vim.keymap.set(mode, lhs, rhs, opts) - end -end - -map("n", "fs", "w", { desc = "Save current file" }) -map("n", "fS", "wa", { desc = "Save all open files" }) diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/config/lazy.lua b/archives/home-manager/nvim/lazyvim-conf/lua/config/lazy.lua deleted file mode 100644 index feaf095..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/config/lazy.lua +++ /dev/null @@ -1,48 +0,0 @@ -local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" -if not vim.loop.fs_stat(lazypath) then - -- bootstrap lazy.nvim - -- stylua: ignore - vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", - lazypath }) -end -vim.opt.rtp:prepend(vim.env.LAZY or lazypath) - -require("lazy").setup({ - spec = { - -- add LazyVim and import its plugins - { "LazyVim/LazyVim", import = "lazyvim.plugins" }, - -- import any extras modules here - -- { import = "lazyvim.plugins.extras.lang.typescript" }, - -- { import = "lazyvim.plugins.extras.lang.json" }, - { import = "lazyvim.plugins.extras.ui.mini-animate" }, - { import = "lazyvim.plugins.extras.lang.rust" }, - -- import/override with your plugins - { import = "plugins" }, - }, - defaults = { - -- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup. - -- If you know what you're doing, you can set this to `true` to have all your custom plugins lazy-loaded by default. - lazy = false, - -- It's recommended to leave version=false for now, since a lot the plugin that support versioning, - -- have outdated releases, which may break your Neovim install. - version = false, -- always use the latest git commit - -- version = "*", -- try installing the latest stable version for plugins that support semver - }, - -- install = { colorscheme = { "catppuccin" } }, - checker = { enabled = true }, -- automatically check for plugin updates - performance = { - rtp = { - -- disable some rtp plugins - disabled_plugins = { - "gzip", - -- "matchit", - -- "matchparen", - -- "netrwPlugin", - "tarPlugin", - "tohtml", - "tutor", - "zipPlugin", - }, - }, - }, -}) diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/config/options.lua b/archives/home-manager/nvim/lazyvim-conf/lua/config/options.lua deleted file mode 100644 index 13b4629..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/config/options.lua +++ /dev/null @@ -1,9 +0,0 @@ --- Options are automatically loaded before lazy.nvim startup --- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua --- Add any additional options here - --- show relative line numbers -vim.wo.number = "relativenumber" -vim.cmd([[ -set mousemodel=extend -]]) diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/example.lua b/archives/home-manager/nvim/lazyvim-conf/lua/plugins/example.lua deleted file mode 100644 index a38ab7e..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/example.lua +++ /dev/null @@ -1,267 +0,0 @@ --- since this is just an example spec, don't actually load anything here and return an empty spec --- stylua: ignore -if true then return {} end - --- every spec file under config.plugins will be loaded automatically by lazy.nvim --- --- In your plugin files, you can: --- * add extra plugins --- * disable/enabled LazyVim plugins --- * override the configuration of LazyVim plugins -return { - -- add gruvbox - { "ellisonleao/gruvbox.nvim" }, - - -- Configure LazyVim to load gruvbox - { - "LazyVim/LazyVim", - opts = { - colorscheme = "gruvbox", - }, - }, - - -- change trouble config - { - "folke/trouble.nvim", - -- opts will be merged with the parent spec - opts = { use_diagnostic_signs = true }, - }, - - -- disable trouble - { "folke/trouble.nvim", enabled = true }, - - -- add symbols-outline - { - "simrat39/symbols-outline.nvim", - cmd = "SymbolsOutline", - keys = { { "cs", "SymbolsOutline", desc = "Symbols Outline" } }, - config = true, - }, - - -- override nvim-cmp and add cmp-emoji - { - "hrsh7th/nvim-cmp", - dependencies = { "hrsh7th/cmp-emoji" }, - ---@param opts cmp.ConfigSchema - opts = function(_, opts) - local cmp = require("cmp") - opts.sources = cmp.config.sources(vim.list_extend(opts.sources, { { name = "emoji" } })) - end, - }, - - -- change some telescope options and a keymap to browse plugin files - { - "nvim-telescope/telescope.nvim", - keys = { - -- add a keymap to browse plugin files - -- stylua: ignore - { - "fp", - function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end, - desc = "Find Plugin File", - }, - }, - -- change some options - opts = { - defaults = { - layout_strategy = "horizontal", - layout_config = { prompt_position = "top" }, - sorting_strategy = "ascending", - winblend = 0, - }, - }, - }, - - -- add telescope-fzf-native - { - "telescope.nvim", - dependencies = { - "nvim-telescope/telescope-fzf-native.nvim", - build = "make", - config = function() - require("telescope").load_extension("fzf") - end, - }, - }, - - -- add pyright to lspconfig - { - "neovim/nvim-lspconfig", - ---@class PluginLspOpts - opts = { - ---@type lspconfig.options - servers = { - -- pyright will be automatically installed with mason and loaded with lspconfig - pyright = {}, - }, - }, - }, - - -- add tsserver and setup with typescript.nvim instead of lspconfig - { - "neovim/nvim-lspconfig", - dependencies = { - "jose-elias-alvarez/typescript.nvim", - init = function() - require("lazyvim.util").on_attach(function(_, buffer) - -- stylua: ignore - vim.keymap.set("n", "co", "TypescriptOrganizeImports", { buffer = buffer, desc = "Organize Imports" }) - vim.keymap.set("n", "cR", "TypescriptRenameFile", { desc = "Rename File", buffer = buffer }) - end) - end, - }, - ---@class PluginLspOpts - opts = { - ---@type lspconfig.options - servers = { - -- tsserver will be automatically installed with mason and loaded with lspconfig - tsserver = {}, - }, - -- you can do any additional lsp server setup here - -- return true if you don't want this server to be setup with lspconfig - ---@type table - setup = { - -- example to setup with typescript.nvim - tsserver = function(_, opts) - require("typescript").setup({ server = opts }) - return true - end, - -- Specify * to use this function as a fallback for any server - -- ["*"] = function(server, opts) end, - }, - }, - }, - - -- for typescript, LazyVim also includes extra specs to properly setup lspconfig, - -- treesitter, mason and typescript.nvim. So instead of the above, you can use: - { import = "lazyvim.plugins.extras.lang.typescript" }, - - -- add more treesitter parsers - { - "nvim-treesitter/nvim-treesitter", - opts = { - ensure_installed = { - "bash", - "help", - "html", - "javascript", - "json", - "lua", - "markdown", - "markdown_inline", - "python", - "query", - "regex", - "tsx", - "typescript", - "vim", - "yaml", - }, - }, - }, - - -- since `vim.tbl_deep_extend`, can only merge tables and not lists, the code above - -- would overwrite `ensure_installed` with the new value. - -- If you'd rather extend the default config, use the code below instead: - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - -- add tsx and treesitter - vim.list_extend(opts.ensure_installed, { - "tsx", - "typescript", - }) - end, - }, - - -- the opts function can also be used to change the default opts: - { - "nvim-lualine/lualine.nvim", - event = "VeryLazy", - opts = function(_, opts) - table.insert(opts.sections.lualine_x, "๐Ÿ˜„") - end, - }, - - -- or you can return new options to override all the defaults - { - "nvim-lualine/lualine.nvim", - event = "VeryLazy", - opts = function() - return { - --[[add your custom lualine config here]] - } - end, - }, - - -- use mini.starter instead of alpha - { import = "lazyvim.plugins.extras.ui.mini-starter" }, - - -- add jsonls and schemastore ans setup treesitter for json, json5 and jsonc - { import = "lazyvim.plugins.extras.lang.json" }, - - -- add any tools you want to have installed below - { - "williamboman/mason.nvim", - opts = { - ensure_installed = { - "stylua", - "shellcheck", - "shfmt", - "flake8", - }, - }, - }, - - -- Use for completion and snippets (supertab) - -- first: disable default and behavior in LuaSnip - { - "L3MON4D3/LuaSnip", - keys = function() - return {} - end, - }, - -- then: setup supertab in cmp - { - "hrsh7th/nvim-cmp", - dependencies = { - "hrsh7th/cmp-emoji", - }, - ---@param opts cmp.ConfigSchema - opts = function(_, opts) - local has_words_before = function() - unpack = unpack or table.unpack - local line, col = unpack(vim.api.nvim_win_get_cursor(0)) - return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil - end - - local luasnip = require("luasnip") - local cmp = require("cmp") - - opts.mapping = vim.tbl_extend("force", opts.mapping, { - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_next_item() - -- You could replace the expand_or_jumpable() calls with expand_or_locally_jumpable() - -- they way you will only jump inside the snippet region - elseif luasnip.expand_or_jumpable() then - luasnip.expand_or_jump() - elseif has_words_before() then - cmp.complete() - else - fallback() - end - end, { "i", "s" }), - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_prev_item() - elseif luasnip.jumpable(-1) then - luasnip.jump(-1) - else - fallback() - end - end, { "i", "s" }), - }) - end, - }, -} diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/lsp.lua b/archives/home-manager/nvim/lazyvim-conf/lua/plugins/lsp.lua deleted file mode 100644 index 7a5c563..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/lsp.lua +++ /dev/null @@ -1,176 +0,0 @@ -return { - -- change trouble config - { - "folke/trouble.nvim", - -- opts will be merged with the parent spec - opts = { use_diagnostic_signs = true }, - }, - - -- add symbols-outline - { - "simrat39/symbols-outline.nvim", - cmd = "SymbolsOutline", - keys = { { "cs", "SymbolsOutline", desc = "Symbols Outline" } }, - config = true, - }, - - -- change some telescope options and a keymap to browse plugin files - { - "nvim-telescope/telescope.nvim", - keys = { - -- add a keymap to browse plugin files - -- stylua: ignore - { - "fp", - function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end, - desc = "Find Plugin File", - }, - }, - -- change some options - opts = { - defaults = { - layout_strategy = "horizontal", - layout_config = { prompt_position = "top" }, - sorting_strategy = "ascending", - winblend = 0, - }, - }, - }, - - -- add wanted servers here - { - "neovim/nvim-lspconfig", - init = function() - local keys = require("lazyvim.plugins.lsp.keymaps").get() - -- change a keymap - keys[#keys + 1] = { "ch", vim.lsp.buf.hover, desc = "Hover Action" } - end, - ---@class PluginLspOpts - opts = { - ---@type lspconfig.options - servers = { - -- rnix = {}, - nil_ls = {}, - bashls = { - filetypes = { "sh", "bash" }, - }, - }, - }, - }, - - -- add more treesitter parsers - { - "nvim-treesitter/nvim-treesitter", - opts = { - ensure_installed = { - "bash", - "help", - "html", - "javascript", - "json", - "lua", - "markdown", - "markdown_inline", - "python", - "query", - "regex", - "tsx", - "typescript", - "vim", - "yaml", - "rust", - "nix", - "fish", - "ron", - }, - highlight = { - enable = true, - additional_vim_regex_highlighting = false, - }, - indent = { - enable = true, - }, - autopairs = { - enable = true, - }, - }, - }, - - { - "williamboman/mason.nvim", - opts = { - ensure_installed = { - "stylua", - "shellcheck", - "shfmt", - }, - PATH = "append", - }, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = { - sources = { - require("null-ls").builtins.formatting.nixpkgs_fmt, - require("null-ls").builtins.formatting.alejandra, - require("null-ls").builtins.formatting.shfmt, - }, - }, - }, - - -- Use for completion and snippets (supertab) - -- first: disable default and behavior in LuaSnip - { - "L3MON4D3/LuaSnip", - keys = function() - return {} - end, - }, - -- then: setup supertab in cmp - { - "hrsh7th/nvim-cmp", - dependencies = { - "hrsh7th/cmp-emoji", - }, - ---@param opts cmp.ConfigSchema - opts = function(_, opts) - local has_words_before = function() - unpack = unpack or table.unpack - local line, col = unpack(vim.api.nvim_win_get_cursor(0)) - return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil - end - - local luasnip = require("luasnip") - local cmp = require("cmp") - - local source_extend = { { name = "emoji" }, { name = "neorg" } } - opts.sources = cmp.config.sources(vim.list_extend(opts.sources, source_extend, 1, #source_extend)) - - opts.mapping = vim.tbl_extend("force", opts.mapping, { - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_next_item() - -- You could replace the expand_or_jumpable() calls with expand_or_locally_jumpable() - -- they way you will only jump inside the snippet region - elseif luasnip.expand_or_jumpable() then - luasnip.expand_or_jump() - elseif has_words_before() then - cmp.complete() - else - fallback() - end - end, { "i", "s" }), - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_prev_item() - elseif luasnip.jumpable(-1) then - luasnip.jump(-1) - else - fallback() - end - end, { "i", "s" }), - }) - end, - }, -} diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/rust.lua b/archives/home-manager/nvim/lazyvim-conf/lua/plugins/rust.lua deleted file mode 100644 index 919741d..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/rust.lua +++ /dev/null @@ -1,21 +0,0 @@ -return { - - -- allow rust-tools to manage rust-analyzer - -- { - -- 'simrat39/rust-tools.nvim', - -- config = true, - -- }, - -- - -- { - -- 'saecki/crates.nvim', - -- config = true - -- }, - - -- { "hrsh7th/nvim-cmp", - -- opts = { - -- sources = { - -- { name = "crates" } - -- } - -- } - -- } -} diff --git a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/ui.lua b/archives/home-manager/nvim/lazyvim-conf/lua/plugins/ui.lua deleted file mode 100644 index 46e8761..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/lua/plugins/ui.lua +++ /dev/null @@ -1,52 +0,0 @@ -return { - -- the catppuccin theme - -- { "catppuccin/nvim", name = "catppuccin", - -- opts = { - -- cmp = true, - -- gitsigns = true, - -- mason = true, - -- mini = true, - -- notify = false, - -- nvimtree = true, - -- symbols_outline = true, - -- telescope = true, - -- treesitter = true, - -- treesitter_context = true, - -- which_key = true, - -- } - -- }, - -- { "NTBBloodbath/sweetie.nvim" }, - - { - "folke/tokyonight.nvim", - opts = { - style = "moon", - styles = { - -- Style to be applied to different syntax groups - -- Value is any valid attr-list value for `:help nvim_set_hl` - comments = { italic = true }, - keywords = { italic = true }, - functions = {}, - variables = {}, - -- Background styles. Can be "dark", "transparent" or "normal" - sidebars = "dark", -- style for sidebars, see below - floats = "dark", -- style for floating windows - }, - }, - }, - - { - "LazyVim/LazyVim", - opts = { - colorscheme = "tokyonight", - }, - }, - - -- better escaping without delay - { - "max397574/better-escape.nvim", - opts = { - mapping = { "kj" }, - }, - }, -} diff --git a/archives/home-manager/nvim/lazyvim-conf/stylua.toml b/archives/home-manager/nvim/lazyvim-conf/stylua.toml deleted file mode 100644 index 5d6c50d..0000000 --- a/archives/home-manager/nvim/lazyvim-conf/stylua.toml +++ /dev/null @@ -1,3 +0,0 @@ -indent_type = "Spaces" -indent_width = 2 -column_width = 120 \ No newline at end of file diff --git a/archives/home-manager/nvim/lazyvim-nvim.nix b/archives/home-manager/nvim/lazyvim-nvim.nix deleted file mode 100644 index 51a64e3..0000000 --- a/archives/home-manager/nvim/lazyvim-nvim.nix +++ /dev/null @@ -1,56 +0,0 @@ -{ - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.lazyvim; -in { - options.lazyvim = { - enable = mkOption { - default = false; - description = "Enable lazyvim"; - type = types.bool; - }; - - userConfig = mkOption { - default = null; - description = "lazyvim extra config"; - type = with types; nullOr path; - }; - }; - config = mkIf (cfg.enable) { - home = { - file = { - ".config/nvim" = { - recursive = true; - source = ./lazyvim-conf; - }; - ".config/nvim/lua/custom" = mkIf (cfg.userConfig != null) { - recursive = true; - source = cfg.userConfig; - }; - }; - packages = with pkgs; [ - # telescope dependency - ripgrep - # build language servers - nodejs - python3 - cargo - lua51Packages.jsregexp - unzip - # for git ui - lazygit - - # lsps - nil - - # formatters - alejandra - shfmt - ]; - }; - }; -} diff --git a/archives/home-manager/rofi.nix b/archives/home-manager/rofi.nix deleted file mode 100644 index 6a6597c..0000000 --- a/archives/home-manager/rofi.nix +++ /dev/null @@ -1,39 +0,0 @@ -{ - pkgs, - lib, - config, - ... -}: -with lib; let - cfg = config.rofi; - catppuccin = - pkgs.fetchFromGitHub { - owner = "catppuccin"; - repo = "rofi"; - rev = "5350da41a11814f950c3354f090b90d4674a95ce"; - sha256 = "DNorfyl3C4RBclF2KDgwvQQwixpTwSRu7fIvihPN8JY="; - } - + "/deathemonic"; -in { - imports = []; - - options.rofi = { - enable = mkOption { - default = false; - description = "Enable rofi configuration"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home.packages = [ - pkgs.rofi-wayland - ]; - # programs.rofi = { - # enable = true; - # package = pkgs.rofi-wayland; - # #terminal = "\${pkgs.kitty}/bin/kitty"; - # }; - xdg.configFile."rofi".source = catppuccin; - }; -} diff --git a/archives/home-manager/syncthing.nix b/archives/home-manager/syncthing.nix deleted file mode 100644 index bbcbb20..0000000 --- a/archives/home-manager/syncthing.nix +++ /dev/null @@ -1,26 +0,0 @@ -{ - config, - lib, - pkgs, - inputs, - ... -}: -with lib; let - cfg = config.syncthing; -in { - imports = []; - - options.syncthing = { - enable = mkOption { - description = "enable syncthing"; - default = true; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - services.syncthing = { - enable = true; - }; - }; -} diff --git a/archives/home-manager/waybar.nix b/archives/home-manager/waybar.nix deleted file mode 100644 index f517ada..0000000 --- a/archives/home-manager/waybar.nix +++ /dev/null @@ -1,37 +0,0 @@ -{ - inputs, - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.waybar; -in { - imports = []; - - options.waybar = { - enable = mkOption { - default = false; - description = "Enable waybar, a bar"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home.packages = with pkgs; [ - font-awesome_5 - helvum - ]; - programs.waybar = { - enable = true; - systemd = { - enable = true; - target = "hyprland-session.target"; - }; - style = ./waybar/style.css; - settings = builtins.fromJSON (builtins.readFile ./waybar/config.json); - package = pkgs.waybar; - }; - }; -} diff --git a/archives/home-manager/wezterm.nix b/archives/home-manager/wezterm.nix deleted file mode 100644 index 4cd08db..0000000 --- a/archives/home-manager/wezterm.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ - config, - pkgs, - lib, - ... -}: -with lib; let - cfg = config.wezterm-conf; -in { - imports = []; - - options.wezterm-conf = { - enable = mkOption { - default = false; - description = "Enable the great kitty terminal config"; - type = types.bool; - }; - }; - - config = mkIf (cfg.enable) { - home = { - packages = with pkgs; [ - wezterm - ]; - }; - - programs.wezterm = { - enable = true; - extraConfig = builtins.readFile ./wezterm/wezterm.lua; - }; - }; -} diff --git a/archives/modules/home-manager/default.nix b/archives/modules/home-manager/default.nix deleted file mode 100644 index 0e9f60c..0000000 --- a/archives/modules/home-manager/default.nix +++ /dev/null @@ -1,8 +0,0 @@ -# Add your reusable home-manager modules to this directory, on their own file (https://nixos.wiki/wiki/Module). -# These should be stuff you would like to share with others, not your personal configurations. -{ - # List your module files here - # my-module = import ./my-module.nix; - a2ln = import ./a2ln.nix; - secrets = import ./secrets/module.nix; -} diff --git a/archives/modules/home-manager/secrets/module.nix b/archives/modules/home-manager/secrets/module.nix deleted file mode 100644 index 78ff5b8..0000000 --- a/archives/modules/home-manager/secrets/module.nix +++ /dev/null @@ -1,22 +0,0 @@ -{ - inputs, - config, - lib, - pkgs, - ... -}: { - imports = [ - inputs.agenix.homeManagerModules.default - ]; - - age = { - identityPaths = ["/home/luqman/.ssh/agenix"]; - secretsDir = "${config.home.homeDirectory}/.agenix/agenix"; - secretsMountPoint = "${config.home.homeDirectory}/.agenix/agenix.d"; - - secrets.taskd_credentials.file = ./taskd_credentials.age; - secrets.taskd_ca.file = ./taskd_ca.age; - secrets.taskd_key.file = ./taskd_key.age; - secrets.taskd_cert.file = ./taskd_cert.age; - }; -} diff --git a/archives/modules/nixos/cloudflare-warp.nix b/archives/modules/nixos/cloudflare-warp.nix deleted file mode 100644 index c0c830b..0000000 --- a/archives/modules/nixos/cloudflare-warp.nix +++ /dev/null @@ -1,114 +0,0 @@ -# credit to wolfangaukang who made this -{ - config, - lib, - pkgs, - ... -}: -with lib; let - cfg = config.services.cloudflare-warp; -in { - meta.maintainers = with maintainers; [wolfangaukang]; - - options = { - services.cloudflare-warp = { - enable = mkEnableOption (lib.mdDoc "cloudflare-warp, a service that replaces the connection between your device and the Internet with a modern, optimized, protocol"); - - package = mkOption { - type = types.package; - default = pkgs.cloudflare-warp; - defaultText = literalExpression "pkgs.cloudflare-warp"; - description = lib.mdDoc "The package to use for Cloudflare Warp."; - }; - - user = mkOption { - type = types.str; - default = "warp"; - description = lib.mdDoc "User account under which Cloudflare Warp runs."; - }; - - group = mkOption { - type = types.str; - default = "warp"; - description = lib.mdDoc "Group under which Cloudflare Warp runs."; - }; - - certificate = mkOption { - type = with types; nullOr path; - default = null; - description = lib.mdDoc '' - Path to the Cloudflare root certificate. There is a download link in the docs [here](https://developers.cloudflare.com/cloudflare-one/connections/connect-devices/warp/install-cloudflare-cert/). - ''; - }; - - udpPort = mkOption { - type = types.int; - default = 2408; - description = lib.mdDoc '' - The UDP port to open in the firewall. Warp uses port 2408 by default, but fallback ports can be used if that conflicts with another service. See the [firewall documentation](https://developers.cloudflare.com/cloudflare-one/connections/connect-devices/warp/deployment/firewall#warp-udp-ports) for the pre-configured available fallback ports. - ''; - }; - - openFirewall = mkOption { - type = types.bool; - default = false; - description = lib.mdDoc '' - Opens UDP port in the firewall. See `udpPort` configuration option, and [firewall documentation](https://developers.cloudflare.com/cloudflare-one/connections/connect-devices/warp/deployment/firewall#warp-udp-ports). - ''; - }; - }; - }; - - config = mkIf cfg.enable { - environment.systemPackages = with pkgs; [cfg.package]; - - security.pki = mkIf (cfg.certificate != null) { - certificateFiles = [cfg.certificate]; - }; - - networking.firewall = mkIf cfg.openFirewall { - allowedUDPPorts = [cfg.udpPort]; - }; - - users.users = mkIf (cfg.user == "warp") { - warp = { - isSystemUser = true; - group = "warp"; - description = "Cloudflare Warp user"; - home = "/var/lib/cloudflare-warp"; - }; - }; - users.groups = mkIf (cfg.group == "warp") { - warp = {}; - }; - - /* - systemd = { - packages = [cfg.package]; - services.warp-svc = { - after = ["network-online.target" "systemd-resolved.service"]; - wantedBy = ["multi-user.target"]; - serviceConfig = { - StateDirectory = "cloudflare-warp"; - User = "root"; - Umask = "0077"; - # Hardening - LockPersonality = true; - PrivateMounts = true; - PrivateTmp = true; - ProtectControlGroups = true; - ProtectHostname = true; - ProtectKernelLogs = true; - ProtectKernelModules = true; - ProtectKernelTunables = true; - ProtectProc = "invisible"; - # Leaving on strict activates warp on plus - ProtectSystem = "full"; - RestrictNamespaces = true; - RestrictRealtime = true; - }; - }; - }; - */ - }; -} diff --git a/archives/modules/nixos/default.nix b/archives/modules/nixos/default.nix deleted file mode 100644 index 30b1077..0000000 --- a/archives/modules/nixos/default.nix +++ /dev/null @@ -1,10 +0,0 @@ -# Add your reusable NixOS modules to this directory, on their own file (https://nixos.wiki/wiki/Module). -# These should be stuff you would like to share with others, not your personal configurations. -{ - # List your module files here - # my-module = import ./my-module.nix; - systemd-secure-boot = ./systemd-secure-boot/default.nix; - cloudflare-warp = ./cloudflare-warp.nix; - protonvpn = ./protonvpn.nix; - wifi-ap = ./wifi-ap.nix; -} diff --git a/flake.lock b/flake.lock index 4ac56fb..6f8e649 100644 --- a/flake.lock +++ b/flake.lock @@ -52,11 +52,11 @@ ] }, "locked": { - "lastModified": 1712136515, - "narHash": "sha256-LpjQJYC24S5P5XhJsZX6HqsQT1pohcFzM6N42I6qo/U=", + "lastModified": 1713259062, + "narHash": "sha256-WTO84hUL8IlNuHDK2yOCeJ38EewFzGt5E0kzBjNWxa8=", "owner": "Kirottu", "repo": "anyrun", - "rev": "be6728884d543665e7bd137bbef62dc1d04a210b", + "rev": "f9d30e34fa4ccb2797c6becec37e8bcff6585d39", "type": "github" }, "original": { @@ -68,12 +68,18 @@ "cachix": { "inputs": { "devenv": "devenv_2", - "flake-compat": "flake-compat_2", + "flake-compat": [ + "devenv", + "flake-compat" + ], "nixpkgs": [ "devenv", "nixpkgs" ], - "pre-commit-hooks": "pre-commit-hooks" + "pre-commit-hooks": [ + "devenv", + "pre-commit-hooks" + ] }, "locked": { "lastModified": 1712055811, @@ -152,17 +158,17 @@ "devenv": { "inputs": { "cachix": "cachix", - "flake-compat": "flake-compat_4", + "flake-compat": "flake-compat_2", "nix": "nix_2", "nixpkgs": "nixpkgs_3", - "pre-commit-hooks": "pre-commit-hooks_2" + "pre-commit-hooks": "pre-commit-hooks" }, "locked": { - "lastModified": 1713005873, - "narHash": "sha256-3DFCO/hK8h0Rs14t7uPr95gVHtKKADkjBh+JjSon8Aw=", + "lastModified": 1713968789, + "narHash": "sha256-Gue8iwW3ZtCQs3EZKhk/i0uLaoUDfW1dpnaZ67MH64o=", "owner": "cachix", "repo": "devenv", - "rev": "8e882058b4602b70093d1fbff57755db09e89f11", + "rev": "b26b52a4dac68bdc305f6b9df948c97f49b2c3ee", "type": "github" }, "original": { @@ -247,11 +253,11 @@ ] }, "locked": { - "lastModified": 1712947906, - "narHash": "sha256-T0eT2lMbcK7RLelkx0qx4SiFpOS/0dt0aSfLB+WsGV8=", + "lastModified": 1713875178, + "narHash": "sha256-FFJ4dojuziC6HLxugW+2YJ1P+m5veDq0WZSpZRSm/SY=", "owner": "nix-community", "repo": "disko", - "rev": "8d4ae698eaac8bd717e23507da2ca8b345bec4b5", + "rev": "dea314155a9b8a4de242bdd4c005ba8a5dce8385", "type": "github" }, "original": { @@ -370,38 +376,6 @@ "type": "github" } }, - "flake-compat_5": { - "flake": false, - "locked": { - "lastModified": 1673956053, - "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_6": { - "flake": false, - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -473,11 +447,11 @@ ] }, "locked": { - "lastModified": 1709336216, - "narHash": "sha256-Dt/wOWeW6Sqm11Yh+2+t0dfEWxoMxGBvv3JpIocFl9E=", + "lastModified": 1712014858, + "narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "f7b3c975cf067e56e7cda6cb098ebe3fb4d74ca2", + "rev": "9126214d0a59633752a136528f5f3b9aa8565b7d", "type": "github" }, "original": { @@ -521,11 +495,11 @@ }, "flake-root": { "locked": { - "lastModified": 1692742795, - "narHash": "sha256-f+Y0YhVCIJ06LemO+3Xx00lIcqQxSKJHXT/yk1RTKxw=", + "lastModified": 1713493429, + "narHash": "sha256-ztz8JQkI08tjKnsTpfLqzWoKFQF4JGu2LRz8bkdnYUk=", "owner": "srid", "repo": "flake-root", - "rev": "d9a70d9c7a5fd7f3258ccf48da9335e9b47c3937", + "rev": "bc748b93b86ee76e2032eecda33440ceb2532fcd", "type": "github" }, "original": { @@ -575,11 +549,11 @@ "systems": "systems_3" }, "locked": { - "lastModified": 1701680307, - "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -590,7 +564,7 @@ }, "flake-utils_3": { "inputs": { - "systems": "systems_4" + "systems": "systems_8" }, "locked": { "lastModified": 1710146030, @@ -611,11 +585,11 @@ "systems": "systems_9" }, "locked": { - "lastModified": 1701680307, - "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -647,11 +621,11 @@ "systems": "systems_11" }, "locked": { - "lastModified": 1701680307, - "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -731,29 +705,6 @@ } }, "gitignore": { - "inputs": { - "nixpkgs": [ - "devenv", - "cachix", - "pre-commit-hooks", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1703887061, - "narHash": "sha256-gGPa9qWNc6eCXT/+Z5/zMkyYOuRZqeFZBDbopNZQkuY=", - "owner": "hercules-ci", - "repo": "gitignore.nix", - "rev": "43e1aa1308018f37118e34d3a9cb4f5e75dc11d5", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "gitignore.nix", - "type": "github" - } - }, - "gitignore_2": { "inputs": { "nixpkgs": [ "devenv", @@ -784,11 +735,11 @@ ] }, "locked": { - "lastModified": 1710478346, - "narHash": "sha256-Xjf8BdnQG0tLhPMlqQdwCIjOp7Teox0DP3N/jjyiGM4=", + "lastModified": 1713898448, + "narHash": "sha256-6q6ojsp/Z9P2goqnxyfCSzFOD92T3Uobmj8oVAicUOs=", "owner": "hercules-ci", "repo": "hercules-ci-effects", - "rev": "64e7763d72c1e4c1e5e6472640615b6ae2d40fbf", + "rev": "c0302ec12d569532a6b6bd218f698bc402e93adc", "type": "github" }, "original": { @@ -825,11 +776,11 @@ ] }, "locked": { - "lastModified": 1713077896, - "narHash": "sha256-Noot8H0EZEAFRQWyGxh9ryvhK96xpIqKbh78X447JWs=", + "lastModified": 1713906585, + "narHash": "sha256-fv84DCOkBtjF6wMATt0rfovu7e95L8rdEkSfNbwKR3U=", "owner": "nix-community", "repo": "home-manager", - "rev": "630a0992b3627c64e34f179fab68e3d48c6991c0", + "rev": "bfa7c06436771e3a0c666ccc6ee01e815d4c33aa", "type": "github" }, "original": { @@ -914,7 +865,7 @@ "inputs": { "hyprlang": "hyprlang", "nixpkgs": "nixpkgs_4", - "systems": "systems_5" + "systems": "systems_4" }, "locked": { "lastModified": 1710180874, @@ -939,7 +890,7 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems_7", + "systems": "systems_6", "wlroots": "wlroots", "xdph": "xdph" }, @@ -1062,7 +1013,7 @@ "hyprcursor", "nixpkgs" ], - "systems": "systems_6" + "systems": "systems_5" }, "locked": { "lastModified": 1709914708, @@ -1179,7 +1130,7 @@ "inputs": { "hyprlang": "hyprlang_4", "nixpkgs": "nixpkgs_5", - "systems": "systems_8" + "systems": "systems_7" }, "locked": { "lastModified": 1710690277, @@ -1271,18 +1222,18 @@ }, "neovim-flake": { "inputs": { - "flake-utils": "flake-utils_4", + "flake-utils": "flake-utils_3", "nixpkgs": [ "nixpkgs" ] }, "locked": { "dir": "contrib", - "lastModified": 1713093670, - "narHash": "sha256-eXFQbG5DmeLHHWlddGMAfYdVbKiwDYDPNDPnb9WBiiQ=", + "lastModified": 1713988022, + "narHash": "sha256-yeEl4zvf6vyMjDbYYbukGCzXcf9n+2duj4YRYwdnET8=", "owner": "neovim", "repo": "neovim", - "rev": "4ca6e08327496ed5efc3465c42464319302ba22a", + "rev": "7f084770c23855083776b0598f2f54bb59a06875", "type": "github" }, "original": { @@ -1294,7 +1245,7 @@ }, "neovim-flake_2": { "inputs": { - "flake-utils": "flake-utils_5", + "flake-utils": "flake-utils_4", "nixpkgs": [ "neovim-nightly-overlay", "nixpkgs" @@ -1302,11 +1253,11 @@ }, "locked": { "dir": "contrib", - "lastModified": 1713051308, - "narHash": "sha256-DaaiUHENmPl1vPrQIJY7sl/LspPBQ/XiLIVeLfqpkKw=", + "lastModified": 1713891901, + "narHash": "sha256-pL11HPJJQ9U5Lq/I5jfHPZGBcjIgm06pvcX+jF7dQrM=", "owner": "neovim", "repo": "neovim", - "rev": "a92822835521574710a830a7de0e692bf7517fb8", + "rev": "c81b7849a0f677164c01cf84ecfb25c1f47acf21", "type": "github" }, "original": { @@ -1318,18 +1269,18 @@ }, "neovim-nightly-overlay": { "inputs": { - "flake-compat": "flake-compat_6", + "flake-compat": "flake-compat_3", "flake-parts": "flake-parts_3", "hercules-ci-effects": "hercules-ci-effects", "neovim-flake": "neovim-flake_2", "nixpkgs": "nixpkgs_6" }, "locked": { - "lastModified": 1713053047, - "narHash": "sha256-x17vugcgPuF+w5MpeYUbOlmUw/8tz7W4UetHKCode0E=", + "lastModified": 1713917052, + "narHash": "sha256-gFeBWAE5ju8na9C2PHOY1ivFQLON8ptZShC0yVAAf+0=", "owner": "nix-community", "repo": "neovim-nightly-overlay", - "rev": "8fa4fbe03aa7475441dd1b9c62e36feea083bfb0", + "rev": "36ebd81eec6aa60234a031ab012dd704329d29f0", "type": "github" }, "original": { @@ -1340,7 +1291,7 @@ }, "nil": { "inputs": { - "flake-utils": "flake-utils_6", + "flake-utils": "flake-utils_5", "nixpkgs": "nixpkgs_7", "rust-overlay": "rust-overlay" }, @@ -1370,11 +1321,11 @@ "nixpkgs-regression": "nixpkgs-regression" }, "locked": { - "lastModified": 1708577783, - "narHash": "sha256-92xq7eXlxIT5zFNccLpjiP7sdQqQI30Gyui2p/PfKZM=", + "lastModified": 1712911606, + "narHash": "sha256-BGvBhepCufsjcUkXnEEXhEVjwdJAwPglCC2+bInc794=", "owner": "domenkozar", "repo": "nix", - "rev": "ecd0af0c1f56de32cbad14daa1d82a132bf298f8", + "rev": "b24a9318ea3f3600c1e24b4a00691ee912d4de12", "type": "github" }, "original": { @@ -1410,7 +1361,7 @@ }, "nix2container": { "inputs": { - "flake-utils": "flake-utils_7", + "flake-utils": "flake-utils_6", "nixpkgs": [ "nixpkgs" ] @@ -1431,7 +1382,10 @@ }, "nix_2": { "inputs": { - "flake-compat": "flake-compat_5", + "flake-compat": [ + "devenv", + "flake-compat" + ], "nixpkgs": [ "devenv", "nixpkgs" @@ -1468,6 +1422,21 @@ "type": "github" } }, + "nixos-flake": { + "locked": { + "lastModified": 1711376798, + "narHash": "sha256-37wawZGSX/dD1rn7TwFJhUdpozC2VPEQXetpfpK/D+w=", + "owner": "srid", + "repo": "nixos-flake", + "rev": "7b19503e7f8c7cc0884fc2fbd669c0cc2e05aef5", + "type": "github" + }, + "original": { + "owner": "srid", + "repo": "nixos-flake", + "type": "github" + } + }, "nixos-generators": { "inputs": { "nixlib": "nixlib", @@ -1476,11 +1445,11 @@ ] }, "locked": { - "lastModified": 1712537332, - "narHash": "sha256-yYlxv1sg/TNl6hghjAe0ct+/p5PwXiT1mpuaExjhR88=", + "lastModified": 1713783234, + "narHash": "sha256-3yh0nqI1avYUmmtqqTW3EVfwaLE+9ytRWxsA5aWtmyI=", "owner": "nix-community", "repo": "nixos-generators", - "rev": "d942db8df8ee860556a38754f15b8d03bf7e6933", + "rev": "722b512eb7e6915882f39fff0e4c9dd44f42b77e", "type": "github" }, "original": { @@ -1491,11 +1460,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1712909959, - "narHash": "sha256-7/5ubuwdEbQ7Z+Vqd4u0mM5L2VMNDsBh54visp27CtQ=", + "lastModified": 1713864415, + "narHash": "sha256-/BPDMJEkrsFAFOsQWhwm31wezlgshPFlLBn34KEUdVA=", "owner": "nixos", "repo": "nixos-hardware", - "rev": "f58b25254be441cd2a9b4b444ed83f1e51244f1f", + "rev": "797f8d8082c7cc3259cba7275c699d4991b09ecc", "type": "github" }, "original": { @@ -1504,6 +1473,28 @@ "type": "github" } }, + "nixos-wsl": { + "inputs": { + "flake-compat": "flake-compat_4", + "flake-utils": "flake-utils_7", + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1713947658, + "narHash": "sha256-q3zu2D5HVphfAMZ070o/K9IPxw5DLsLkvwr7H1b5fpE=", + "owner": "nix-community", + "repo": "NixOS-WSL", + "rev": "f41f95c2c187a49a4ef98b5d00fdf1a68c5f88ba", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "NixOS-WSL", + "type": "github" + } + }, "nixpkgs": { "locked": { "lastModified": 1703013332, @@ -1571,22 +1562,6 @@ } }, "nixpkgs-stable": { - "locked": { - "lastModified": 1704874635, - "narHash": "sha256-YWuCrtsty5vVZvu+7BchAxmcYzTMfolSPP5io8+WYCg=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "3dc440faeee9e889fe2d1b4d25ad0f430d449356", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-23.11", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-stable_2": { "locked": { "lastModified": 1710695816, "narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=", @@ -1732,11 +1707,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1710796454, - "narHash": "sha256-lQlICw60RhH8sHTDD/tJiiJrlAfNn8FDI9c+7G2F0SE=", + "lastModified": 1713361204, + "narHash": "sha256-TA6EDunWTkc5FvDCqU3W2T3SFn0gRZqh6D/hJnM02MM=", "owner": "cachix", "repo": "devenv-nixpkgs", - "rev": "06fb0f1c643aee3ae6838dda3b37ef0abc3c763b", + "rev": "285676e87ad9f0ca23d8714a6ab61e7e027020c6", "type": "github" }, "original": { @@ -1780,11 +1755,11 @@ }, "nixpkgs_6": { "locked": { - "lastModified": 1712883908, - "narHash": "sha256-icE1IJE9fHcbDfJ0+qWoDdcBXUoZCcIJxME4lMHwvSM=", + "lastModified": 1713805509, + "narHash": "sha256-YgSEan4CcrjivCNO5ZNzhg7/8ViLkZ4CB/GrGBVSudo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "a0c9e3aee1000ac2bfb0e5b98c94c946a5d180a9", + "rev": "1e1dc66fe68972a76679644a5577828b6a7e8be4", "type": "github" }, "original": { @@ -1812,11 +1787,11 @@ }, "nixpkgs_8": { "locked": { - "lastModified": 1712791164, - "narHash": "sha256-3sbWO1mbpWsLepZGbWaMovSO7ndZeFqDSdX0hZ9nVyw=", + "lastModified": 1713895582, + "narHash": "sha256-cfh1hi+6muQMbi9acOlju3V1gl8BEaZBXBR9jQfQi4U=", "owner": "nixos", "repo": "nixpkgs", - "rev": "1042fd8b148a9105f3c0aca3a6177fd1d9360ba5", + "rev": "572af610f6151fd41c212f897c71f7056e3fb518", "type": "github" }, "original": { @@ -1911,51 +1886,25 @@ } }, "pre-commit-hooks": { - "inputs": { - "flake-compat": "flake-compat_3", - "flake-utils": "flake-utils_2", - "gitignore": "gitignore", - "nixpkgs": [ - "devenv", - "cachix", - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable" - }, - "locked": { - "lastModified": 1708018599, - "narHash": "sha256-M+Ng6+SePmA8g06CmUZWi1AjG2tFBX9WCXElBHEKnyM=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "5df5a70ad7575f6601d91f0efec95dd9bc619431", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, - "pre-commit-hooks_2": { "inputs": { "flake-compat": [ "devenv", "flake-compat" ], - "flake-utils": "flake-utils_3", - "gitignore": "gitignore_2", + "flake-utils": "flake-utils_2", + "gitignore": "gitignore", "nixpkgs": [ "devenv", "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable_2" + "nixpkgs-stable": "nixpkgs-stable" }, "locked": { - "lastModified": 1712897695, - "narHash": "sha256-nMirxrGteNAl9sWiOhoN5tIHyjBbVi5e2tgZUgZlK3Y=", + "lastModified": 1713775815, + "narHash": "sha256-Wu9cdYTnGQQwtT20QQMg7jzkANKQjwBD9iccfGKkfls=", "owner": "cachix", "repo": "pre-commit-hooks.nix", - "rev": "40e6053ecb65fcbf12863338a6dcefb3f55f1bf8", + "rev": "2ac4dcbf55ed43f3be0bae15e181f08a57af24a4", "type": "github" }, "original": { @@ -2025,8 +1974,10 @@ "neovim-nightly-overlay": "neovim-nightly-overlay", "nil": "nil", "nix2container": "nix2container", + "nixos-flake": "nixos-flake", "nixos-generators": "nixos-generators", "nixos-hardware": "nixos-hardware", + "nixos-wsl": "nixos-wsl", "nixpkgs": "nixpkgs_8", "treefmt-nix": "treefmt-nix", "wayper": "wayper", @@ -2301,16 +2252,16 @@ }, "systems_4": { "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "lastModified": 1689347949, + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "repo": "default-linux", + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", "type": "github" }, "original": { "owner": "nix-systems", - "repo": "default", + "repo": "default-linux", "type": "github" } }, @@ -2361,16 +2312,16 @@ }, "systems_8": { "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", "type": "github" }, "original": { "owner": "nix-systems", - "repo": "default-linux", + "repo": "default", "type": "github" } }, diff --git a/flake.nix b/flake.nix index e7be62c..567ebf7 100644 --- a/flake.nix +++ b/flake.nix @@ -1,6 +1,72 @@ { description = "Luqman's Nix Config done right"; + outputs = inputs @ { + self, + flake-parts, + flake-root, + home-manager, + nixpkgs, + treefmt-nix, + devenv, + nixos-flake, + ... + }: let + # Use our custom lib enhanced with nixpkgs and home-manager + lib = import ./nix/lib {inherit (nixpkgs) lib;} // nixpkgs.lib // home-manager.lib; + in + flake-parts.lib.mkFlake { + inherit inputs; + specialArgs = {inherit lib;}; + } { + debug = true; + imports = [ + flake-root.flakeModule + nixos-flake.flakeModule + treefmt-nix.flakeModule + devenv.flakeModule + ./nix + ./nixos + ./home + ]; + + systems = [ + "aarch64-linux" + "aarch64-darwin" + "x86_64-darwin" + "x86_64-linux" + ]; + + flake = { + #main laptop + nixosConfigurations.asuna = self.nixos-flake.lib.mkLinuxSystem ./systems/asuna; + + # configuration for WSL + nixosConfigurations.sinon = self.nixos-flake.lib.mkLinuxSystem ./systems/sinon.nix; + }; + + _module.args._inputs = inputs // {inherit self;}; + + perSystem = { + pkgs, + system, + ... + }: { + # make pkgs available to all `perSystem` functions + _module.args.pkgs = import inputs.nixpkgs { + inherit system; + overlays = [ + inputs.neovim-nightly-overlay.overlay + ]; + }; + + # make custom lib available to all `perSystem` functions + _module.args.lib = lib; + + packages = import ./pkgs {inherit pkgs;}; + }; + }; + nixConfig = { extra-substituters = [ "https://nix-community.cachix.org" @@ -10,9 +76,16 @@ ]; }; + # TODO: sort the damn inputs inputs = { # packages nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + home-manager = { + url = "github:nix-community/home-manager"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + # nix darwin when we need it only + nil.url = "github:oxalica/nil"; alejandra = { url = "github:kamadorueda/alejandra/3.0.0"; @@ -26,6 +99,7 @@ inputs.nixpkgs-lib.follows = "nixpkgs"; }; flake-root.url = "github:srid/flake-root"; + nixos-flake.url = "github:srid/nixos-flake"; # utilities nixos-generators = { @@ -42,10 +116,8 @@ inputs.nixpkgs.follows = "nixpkgs"; }; nixos-hardware.url = "github:nixos/nixos-hardware"; - home-manager = { - url = "github:nix-community/home-manager"; - inputs.nixpkgs.follows = "nixpkgs"; - }; + nixos-wsl.url = "github:nix-community/NixOS-WSL"; + nixos-wsl.inputs.nixpkgs.follows = "nixpkgs"; impermanence.url = "github:nix-community/impermanence"; hyprland = { url = "github:hyprwm/Hyprland/v0.37.1"; @@ -74,70 +146,4 @@ nix2container.inputs = {nixpkgs.follows = "nixpkgs";}; mk-shell-bin.url = "github:rrbutani/nix-mk-shell-bin"; }; - - outputs = inputs @ { - self, - flake-parts, - flake-root, - home-manager, - nixpkgs, - treefmt-nix, - devenv, - ... - }: let - # Use our custom lib enhanced with nixpkgs and home-manager - lib = import ./nix/lib {lib = nixpkgs.lib;} // nixpkgs.lib // home-manager.lib; - in - flake-parts.lib.mkFlake { - inherit inputs; - specialArgs = {inherit lib;}; - } { - debug = true; - imports = [ - flake-root.flakeModule - treefmt-nix.flakeModule - devenv.flakeModule - ./nix - ./nixos - ]; - - systems = [ - "aarch64-linux" - "aarch64-darwin" - "x86_64-darwin" - "x86_64-linux" - ]; - - flake = { - # overlays? - overlays = { - # channels = final: prev: { - # # expose other channels via overlays - # }; - }; - homeManagerModules = import ./modules/home-manager; - }; - - _module.args._inputs = inputs // {inherit self;}; - - perSystem = { - inputs', - pkgs, - system, - ... - }: { - # make pkgs available to all `perSystem` functions - _module.args.pkgs = import inputs.nixpkgs { - inherit system; - overlays = [ - inputs.neovim-nightly-overlay.overlay - ]; - }; - - # make custom lib available to all `perSystem` functions - _module.args.lib = lib; - - packages = import ./pkgs {inherit pkgs;}; - }; - }; } diff --git a/nixos/modules/home-manager/browsers/firefox.nix b/home/browsers/firefox.nix similarity index 100% rename from nixos/modules/home-manager/browsers/firefox.nix rename to home/browsers/firefox.nix diff --git a/home/configopts.nix b/home/configopts.nix new file mode 100644 index 0000000..4e1d7f8 --- /dev/null +++ b/home/configopts.nix @@ -0,0 +1,4 @@ +{lib, ...}: { + # TODO: options to be used in the future + options.solemnattic.gui = lib.mkEnableOption "gui"; +} diff --git a/home/default.nix b/home/default.nix new file mode 100644 index 0000000..9d23ad2 --- /dev/null +++ b/home/default.nix @@ -0,0 +1,51 @@ +{self, ...}: { + flake = { + homeModules = { + # common modules that should be imported by everyone. + # these modules should be usable in all environments + common = { + imports = [ + ./configopts.nix + ./editors/astronvim + ./tools/shell.nix + ./tools/starship.nix + ./terminals/zellij.nix + ./tools/mpd.nix + ./tools/task.nix + ./secrets + ]; + home.stateVersion = "22.11"; + }; + + gui.imports = [ + ./tools/fonts.nix + ./terminals/kitty.nix + ./browsers/firefox.nix + ./prod/essentials.nix + ./terminals/wezterm + ]; + + wayland.imports = [ + ./wayland-shell/hyprland + ./wayland-shell/wayper.nix + ./wayland-shell/dunst.nix + ./wayland-shell/rofi.nix + ./wayland-shell/anyrun + ./wayland-shell/waybar + ]; + + misc-gui.imports = [ + ./prod/school.nix + ]; + + # for specific systems + + luqman-sinon = { + imports = [ + self.homeModules.common + ./luqman-home.nix + ]; + }; + }; + }; +} diff --git a/nixos/modules/home-manager/editors/astronvim/config/.neoconf.json b/home/editors/astronvim/config/.neoconf.json similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/.neoconf.json rename to home/editors/astronvim/config/.neoconf.json diff --git a/nixos/modules/home-manager/editors/astronvim/config/README.md b/home/editors/astronvim/config/README.md similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/README.md rename to home/editors/astronvim/config/README.md diff --git a/nixos/modules/home-manager/editors/astronvim/config/init.lua b/home/editors/astronvim/config/init.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/init.lua rename to home/editors/astronvim/config/init.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/community.lua b/home/editors/astronvim/config/lua/community.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/community.lua rename to home/editors/astronvim/config/lua/community.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/lazy_setup.lua b/home/editors/astronvim/config/lua/lazy_setup.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/lazy_setup.lua rename to home/editors/astronvim/config/lua/lazy_setup.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astrocore.lua b/home/editors/astronvim/config/lua/plugins/astrocore.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astrocore.lua rename to home/editors/astronvim/config/lua/plugins/astrocore.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astrolsp.lua b/home/editors/astronvim/config/lua/plugins/astrolsp.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astrolsp.lua rename to home/editors/astronvim/config/lua/plugins/astrolsp.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astroui.lua b/home/editors/astronvim/config/lua/plugins/astroui.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/astroui.lua rename to home/editors/astronvim/config/lua/plugins/astroui.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/chezmoi.lua b/home/editors/astronvim/config/lua/plugins/chezmoi.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/chezmoi.lua rename to home/editors/astronvim/config/lua/plugins/chezmoi.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/cmp.lua b/home/editors/astronvim/config/lua/plugins/cmp.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/cmp.lua rename to home/editors/astronvim/config/lua/plugins/cmp.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/mason.lua b/home/editors/astronvim/config/lua/plugins/mason.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/mason.lua rename to home/editors/astronvim/config/lua/plugins/mason.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/neorg.lua b/home/editors/astronvim/config/lua/plugins/neorg.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/neorg.lua rename to home/editors/astronvim/config/lua/plugins/neorg.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/neovide.lua b/home/editors/astronvim/config/lua/plugins/neovide.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/neovide.lua rename to home/editors/astronvim/config/lua/plugins/neovide.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/none-ls.lua b/home/editors/astronvim/config/lua/plugins/none-ls.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/none-ls.lua rename to home/editors/astronvim/config/lua/plugins/none-ls.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/term.lua b/home/editors/astronvim/config/lua/plugins/term.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/term.lua rename to home/editors/astronvim/config/lua/plugins/term.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/treesitter.lua b/home/editors/astronvim/config/lua/plugins/treesitter.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/treesitter.lua rename to home/editors/astronvim/config/lua/plugins/treesitter.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/plugins/user.lua b/home/editors/astronvim/config/lua/plugins/user.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/plugins/user.lua rename to home/editors/astronvim/config/lua/plugins/user.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/lua/polish.lua b/home/editors/astronvim/config/lua/polish.lua similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/lua/polish.lua rename to home/editors/astronvim/config/lua/polish.lua diff --git a/nixos/modules/home-manager/editors/astronvim/config/neovim.yml b/home/editors/astronvim/config/neovim.yml similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/neovim.yml rename to home/editors/astronvim/config/neovim.yml diff --git a/nixos/modules/home-manager/editors/astronvim/config/selene.toml b/home/editors/astronvim/config/selene.toml similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/selene.toml rename to home/editors/astronvim/config/selene.toml diff --git a/nixos/modules/home-manager/editors/astronvim/config/stylua.toml b/home/editors/astronvim/config/stylua.toml similarity index 100% rename from nixos/modules/home-manager/editors/astronvim/config/stylua.toml rename to home/editors/astronvim/config/stylua.toml diff --git a/nixos/modules/home-manager/editors/astronvim/default.nix b/home/editors/astronvim/default.nix similarity index 90% rename from nixos/modules/home-manager/editors/astronvim/default.nix rename to home/editors/astronvim/default.nix index 3a9383d..6d0b393 100644 --- a/nixos/modules/home-manager/editors/astronvim/default.nix +++ b/home/editors/astronvim/default.nix @@ -1,5 +1,4 @@ { - inputs, config, pkgs, lib, @@ -62,7 +61,8 @@ in { programs.neovim = { enable = true; - package = inputs.neovim-flake.packages.${pkgs.system}.neovim; + package = pkgs.neovim-nightly; + # package = inputs.neovim-flake.packages.${pkgs.system}.neovim; # we avoid using the wrapped neovim thing }; }; diff --git a/nixos/modules/home-manager/games/general.nix b/home/games/general.nix similarity index 94% rename from nixos/modules/home-manager/games/general.nix rename to home/games/general.nix index 8da57a1..4e8ad94 100644 --- a/nixos/modules/home-manager/games/general.nix +++ b/home/games/general.nix @@ -7,6 +7,7 @@ gamescope mangohud scrcpy + discord ]; }; } diff --git a/home/luqman-home.nix b/home/luqman-home.nix new file mode 100644 index 0000000..7c127bc --- /dev/null +++ b/home/luqman-home.nix @@ -0,0 +1,17 @@ +{config, ...}: { + home = { + username = "luqman"; + homeDirectory = "/home/luqman"; + sessionVariables = { + COLORTERM = "truecolor"; + XDG_CONFIG_HOME = "${config.home.homeDirectory}/.config"; + MEOW = "cat"; + }; + }; + + xdg = { + enable = true; + userDirs.enable = true; + configHome = "${config.home.homeDirectory}/.config"; + }; +} diff --git a/home/nix.nix b/home/nix.nix new file mode 100644 index 0000000..95b25bd --- /dev/null +++ b/home/nix.nix @@ -0,0 +1,4 @@ +{ + # Garbage collect automatically every week + nix.gc.automatic = true; +} diff --git a/home/prod/essentials.nix b/home/prod/essentials.nix new file mode 100644 index 0000000..04a248b --- /dev/null +++ b/home/prod/essentials.nix @@ -0,0 +1,7 @@ +{pkgs, ...}: { + home.packages = with pkgs; [ + tdesktop + obsidian + zathura + ]; +} diff --git a/nixos/modules/home-manager/prod/school.nix b/home/prod/school.nix similarity index 70% rename from nixos/modules/home-manager/prod/school.nix rename to home/prod/school.nix index 53f2cfe..f599f28 100644 --- a/nixos/modules/home-manager/prod/school.nix +++ b/home/prod/school.nix @@ -3,18 +3,11 @@ home = { packages = with pkgs; [ #desktop apps - tdesktop # TODO: move these browsers into their own file chromium microsoft-edge - pavucontrol - obsidian - zathura foliate libreoffice - logseq - - discord ]; }; }; diff --git a/nixos/modules/home-manager/secrets/default.nix b/home/secrets/default.nix similarity index 77% rename from nixos/modules/home-manager/secrets/default.nix rename to home/secrets/default.nix index 3287665..35adccc 100644 --- a/nixos/modules/home-manager/secrets/default.nix +++ b/home/secrets/default.nix @@ -1,14 +1,16 @@ { - inputs, + flake, config, ... -}: { +}: let + inherit (flake) inputs; +in { imports = [ inputs.agenix.homeManagerModules.default ]; age = { - identityPaths = ["/home/luqman/.ssh/agenix"]; + identityPaths = ["/home/luqman/.ssh/agenix" "/home/luqman/.ssh/general"]; secretsDir = "${config.home.homeDirectory}/.agenix/agenix"; secretsMountPoint = "${config.home.homeDirectory}/.agenix/agenix.d"; diff --git a/archives/modules/home-manager/secrets/secrets.nix b/home/secrets/secrets.nix similarity index 100% rename from archives/modules/home-manager/secrets/secrets.nix rename to home/secrets/secrets.nix diff --git a/archives/modules/home-manager/secrets/taskd_ca.age b/home/secrets/taskd_ca.age similarity index 100% rename from archives/modules/home-manager/secrets/taskd_ca.age rename to home/secrets/taskd_ca.age diff --git a/archives/modules/home-manager/secrets/taskd_cert.age b/home/secrets/taskd_cert.age similarity index 100% rename from archives/modules/home-manager/secrets/taskd_cert.age rename to home/secrets/taskd_cert.age diff --git a/archives/modules/home-manager/secrets/taskd_credentials.age b/home/secrets/taskd_credentials.age similarity index 100% rename from archives/modules/home-manager/secrets/taskd_credentials.age rename to home/secrets/taskd_credentials.age diff --git a/archives/modules/home-manager/secrets/taskd_key.age b/home/secrets/taskd_key.age similarity index 100% rename from archives/modules/home-manager/secrets/taskd_key.age rename to home/secrets/taskd_key.age diff --git a/nixos/modules/home-manager/terminals/config.kdl b/home/terminals/config.kdl similarity index 100% rename from nixos/modules/home-manager/terminals/config.kdl rename to home/terminals/config.kdl diff --git a/nixos/modules/home-manager/terminals/kitty.nix b/home/terminals/kitty.nix similarity index 100% rename from nixos/modules/home-manager/terminals/kitty.nix rename to home/terminals/kitty.nix diff --git a/nixos/modules/home-manager/terminals/wezterm/default.nix b/home/terminals/wezterm/default.nix similarity index 100% rename from nixos/modules/home-manager/terminals/wezterm/default.nix rename to home/terminals/wezterm/default.nix diff --git a/archives/home-manager/wezterm/wezterm.lua b/home/terminals/wezterm/wezterm.lua similarity index 100% rename from archives/home-manager/wezterm/wezterm.lua rename to home/terminals/wezterm/wezterm.lua diff --git a/nixos/modules/home-manager/terminals/zellij.nix b/home/terminals/zellij.nix similarity index 100% rename from nixos/modules/home-manager/terminals/zellij.nix rename to home/terminals/zellij.nix diff --git a/archives/modules/home-manager/a2ln.nix b/home/tools/a2ln.nix similarity index 100% rename from archives/modules/home-manager/a2ln.nix rename to home/tools/a2ln.nix diff --git a/nixos/modules/home-manager/tools/fonts.nix b/home/tools/fonts.nix similarity index 100% rename from nixos/modules/home-manager/tools/fonts.nix rename to home/tools/fonts.nix diff --git a/nixos/modules/home-manager/tools/mpd.nix b/home/tools/mpd.nix similarity index 100% rename from nixos/modules/home-manager/tools/mpd.nix rename to home/tools/mpd.nix diff --git a/archives/home-manager/modules/tools/oci.nix b/home/tools/oci.nix similarity index 100% rename from archives/home-manager/modules/tools/oci.nix rename to home/tools/oci.nix diff --git a/nixos/modules/home-manager/tools/shell.nix b/home/tools/shell.nix similarity index 100% rename from nixos/modules/home-manager/tools/shell.nix rename to home/tools/shell.nix diff --git a/nixos/modules/home-manager/tools/starship.nix b/home/tools/starship.nix similarity index 100% rename from nixos/modules/home-manager/tools/starship.nix rename to home/tools/starship.nix diff --git a/nixos/modules/home-manager/tools/task.nix b/home/tools/task.nix similarity index 100% rename from nixos/modules/home-manager/tools/task.nix rename to home/tools/task.nix diff --git a/nixos/modules/home-manager/wayland-shell/ags/ags-config/config.js b/home/wayland-shell/ags/ags-config/config.js similarity index 100% rename from nixos/modules/home-manager/wayland-shell/ags/ags-config/config.js rename to home/wayland-shell/ags/ags-config/config.js diff --git a/nixos/modules/home-manager/wayland-shell/ags/default.nix b/home/wayland-shell/ags/default.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/ags/default.nix rename to home/wayland-shell/ags/default.nix diff --git a/nixos/modules/home-manager/wayland-shell/anyrun/default.nix b/home/wayland-shell/anyrun/default.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/anyrun/default.nix rename to home/wayland-shell/anyrun/default.nix diff --git a/archives/home-manager/anyrun/style.css b/home/wayland-shell/anyrun/style.css similarity index 100% rename from archives/home-manager/anyrun/style.css rename to home/wayland-shell/anyrun/style.css diff --git a/nixos/modules/home-manager/wayland-shell/dunst.nix b/home/wayland-shell/dunst.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/dunst.nix rename to home/wayland-shell/dunst.nix diff --git a/nixos/modules/home-manager/wayland-shell/hyprland/default.nix b/home/wayland-shell/hyprland/default.nix similarity index 97% rename from nixos/modules/home-manager/wayland-shell/hyprland/default.nix rename to home/wayland-shell/hyprland/default.nix index d915110..26b10ef 100644 --- a/nixos/modules/home-manager/wayland-shell/hyprland/default.nix +++ b/home/wayland-shell/hyprland/default.nix @@ -32,6 +32,8 @@ in { swaylock-effects grim slurp + # TODO: maybe move this? + pavucontrol ]; pointerCursor = { gtk.enable = true; diff --git a/nixos/modules/home-manager/wayland-shell/hyprland/hyprland.conf b/home/wayland-shell/hyprland/hyprland.conf similarity index 100% rename from nixos/modules/home-manager/wayland-shell/hyprland/hyprland.conf rename to home/wayland-shell/hyprland/hyprland.conf diff --git a/nixos/modules/home-manager/wayland-shell/rofi.nix b/home/wayland-shell/rofi.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/rofi.nix rename to home/wayland-shell/rofi.nix diff --git a/archives/home-manager/waybar/config.json b/home/wayland-shell/waybar/config.json similarity index 100% rename from archives/home-manager/waybar/config.json rename to home/wayland-shell/waybar/config.json diff --git a/nixos/modules/home-manager/wayland-shell/waybar/default.nix b/home/wayland-shell/waybar/default.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/waybar/default.nix rename to home/wayland-shell/waybar/default.nix diff --git a/archives/home-manager/waybar/style.css b/home/wayland-shell/waybar/style.css similarity index 100% rename from archives/home-manager/waybar/style.css rename to home/wayland-shell/waybar/style.css diff --git a/nixos/modules/home-manager/wayland-shell/wayper.nix b/home/wayland-shell/wayper.nix similarity index 100% rename from nixos/modules/home-manager/wayland-shell/wayper.nix rename to home/wayland-shell/wayper.nix diff --git a/nix/shell.nix b/nix/shell.nix index 1ab8070..fd5ccf9 100644 --- a/nix/shell.nix +++ b/nix/shell.nix @@ -52,7 +52,7 @@ # # cf. https://haskell.flake.page/devshell#composing-devshells # inputsFrom = [config.mission-control.devShell]; # }; - devenv.shells."default" = { + devenv.shells.default = { packages = with pkgs; [ neovim nil @@ -65,7 +65,7 @@ }; nix-build-asuna = { - description = "Builds toplevel NixOS image for NUC-1 host"; + description = "Builds toplevel NixOS image for host asuna"; exec = nix-build "asuna"; }; @@ -81,7 +81,7 @@ # ISOs flash-asuna-iso = { - description = "Flash installer-iso image for NUC-1"; + description = "Flash installer-iso image for asuna"; exec = flash-iso-image "asuna-iso-image"; }; diff --git a/nixos/asuna.nix b/nixos/asuna.nix deleted file mode 100644 index ce3f76e..0000000 --- a/nixos/asuna.nix +++ /dev/null @@ -1,370 +0,0 @@ -# Edit this configuration file to define what should be installed on -# your system. Help is available in the configuration.nix(5) man page -# and in the NixOS manual (accessible by running โ€˜nixos-helpโ€™). -{ - inputs, - outputs, - lib, - config, - pkgs, - ... -}: { - imports = [ - inputs.xremap-flake.nixosModules.default - outputs.nixosModules.protonvpn - outputs.nixosModules.wifi-ap - # Include the results of the hardware scan. - ./hw-conf/asuna-hc.nix - ]; - - # This is disabled to let lanzaboote manage it - # Use the systemd-boot EFI boot loader. - boot.loader.systemd-boot.enable = true; - boot.loader.systemd-boot.configurationLimit = 10; - boot.loader.efi.canTouchEfiVariables = true; - # boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_2; - - # use the latest zen kernel - boot.kernelPackages = pkgs.linuxKernel.packages.linux_zen; - - # use the experimental bootspec - # boot.bootspec.enable = true; - # boot.loader.systemd-boot.enable = lib.mkForce false; - # boot.lanzaboote = { - # enable = true; - # pkiBundle = "/etc/secureboot"; - # configurationLimit = 10; - # }; - - networking.hostName = "asuna"; # Define your hostname. - networking.networkmanager.enable = true; - networking.networkmanager.wifi.powersave = false; - - # Set your time zone. - time.timeZone = "Asia/Kuala_Lumpur"; - time.hardwareClockInLocalTime = true; - - nixpkgs = {config.allowUnfree = true;}; - nix = { - # i have no idea what these lines do - registry = lib.mapAttrs (_: value: {flake = value;}) inputs; - - nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry; - - settings = { - experimental-features = "nix-command flakes"; - - auto-optimise-store = true; - - substituters = ["https://hyprland.cachix.org"]; - trusted-public-keys = ["hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="]; - trusted-substituters = ["https://hyprland.cachix.org"]; - }; - }; - - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; - - hardware.opengl = { - enable = true; - driSupport = true; - extraPackages = with pkgs; [ - # Vulkan - #amdvlk # Outdated - - # VAAPI - vaapiVdpau - libvdpau-va-gl - ]; - }; - - # bluetooth - hardware.bluetooth = { - enable = true; - settings = { - General = { - Enable = "Source,Sink,Media,Socket"; - }; - }; - }; - services.blueman.enable = true; - - programs = { - dconf.enable = true; - fish.enable = true; - light.enable = true; - steam = { - enable = true; - remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play - dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server - }; - git.enable = true; - hyprland = { - enable = true; - package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; - }; - adb.enable = true; - command-not-found.enable = false; - }; - - services.greetd = { - enable = true; - settings = { - vt = 2; - default_session = { - command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --cmd Hyprland"; - user = "greeter"; - }; - }; - }; - - # Enable CUPS to print documents. - services.printing.enable = true; - - # Enable sound. - sound.enable = false; - hardware.pulseaudio.enable = false; - security.rtkit.enable = true; - services.pipewire = { - enable = true; - audio.enable = true; - wireplumber.enable = true; - pulse.enable = true; - alsa.enable = true; - jack.enable = true; - }; - services.flatpak.enable = true; - # to ease mount of usbs - services.udisks2.enable = true; - services.tailscale.enable = true; - - services.protonvpn = { - enable = true; - autostart = false; - interface = { - ip = "10.2.0.2/32"; - privateKeyFile = "/etc/protonkey"; - dns = { - enable = true; - ip = "10.2.0.1"; - }; - }; - endpoint = { - publicKey = "6vLkUgiS/K8p5dTMwUQo6tiyJ65DrM8E2mwO+QFz/zs="; - ip = "138.199.21.206"; - port = 51820; - }; - }; - - # Define a user account. Don't forget to set a password with โ€˜passwdโ€™. - users.users.luqman = { - isNormalUser = true; - extraGroups = ["wheel" "audio" "video" "networkmanager" "podman" "adbusers" "mediacenter"]; - shell = pkgs.fish; - hashedPassword = "$6$qCj8Szs3ReZHsRHN$nE0ASG2jCRcpryBGXcH9fhJyem1IzH2e1RQzTffkI0bCBOJ1FsOst1Dy8m53nQpzSsEhCR6JVIZ5tcHPmH0bL."; - packages = with pkgs; [ - tmux - neovim - byobu - ]; - }; - - users.groups.mediacenter.gid = 13000; - systemd.services.tailscale-funnel = { - unitConfig = { - Description = "Expose the jellyfin instance via tailscale"; - After = ["tailscaled.service"]; - }; - - serviceConfig = { - ExecStart = "${pkgs.tailscale}/bin/tailscale funnel 8096"; - Restart = "on-failure"; - RestartSec = 3; - }; - - wantedBy = ["multi-user.target"]; - }; - - services.xremap = { - withHypr = true; - config = { - modmap = [ - { - name = "Emacs pinky"; - remap = { - CapsLock = { - held = "CTRL_L"; - alone = "CapsLock"; - alone_timeout_millis = 200; - }; - }; - } - ]; - }; - userName = "luqman"; - watch = true; - }; - - console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz"; - - security.pam.loginLimits = [ - { - domain = "*"; - type = "soft"; - item = "nofile"; - value = "8192"; - } - ]; - security.pam.services.swaylock = {}; - security.sudo = { - extraRules = [ - { - users = ["luqman"]; - commands = [ - { - command = "ALL"; - options = ["NOPASSWD"]; - } - ]; - } - ]; - extraConfig = '' - Defaults lecture = never - ''; - }; - security.polkit.enable = true; - - services.tlp = { - enable = true; - settings = {}; - }; - - # List packages installed in system profile. To search, run: - # $ nix search wget - environment.systemPackages = with pkgs; [ - wayland - wayland.dev - wayland-protocols - wayland-utils - wayland-scanner - vim - wget - neovim - git - curl - fish - gcc - clang - python3 - python310Packages.pip - polkit-kde-agent - cloudflare-warp - aria2 - helvum - ntfsprogs - qemu - ( - pkgs.writeShellScriptBin "qemu-system-x86_64-uefi" '' - qemu-system-x86_64 \ - -bios ${pkgs.OVMF.fd}/FV/OVMF.fd \ - "$@" '' - ) - podman-compose - - steam-tui - steamcmd - - sbctl - ]; - - systemd = { - user.services.polkit-kde-authentication-agent-1 = { - description = "polkit-kde-authentication-agent-1"; - wantedBy = ["graphical-session.target"]; - wants = ["graphical-session.target"]; - after = ["graphical-session.target"]; - serviceConfig = { - Type = "simple"; - ExecStart = "${pkgs.polkit-kde-agent}/libexec/polkit-kde-authentication-agent-1"; - Restart = "on-failure"; - RestartSec = 1; - TimeoutStopSec = 10; - }; - }; - }; - - # Enable the OpenSSH daemon. - services.openssh.enable = true; - - # Open ports in the firewall. - networking.firewall.allowedTCPPorts = [22 8989 6881 8112 8096 8920]; - networking.firewall.allowedUDPPorts = [6881 1990 7359]; - # Or disable the firewall altogether. - networking.firewall.enable = true; - /* - services.cloudflare-warp = { - enable = true; - certificate = "/home/luqman/Cloudflare_CA.crt"; - user = "root"; - group = "root"; - }; - */ - solemnattic.modules.system.wifi-relay = { - enable = false; - network-interface = "wlp1s0"; - # dns = "8.8.8.8"; - }; - - virtualisation = { - waydroid.enable = false; - lxd.enable = false; - podman = { - enable = true; - defaultNetwork.settings.dns_enabled = true; - }; - }; - - # zram swap - zramSwap = { - enable = true; - swapDevices = 1; - memoryPercent = 25; - algorithm = "zstd"; - }; - - # # warning, here there be dragons - # # use impermanence - # environment.persistence."/persist" = { - # # hideMounts = true; - # directories = [ - # "/etc/NetworkManager/system-connections" - # "/etc/nixos" - # "/etc/secureboot" - # "/usr/share/waydroid-extra" - # ]; - # - # files = [ - # # "/etc/NIXOS" - # "/etc/machine-id" - # "/root/.local/share/nix/trusted-settings.json" - # /* - # "/var/lib/NetworkManger/secret_key" - # "/var/lib/NetworkManger/seen_bssids" - # "/var/lib/NetworkManger/timestamps" - # */ - # ]; - # }; - - systemd.tmpfiles.rules = [ - "L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" - "L+ /lib64 - - - - /lib" - ]; - - # This value determines the NixOS release from which the default - # settings for stateful data, like file locations and database versions - # on your system were taken. Itโ€˜s perfectly fine and recommended to leave - # this value at the release version of the first install of this system. - # Before changing this value read the documentation for this option - # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). - system.stateVersion = "22.11"; # Did you read the comment? -} diff --git a/nixos/default.nix b/nixos/default.nix index 071e6a0..4339d6d 100644 --- a/nixos/default.nix +++ b/nixos/default.nix @@ -1,99 +1,43 @@ { self, - inputs, - lib, - withSystem, + config, ... -}: let - inherit - (inputs) - disko - home-manager - neovim-nightly-overlay - ; +}: { + flake = { + # declare our modules here + nixosModules = { + # common modules that should be present on all systems + common.imports = [ + ./nix.nix + self.nixosModules.home-manager - mkNixosConfig = { - system ? "x86_64-linux", - nixpkgs ? inputs.nixpkgs, - nixpkgsConfig ? null, - nixpkgsOverlay ? [], - defaultUser ? "luqman", - hardwareModules ? [], - baseModules ? [ - home-manager.nixosModules.home-manager - disko.nixosModules.disko - ], - hostModules ? [], - homeManagerModules ? [], - # TODO: go crazy and add an extra users module - }: let - pkgs = import nixpkgs { - inherit system; - config = nixpkgsConfig; - overlay = nixpkgsOverlay; - }; - in - nixpkgs.lib.nixosSystem { - inherit system pkgs; - modules = - baseModules - ++ hardwareModules - ++ hostModules - ++ [ - { - home-manager = { - useUserPackages = true; - # extraSpecialArgs = {inherit inputs outputs;}; - extraSpecialArgs = {inherit pkgs inputs self;}; - users."${defaultUser}" = { - imports = homeManagerModules; - nixpkgs.overlays = nixpkgsOverlay; - programs.home-manager.enable = true; - systemd.user.startServices = "sd-switch"; - home.stateVersion = "22.11"; - }; - }; - } - ]; - specialArgs = {inherit self inputs lib;}; - }; + ./users.nix + ./groups.nix + ./dev.nix + ./shells.nix + ]; - hosts = lib.rakeLeaves ./hosts; - home-modules = lib.rakeLeaves ./modules/home-manager; -in { - imports = []; + # system specific configurations - flake.nixosConfigurations = { - asuna = withSystem "x86_64-linux" (_: - mkNixosConfig { - hardwareModules = []; - hostModules = [hosts.asuna]; - nixpkgsConfig = import ./hosts/asuna/nixpkgs-config.nix; - nixpkgsOverlay = [neovim-nightly-overlay.overlays.default]; - homeManagerModules = [ - home-modules.nix-config - home-modules.luqman-home - home-modules.secrets + # main laptop configuration + asuna = { + imports = [ + self.nixosModules.common + ./experimental/protonvpn.nix + ./steam.nix + ]; + }; - home-modules.browsers.firefox - home-modules.editors.astronvim - home-modules.games.general - home-modules.prod.school - home-modules.terminals.kitty - home-modules.terminals.wezterm - home-modules.terminals.zellij - home-modules.tools.fonts - home-modules.tools.mpd - home-modules.tools.shell - home-modules.tools.starship - home-modules.tools.task - home-modules.wayland-shell.dunst - home-modules.wayland-shell.hyprland - home-modules.wayland-shell.waybar - home-modules.wayland-shell.wayper - home-modules.wayland-shell.rofi - home-modules.wayland-shell.anyrun + # wsl setup + sinon = { + imports = [ + self.nixosModules.common + ./wsl.nix ]; - }); + home-manager.users.luqman = { + imports = [self.homeModules.luqman-sinon]; + }; + }; + }; }; } diff --git a/nixos/dev.nix b/nixos/dev.nix new file mode 100644 index 0000000..a615670 --- /dev/null +++ b/nixos/dev.nix @@ -0,0 +1,8 @@ +{pkgs, ...}: { + programs.direnv.enable = true; + + systemd.tmpfiles.rules = [ + "L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" + "L+ /lib64 - - - - /lib" + ]; +} diff --git a/archives/modules/nixos/protonvpn.nix b/nixos/experimental/protonvpn.nix similarity index 100% rename from archives/modules/nixos/protonvpn.nix rename to nixos/experimental/protonvpn.nix diff --git a/archives/modules/nixos/systemd-secure-boot/default.nix b/nixos/experimental/systemd-secure-boot/default.nix similarity index 100% rename from archives/modules/nixos/systemd-secure-boot/default.nix rename to nixos/experimental/systemd-secure-boot/default.nix diff --git a/archives/modules/nixos/systemd-secure-boot/systemd-boot-builder.py b/nixos/experimental/systemd-secure-boot/systemd-boot-builder.py similarity index 100% rename from archives/modules/nixos/systemd-secure-boot/systemd-boot-builder.py rename to nixos/experimental/systemd-secure-boot/systemd-boot-builder.py diff --git a/archives/modules/nixos/wifi-ap.nix b/nixos/experimental/wifi-ap.nix similarity index 100% rename from archives/modules/nixos/wifi-ap.nix rename to nixos/experimental/wifi-ap.nix diff --git a/nixos/groups.nix b/nixos/groups.nix new file mode 100644 index 0000000..24491c6 --- /dev/null +++ b/nixos/groups.nix @@ -0,0 +1,3 @@ +{ + users.groups.mediacenter.gid = 13000; +} diff --git a/nixos/hosts/asuna/default.nix b/nixos/hosts/asuna/default.nix deleted file mode 100644 index 49a5124..0000000 --- a/nixos/hosts/asuna/default.nix +++ /dev/null @@ -1,344 +0,0 @@ -# {...}: { -# imports = [./system.nix]; -# } -{ - inputs, - lib, - config, - pkgs, - ... -}: { - imports = [ - inputs.xremap-flake.nixosModules.default - # Include the results of the hardware scan. - # ./hw-conf/asuna-hc.nix - ./hardware.nix - ]; - - # This is disabled to let lanzaboote manage it - # Use the systemd-boot EFI boot loader. - boot.loader.systemd-boot.enable = true; - boot.loader.systemd-boot.configurationLimit = 10; - boot.loader.efi.canTouchEfiVariables = true; - # boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_2; - - # use the latest zen kernel - boot.kernelPackages = pkgs.linuxKernel.packages.linux_zen; - - # use the experimental bootspec - # boot.bootspec.enable = true; - # boot.loader.systemd-boot.enable = lib.mkForce false; - # boot.lanzaboote = { - # enable = true; - # pkiBundle = "/etc/secureboot"; - # configurationLimit = 10; - # }; - - networking.hostName = "asuna"; # Define your hostname. - networking.networkmanager.enable = true; - networking.networkmanager.wifi.powersave = false; - - # Set your time zone. - time.timeZone = "Asia/Kuala_Lumpur"; - time.hardwareClockInLocalTime = true; - - nix = { - # i have no idea what these lines do - registry = lib.mapAttrs (_: value: {flake = value;}) inputs; - - nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry; - - settings = { - experimental-features = "nix-command flakes"; - - auto-optimise-store = true; - - substituters = ["https://hyprland.cachix.org"]; - trusted-public-keys = ["hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="]; - trusted-substituters = ["https://hyprland.cachix.org"]; - }; - }; - - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; - - hardware.opengl = { - enable = true; - driSupport = true; - extraPackages = with pkgs; [ - # Vulkan - #amdvlk # Outdated - - # VAAPI - vaapiVdpau - libvdpau-va-gl - ]; - }; - - # bluetooth - hardware.bluetooth = { - enable = true; - settings = { - General = { - Enable = "Source,Sink,Media,Socket"; - }; - }; - }; - services.blueman.enable = true; - - programs = { - dconf.enable = true; - fish.enable = true; - light.enable = true; - steam = { - enable = true; - remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play - dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server - }; - git.enable = true; - hyprland = { - enable = true; - package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; - }; - adb.enable = true; - command-not-found.enable = false; - }; - - services.greetd = { - enable = true; - settings = { - vt = 2; - default_session = { - command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --cmd Hyprland"; - user = "greeter"; - }; - }; - }; - - # Enable CUPS to print documents. - services.printing.enable = true; - - # Enable sound. - sound.enable = false; - hardware.pulseaudio.enable = false; - security.rtkit.enable = true; - services.pipewire = { - enable = true; - audio.enable = true; - wireplumber.enable = true; - pulse.enable = true; - alsa.enable = true; - jack.enable = true; - }; - services.flatpak.enable = true; - # to ease mount of usbs - services.udisks2.enable = true; - services.tailscale.enable = true; - - # Define a user account. Don't forget to set a password with โ€˜passwdโ€™. - users.users.luqman = { - isNormalUser = true; - extraGroups = ["wheel" "audio" "video" "networkmanager" "podman" "adbusers" "mediacenter"]; - shell = pkgs.fish; - hashedPassword = "$6$qCj8Szs3ReZHsRHN$nE0ASG2jCRcpryBGXcH9fhJyem1IzH2e1RQzTffkI0bCBOJ1FsOst1Dy8m53nQpzSsEhCR6JVIZ5tcHPmH0bL."; - packages = with pkgs; [ - tmux - neovim - byobu - ]; - }; - - users.groups.mediacenter.gid = 13000; - systemd.services.tailscale-funnel = { - unitConfig = { - Description = "Expose the jellyfin instance via tailscale"; - After = ["tailscaled.service"]; - }; - - serviceConfig = { - ExecStart = "${pkgs.tailscale}/bin/tailscale funnel 8096"; - Restart = "on-failure"; - RestartSec = 3; - }; - - wantedBy = ["multi-user.target"]; - }; - - services.xremap = { - withHypr = true; - config = { - modmap = [ - { - name = "Emacs pinky"; - remap = { - CapsLock = { - held = "CTRL_L"; - alone = "CapsLock"; - alone_timeout_millis = 200; - }; - }; - } - ]; - }; - userName = "luqman"; - watch = true; - }; - - console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz"; - - security.pam.loginLimits = [ - { - domain = "*"; - type = "soft"; - item = "nofile"; - value = "8192"; - } - ]; - security.pam.services.swaylock = {}; - security.sudo = { - extraRules = [ - { - users = ["luqman"]; - commands = [ - { - command = "ALL"; - options = ["NOPASSWD"]; - } - ]; - } - ]; - extraConfig = '' - Defaults lecture = never - ''; - }; - security.polkit.enable = true; - - services.tlp = { - enable = true; - settings = {}; - }; - - # List packages installed in system profile. To search, run: - # $ nix search wget - environment.systemPackages = with pkgs; [ - wayland - wayland.dev - wayland-protocols - wayland-utils - wayland-scanner - vim - wget - neovim - git - curl - fish - gcc - clang - python3 - python310Packages.pip - polkit-kde-agent - cloudflare-warp - aria2 - helvum - ntfsprogs - qemu - ( - pkgs.writeShellScriptBin "qemu-system-x86_64-uefi" '' - qemu-system-x86_64 \ - -bios ${pkgs.OVMF.fd}/FV/OVMF.fd \ - "$@" '' - ) - podman-compose - - steam-tui - steamcmd - - sbctl - ]; - - systemd = { - user.services.polkit-kde-authentication-agent-1 = { - description = "polkit-kde-authentication-agent-1"; - wantedBy = ["graphical-session.target"]; - wants = ["graphical-session.target"]; - after = ["graphical-session.target"]; - serviceConfig = { - Type = "simple"; - ExecStart = "${pkgs.polkit-kde-agent}/libexec/polkit-kde-authentication-agent-1"; - Restart = "on-failure"; - RestartSec = 1; - TimeoutStopSec = 10; - }; - }; - }; - - # Enable the OpenSSH daemon. - services.openssh.enable = true; - - # Open ports in the firewall. - networking.firewall.allowedTCPPorts = [22 8989 6881 8112 8096 8920]; - networking.firewall.allowedUDPPorts = [6881 1990 7359]; - # Or disable the firewall altogether. - networking.firewall.enable = true; - /* - services.cloudflare-warp = { - enable = true; - certificate = "/home/luqman/Cloudflare_CA.crt"; - user = "root"; - group = "root"; - }; - */ - - virtualisation = { - waydroid.enable = false; - lxd.enable = false; - podman = { - enable = true; - defaultNetwork.settings.dns_enabled = true; - }; - }; - - # zram swap - zramSwap = { - enable = true; - swapDevices = 1; - memoryPercent = 25; - algorithm = "zstd"; - }; - - # # warning, here there be dragons - # # use impermanence - # environment.persistence."/persist" = { - # # hideMounts = true; - # directories = [ - # "/etc/NetworkManager/system-connections" - # "/etc/nixos" - # "/etc/secureboot" - # "/usr/share/waydroid-extra" - # ]; - # - # files = [ - # # "/etc/NIXOS" - # "/etc/machine-id" - # "/root/.local/share/nix/trusted-settings.json" - # /* - # "/var/lib/NetworkManger/secret_key" - # "/var/lib/NetworkManger/seen_bssids" - # "/var/lib/NetworkManger/timestamps" - # */ - # ]; - # }; - - systemd.tmpfiles.rules = [ - "L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" - "L+ /lib64 - - - - /lib" - ]; - - # This value determines the NixOS release from which the default - # settings for stateful data, like file locations and database versions - # on your system were taken. Itโ€˜s perfectly fine and recommended to leave - # this value at the release version of the first install of this system. - # Before changing this value read the documentation for this option - # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). - system.stateVersion = "22.11"; # Did you read the comment? -} diff --git a/nixos/hosts/asuna/disko.nix b/nixos/hosts/asuna/disko.nix deleted file mode 100644 index e711d97..0000000 --- a/nixos/hosts/asuna/disko.nix +++ /dev/null @@ -1,4 +0,0 @@ -{...}: { - # TODO: create a disko config - disko.devices = {}; -} diff --git a/nixos/hosts/asuna/hardware.nix b/nixos/hosts/asuna/hardware.nix deleted file mode 100644 index f8cddcb..0000000 --- a/nixos/hosts/asuna/hardware.nix +++ /dev/null @@ -1,90 +0,0 @@ -# Do not modify this file! It was generated by โ€˜nixos-generate-configโ€™ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ - config, - lib, - modulesPath, - ... -}: { - imports = [ - (modulesPath + "/installer/scan/not-detected.nix") - ]; - - boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "usb_storage" "usbhid" "sd_mod"]; - boot.initrd.kernelModules = []; - boot.kernelModules = ["kvm-amd"]; - boot.extraModulePackages = []; - - fileSystems."/" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=root" "compress=zstd" "noatime"]; - }; - - boot.initrd.luks.devices."enc".device = "/dev/disk/by-uuid/2f22d311-7714-4816-a444-39c1b87fbe20"; - - fileSystems."/home" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=home" "compress=zstd" "noatime"]; - }; - - fileSystems."/var/log" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=var/log" "compress=zstd" "noatime"]; - }; - - fileSystems."/var/lib" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=var/lib" "compress=zstd" "noatime"]; - }; - - fileSystems."/nix" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=nix" "compress=zstd" "noatime"]; - }; - - fileSystems."/boot" = { - device = "/dev/disk/by-uuid/E8FE-853C"; - fsType = "vfat"; - }; - - fileSystems."/mnt/windowsc" = { - device = "/dev/disk/by-uuid/ACFA1C91FA1C59C2"; - fsType = "ntfs3"; - options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; - }; - - fileSystems."/mnt/windowsd" = { - device = "/dev/disk/by-uuid/DA1AAC921AAC6CE7"; - fsType = "ntfs3"; - options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; - }; - - fileSystems."/mnt/storage2/jellyfin" = { - device = "/dev/disk/by-uuid/39ea80c4-e748-47eb-835c-64025de53e26"; - fsType = "btrfs"; - options = ["subvol=jellyfin" "compress=zstd" "rw" "user" "exec" "nofail"]; - }; - - fileSystems."/mnt/storage2/rustic-repo" = { - device = "/dev/disk/by-uuid/39ea80c4-e748-47eb-835c-64025de53e26"; - fsType = "btrfs"; - options = ["subvol=rustic-repo" "compress=zstd" "rw" "user" "exec" "nofail"]; - }; - swapDevices = []; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. - networking.useDHCP = lib.mkDefault true; - # networking.interfaces.wlp1s0.useDHCP = lib.mkDefault true; - - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; -} diff --git a/nixos/hosts/asuna/nixpkgs-config.nix b/nixos/hosts/asuna/nixpkgs-config.nix deleted file mode 100644 index 1dd1750..0000000 --- a/nixos/hosts/asuna/nixpkgs-config.nix +++ /dev/null @@ -1,3 +0,0 @@ -{ - allowUnfree = true; -} diff --git a/nixos/hw-conf/asuna-hc.nix b/nixos/hw-conf/asuna-hc.nix deleted file mode 100644 index 4c4f36e..0000000 --- a/nixos/hw-conf/asuna-hc.nix +++ /dev/null @@ -1,85 +0,0 @@ -# Do not modify this file! It was generated by โ€˜nixos-generate-configโ€™ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ - config, - lib, - pkgs, - modulesPath, - ... -}: { - imports = [ - (modulesPath + "/installer/scan/not-detected.nix") - ]; - - boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "usb_storage" "usbhid" "sd_mod"]; - boot.initrd.kernelModules = []; - boot.kernelModules = ["kvm-amd"]; - boot.extraModulePackages = []; - - fileSystems."/" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=root" "compress=zstd" "noatime"]; - }; - - boot.initrd.luks.devices."enc".device = "/dev/disk/by-uuid/2f22d311-7714-4816-a444-39c1b87fbe20"; - - fileSystems."/home" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=home" "compress=zstd" "noatime"]; - }; - - fileSystems."/var/log" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=var/log" "compress=zstd" "noatime"]; - }; - - fileSystems."/var/lib" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=var/lib" "compress=zstd" "noatime"]; - }; - - fileSystems."/nix" = { - device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; - fsType = "btrfs"; - options = ["subvol=nix" "compress=zstd" "noatime"]; - }; - - fileSystems."/boot" = { - device = "/dev/disk/by-uuid/E8FE-853C"; - fsType = "vfat"; - }; - - fileSystems."/mnt/windowsc" = { - device = "/dev/disk/by-uuid/ACFA1C91FA1C59C2"; - fsType = "ntfs3"; - options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; - }; - - fileSystems."/mnt/windowsd" = { - device = "/dev/disk/by-uuid/DA1AAC921AAC6CE7"; - fsType = "ntfs3"; - options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; - }; - - fileSystems."/mnt/storage2/jellyfin" = { - device = "/dev/disk/by-uuid/39ea80c4-e748-47eb-835c-64025de53e26"; - fsType = "btrfs"; - options = ["subvol=jellyfin" "compress=zstd" "rw" "user" "exec" "nofail"]; - }; - swapDevices = []; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. - networking.useDHCP = lib.mkDefault true; - # networking.interfaces.wlp1s0.useDHCP = lib.mkDefault true; - - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; -} diff --git a/nixos/hw-conf/kurumi-hc.nix b/nixos/hw-conf/kurumi-hc.nix deleted file mode 100644 index aab3c9c..0000000 --- a/nixos/hw-conf/kurumi-hc.nix +++ /dev/null @@ -1,39 +0,0 @@ -# Do not modify this file! It was generated by โ€˜nixos-generate-configโ€™ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ - config, - lib, - pkgs, - modulesPath, - ... -}: { - imports = []; - - boot.initrd.availableKernelModules = ["ata_piix" "ohci_pci" "ehci_pci" "ahci" "sd_mod" "sr_mod"]; - boot.initrd.kernelModules = []; - boot.kernelModules = []; - boot.extraModulePackages = []; - - fileSystems."/" = { - device = "/dev/disk/by-uuid/392a1cfb-1679-4668-a8d7-83e74af4fb51"; - fsType = "xfs"; - }; - - fileSystems."/boot" = { - device = "/dev/disk/by-uuid/D1D6-3780"; - fsType = "vfat"; - }; - - swapDevices = []; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. - networking.useDHCP = lib.mkDefault true; - # networking.interfaces.enp0s3.useDHCP = lib.mkDefault true; - - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - virtualisation.virtualbox.guest.enable = true; -} diff --git a/nixos/modules/home-manager/luqman-home.nix b/nixos/modules/home-manager/luqman-home.nix deleted file mode 100644 index 6861052..0000000 --- a/nixos/modules/home-manager/luqman-home.nix +++ /dev/null @@ -1,19 +0,0 @@ -{config, ...}: { - config = { - home = { - username = "luqman"; - homeDirectory = "/home/luqman"; - sessionVariables = { - COLORTERM = "truecolor"; - XDG_CONFIG_HOME = "${config.home.homeDirectory}/.config"; - MEOW = "cat"; - }; - }; - - xdg = { - enable = true; - userDirs.enable = true; - configHome = "${config.home.homeDirectory}/.config"; - }; - }; -} diff --git a/nixos/modules/home-manager/nix-config.nix b/nixos/modules/home-manager/nix-config.nix deleted file mode 100644 index 3cb62de..0000000 --- a/nixos/modules/home-manager/nix-config.nix +++ /dev/null @@ -1,12 +0,0 @@ -{...}: { - config = { - nixpkgs = { - config = { - allowUnfree = true; - # Workaround for https://github.com/nix-community/home-manager/issues/2942 - allowUnfreePredicate = _: true; - permittedInsecurePackages = ["electron-11.5.0" "electron-25.9.0"]; - }; - }; - }; -} diff --git a/nixos/modules/home-manager/secrets/secrets.nix b/nixos/modules/home-manager/secrets/secrets.nix deleted file mode 100644 index f14810b..0000000 --- a/nixos/modules/home-manager/secrets/secrets.nix +++ /dev/null @@ -1,8 +0,0 @@ -let - general_pub = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDW+oXpKYSILzxc4O5Nrlf1oObQQc4XrawHWQmd5yvspQI6G5138KhX4woq65P1dGRguLvj3wWwJt5zKf533995radcusma9G1YDMWgkq+bKz+eNvY4n3zkA3EeKAlLsdwf/bA1ydLqK/LOTmBjTQqoxJsiQ7sqWCQFKZxRPlaRKsEnL8PmhkQNll8sJJ0GY559kODKArAjqYxNVPnOjijfl80WjIplrxKOdlaK79zJxv955lQTRNotI/wITnbOSpi2IMrbhCXQ5IViVj1fr5CwxPO1hrz5wRaycUhErtxzQS+Cvfkp5ooaOJSNRtmxoGC0hPxO8Vi+SrL28mH8ziPn"; - agenix_pub = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPS7So2hAtYNZQNkqTzq0+b2wDgsx++VpKLMttkA4F00 luqman@asuna"; -in { - "taskd_credentials.age".publicKeys = [general_pub agenix_pub]; - "taskd_ca.age".publicKeys = [general_pub agenix_pub]; - "taskd_key.age".publicKeys = [general_pub agenix_pub]; -} diff --git a/nixos/modules/home-manager/secrets/taskd_ca.age b/nixos/modules/home-manager/secrets/taskd_ca.age deleted file mode 100644 index bf8d34e3b68bc174408b967d42ab3d2a1dfa5978..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2517 zcmV;`2`ctsXJsvAZewzJaCB*JZZ2G70Oi^<|F*ZzO zcuGiWXfQ}?csF@$aZfogT4h9O3S)OdT2vhM`KiWLRUFNH(^yXVG1yFGi+yiNJU6ZOj&6#IdgY1 zHgHH$NKkoXc~)&gS5|jWV>f4NP*_N7cu`4tQc`O-L1|+%b!|CPWOPMFHEjx6Nq9Lp zO?P=wFiBBnD@SrxNM>X*O=oCkWJyX|OiOHMQE_oNaW*h7c}GJ~P;FsHSV=WYabi#~ zS}!?zN@ht4QFM4|LPkw#Vo`21M?rTpY%gV3FHs6DJ|J^*Xf0)AGBq_ZIUs2{b~tZ$ zAZA2iNlkP}L3(jiG&5^qD`PStlOGi^HY*8{sHb!${Q&ul?3N0-yAZBG*G;TCnNGowO zS!HHyRxeU>byziFS#xf4c2`JOM@4r_Oe;c9MMzj<3WXLh|JWe95lm27uw(W!>!Jbo zWAkf_kO-RLi@l50-5jEj|Co3TUqqN(x$rz-Ys`RqpBiTO-_M}z$_U(i7PX< z)v6w|I~F-67s8s|1gGqj6xC2KD{k-7Ya0MRxMZ-O}qC48n+mIeGzLg_=1YelpWeHbgSy-89Z0 zqAPf1&wqdsO|04K8Vft=eZgvlt_{K>T?i`o?c)Tqr<6~&vi=7`3Zq+eFRo4H?3deM zxC9iC_AHvfjLcj(AbFN=>OL4qUXQ<#>!K{R;pp;-3I=uqk+eoRrc1++t2bs@5;c4+ zyuBd1yvuMKsq@79Z<``PT$B+&*>vs96Oo#%G>-kc%me&+0!&SM00$4ZRch}|JL0nH zVDcok$&EhmLVmI)hdge*DHT9F)tvds|7vBR`h zbWDDA#;zN|b~_9&^t03i7*huhkKkJUn9!JG!Y%?scwCPRDN;8#+)@W<@#wD2P+NwN zQO*|phT2*D7lJl+G|dhux9pgc{h-@58uS>?0dtKBI~+mBXeaLIvTaB@mPhs5LouXRJByS9DjJ3XeVpdM>wQd1MWGE@ZlDGQ zwIPlRQ>qpDHD*(s-Eg?l6z&S8uZJrwDM{?9tXMI&WRFb=gY7t_QBo9&UVBzK5{#C)=G2^8~*?tqT-qKwLTcv zGs?}9>G=UNhFr1R%vQ9zmtO)5d%(NuUm2DsH?9RhF_A|zlBS09m>a1Mg|$~07A1bV+n;$okER<hJlki%&k5+LdEBk<6PcBt zLvjs4GRBVNr~e69s}y|?a6aY6O94qJ%ZVVYFPQnU#lUeAEGXAj_8Y-4fAw4z3C*)l z3jte;i;yiQFig|Cs#DRO5#)35r=57n(&f^EEkU4Msxbug=GOweb&vrQJ%wz_{^}Ns zuDLkw=s2MA1Z&#LSDIPz1A(n(^WU|k!a^#c79;whU7^TOCRebMAQrF1=wAecYw&Rr zr%B?@Ezu|jD+-&2_%N!Yov>nlZ;DnrAX)ZnBQ&zZX^ntz9kj`;pPKlIs3p&Fx8Kn&-FjSxN#Y_2j z8yZ;n_Ik1)%o$$;H2;(hZmUX27#3ZNFz&_5lJ`pwnBNp_QtubW%erZcjsQY+_?ZSwU<|PDM*XL`iaCHAin+QcPl2ZdpQeD^D>~S2k06 zGk8@tY)V54W-}{tVlq{2aCt8|FH=fWaxX$iH8EpDX>BiVP(w&FQE)I!LrqY5X?RpI zGg?q$WlL{KL|AfmSZ`!_LT_v<3T1avXlyHSQe;LoctTTDdSh&MZfIs&XH;-vRzpNZ zQfM!2W-nx9YI0LjWHnD?V{$KddN(t0b8KrcX;(F8P6{Hd#ShXF+Fi zQFK97GI~v7T2fI{OEzUOXlqMOS7|mfRz*%nNJedER$(tvReEc6O=U+#WHSnLaZFET zQ)PNKFjHbuSWQ7OQ%h)gFIYrOMKeTgN={2hc2ZJvXhAnhcX3a3bXZYXQDLTP1FSu=Ebb!TNwb9Goscv@#mX>3SBL1siNVs%G%3T|>RNo7n; zX<<<-bTwvTWomSGF?2aaXJ>g)bTM~9Wh-H5Raka*cq=P33N0-yAZ%!MX>w3gbV+7# zYDH>OQ$$!*YH%?$HBe7xbWeI?Mpa>NOmlNbL26Ji3iu9>s(U+bo3)`3%;xV;8vGmu zcY7n35h$d=%d*lOl&^uVfxVs{`9N*>!Z6o5#TSpqyQko}KOdQ1YwEd2SI_4+{ViPUi<53>Uv=y1VyzhAH}*(}VyG0^Ve zsQqEgz`9Z2Ih=w}TrJn>=0;Mh^l=jx|Xn(-pC%{qewpVrGOC@O)8PQ#A8C}B!G zRuDZr?Q$egcxW^Gtaj-B;FPr>0PVmgmw`>h1&=w2X#yH;a)I%B>^gfM6!fwXD4VmR zCjxs{y>V1-|CZb(8Yjnq#0~Q`-&DJ%Lig-Ut5wv)&Qf+!h)Bf#=V?ot$7V;sxbfqK z04x)(bl?<47O|*aN2vO@_pEU-2~PxTNXgglToWT^SBsIe%j+ zD*P4iuU82-kP%nQgyI10XOnfI8Yi*xAs6ep-K!A_rMvbLsp%&q$p}H-vL$7!wGT!x zA8R)zDbgSNpGrQ#QQj*|ZXO&OlE}a)pNU1=kLRCN8|{<#U^H~o*Qta#e=FmqK=x?& zh)rE%1O#M}P9x962_Snk?gt6lP}!j`7+DgC0|oC+pRX3iS&;jbbf-JUt>ldbh>0e! zGna)!nGH;-Da-^LTBen#Iy1Yn(Q;iDYdz-OF3uJ6xlRka0R;4s7lr2*<>UE1w(>PJiGZ#B-kkz<2&BX- z!hXpY9d}`X4w$$1w6W{&*C4)IWugK-Dl(RK3Ob{%8@6%SynmE@^rZdX4grPvnT_DJ zk%FjDmz%wp$hop2P{(T8R}6nAu;ofo7uP1 zK4Ix8^3dD47sz&x0bMsQzvYdC@a%`gSn-Npff2(fBg>D@7===_L0Gnk?i#?B^QMt4 zE|E$=MR+u^A};qbH*u2`P9E4S+5SUB6zmLcJRx+=SCila7!1w4?Eb>kO86D>!rYh! z<)2;A>yv=gn#jXe<(ZYevPVrLgiu4_x-~HLwzS#pN%D0VEgmX4YYz9K-ra7wvA2=Y9rRxb4LTqxVa; zKEOerEl4z0CqKQo%TT59gCyK-_-;~fa>qunAm*EEt8#t|PA;=%W`myjYYS+N{r}8o z%~f!50=2xwp0`Dm_JTH(fa%$1RtHKkPrtKzPr&FEjr)bO_}-%oE_^B%adzU-lg)VG zz=+fgFuS)94eu`)z!fpeSdaSPNkAv4YF%UTdC}e$7xLN#D)4GNx|0ri^XyTX|29Lf zP&-UIS8Z$p0(ASPuETSTbceQzVEjZd-@i$Eeca%eh29b=|EClfy}I^UPac^!pBa+e zGm#P1`2Z>8Jk4j`R4U88T3BU*Ypgmyy}yI#oBR-jm?i17^?%JHc3)!*Wz6<8-ANg<%5-$AN&oE*4+m**OTK1BNm{*g{aX51vgtPS z$d6ZZ{XWAy-2(>XG#>EsF19M)M4;8An1)*VLDVP{!Sv8vYQYkZEzi;>p}4TdWI&?* z1Pl$EOMY-L4hp1b(gnyjX?N=9aA{=|DxyuM-+~?4g#GFuWtt626%W{Xj9&$*F zz6=)xtPd}xvy1OBrDzqZ1rk0^YvDiaQKBHKTFk+dR(9X3fb4+ILM(8;Nk2b4w@M&+ zxB6N6W*JczTl8J>!QJ}<4NW_U?Z-^T5 zuFx^!^U3u#WPyy&)KNLs0{NB|ee&cJQ#;9zf>yR@Dr2%Gez%+*o?1?&`jqPiOs`0dIS-6%J?=HRoJS86X6ZgLalN z!M#%ouFx%S_^)-`x@U--y7PwXhd6PSKosiK2)Y2>PyQMck_4l$`kma~vN`tv4gj)I cZdfC3nxX0PG(OJ+T31w%OCagQzVI#jhv;pw0RR91 diff --git a/nixos/modules/home-manager/secrets/taskd_credentials.age b/nixos/modules/home-manager/secrets/taskd_credentials.age deleted file mode 100644 index 1a9f13b5fc8bf050ce2ae510fae51498e93f27f8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 679 zcmXxgJB!l*003Y)MKIzZqJzj?y;CT}+B9vNW>J$iNz){4(=_Qd+>$1_q)nS=lQ!|e z;c_SlC#c*a3d&6m&N}I&C~m%{Lj^ZCIS@ge{C>ixnnuoWv>@@OL)SU)24+4k0J#g9 zFtl<(sAhUBm(T(*(ENU!6a{&z(qJRiRYamZ87$Ejn)s{%`*MWJ^Nz=tTvwl|NKZ@# zHJm5I5frnXE(}QZr0FZG{v3@;EzAckBCk{!d<4TTGV$tmoqWQ9JGt9^|Tc&KnE=~GQ+J=UcQ4!;{sT#_V zXX|ZIX266`+*u zK#563B4sEjf#9TVU>wrL841_x41iT_vlLZ&lX=nQ`zT=u&Akjv#VwUL`RVk~K1Gnf{uko72G?uFJ0MOz6$;dK3y&z YJk;J>d$J~N?>u)do!NdAKo9Qz1O3zODgXcg diff --git a/nixos/modules/home-manager/secrets/taskd_key.age b/nixos/modules/home-manager/secrets/taskd_key.age deleted file mode 100644 index 8f7a4b9de40210e2cc1107b28eb5f279542c99f0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 11310 zcmV+}EYZ_pXJsvAZewzJaCB*JZZ2}Wk-2MQf5kTczQNAMMZdVNN!j` zFl;YyVr^FnRai7NR6;^>S#4%+S7lgvH7ibXF+mC~J|J^*Xf0)AGBq_ZIUs2{b~tZ$ zAVOwjG+|~(VrfoeGd6N+IdfM+Y)>#xFL6eCFj;hIR8(MrLthcS2cqZf7@4cQ#`}OHg=XS21XJXm4{g3g}sRRO3bHppi1l^&kX(hSrYT zksuHFP`BcWw^+h|7(-cQ#^8gU%G@BaI+!Tp8gLMPxY5{GD=)e{Cc*(4y+01`G&0-) ziUHq+wYNrjtc?%eBiy5J6+xv@?FART^AF}#DdYj&fsY&cz0LZ_hqg-dJW0MGX*EB< z=!@$l%AN=rTZ&pe`6VQpcLP_Cj9Nv8xcyW>ScfUy`cX8CEvU_5Ti|Vc)0DBuyHUux zZiM=#wZaZ_dm#nmvqFSQ`6j>P|GQ3!?(%g_sUc=az{5Mm1pY;BFT6R#`%Bo->U@cU z;aqHoz7F?RYL}-ZZmxV!OHUwhT9I>WDA*xwH8;9k-EtrkUEqFK?(eg?~=)cg`OjY33J_XzH7jjUoro0^E)<%J%f z2w!hD*oJWzrTF?Y@9bp)gy$EPJUq1f{robav^zO61w(S`s4|sMbfG{ELuD`J)J_-s z?CYfBq*=*-f#erZdy@s#@RxRe_~xG4-Le>vzx1ZtBkEI2zA`lI3x0qM91irR2xo6u z`V+NWqVWRgjOIN!S&jXJ-Fd0z(~T2#`w{$N+NZ)0b-N@eZnG!_1bmRXkBdu@&bxs(|L!kp|PD!7rqH}1@_TR$dX#QNEk}OM=L!Ocn1_ zRgkPHncTq~am5;~-!IhvC_)Cj=rZUP7}maPvN155Ht)bru+m+h)bw;vxhQxKq!Mi- z>7`R4%n9b4>nB#yCsBWjX;^J1vddK08{)WQP~% zN1AwAxUC-$>{B)ycYu1561I@H%wuRInY$~u&pNJtVZq6$L$+pp>asd$n99QwWjoWU z9P??63eUmk&O(G?L0on?@gB89$WFY_Z%WF$u(iNHBr-cjODs4hxNyJ4tV#rVTO@zA z*wnXCVqVKaFwxsM1GJ?WB#A76Da>4&20BtbyB>xuSyIn3EDgT!;&B)>QbdJZoz&_i z1?8_=)&=me_#ni`-h$38?)^45L~o6ZrP(#^{}z2JqajpOUj`@5uaO{#EHhQV1t-qHCSI948!w(!q1gTh`*kE*hrXWO3 zS0xcb%bfyJ+fu}No~K?389MRj08Lra&|Tp(&Rr^-E&ir3k3FyOGU}7AJo&BD>*Psf zQ<-mTd3V zlqDI*R1{71oC14@q@G|cJ6M?S^z!T6n06&n9*(1-EJg4h*Q!?vZlO0}3T_6G-SMtA zmc8%jbU7?p*+nyd$U+jdiuU3jUbzlpV`1&ofB18ylL78zVm|xqp@)E-)c{~(%n(O% zpi6N&5GMmiB2*oo)G_A)W^6YC-A8Y_Jx0ce_cvI5kWQ zumD6P1E^E{OtLvRwdjE<_TYFvg7>;TW!{a6SipHn68n8UD81P=8!k9H@4GaT-(y*1 z$>c*Dp&#VRnVO11F$X_?j-=bd38D+d)`HMx!o`*qY8RBh;2FV=G)PYh^!m(Nrn?db zkRcb!C39aK;h+$cv}B@1P9EJa8)qbWcFMG8T#%*DB$`^Mv+$dLK=^@tG%I{cWNf~G z_dw-KjT8?W0ePovpGm|b@Nu&Rc;dGnATRMn*TDBXp*ie*XM3r+fwL4%Qlcu1o-i~N zR-MVKzW!+yT(a3@;4PbK0e3hH09BqIEEK&$61<&d`gURs*XIh&}A++pMy7(VL(6g8c1JO)_@A7iW53|(kQOpRu zd$J$`_Uv05Whe;u?C;Y3W!xyK$lSBJm7nV-1XNOA zhY<2%mXX2eZyuh3X{*i(+&uH|>&YU%!ez@Z z_=Tv+9g)|lv&DddixEl|cu2SQ$e1=7SU`1SK{g2>8-F6EK-B!4aQM|$14Z=qKT>oD zO^~LdwTi~yRDOcH9I=ouc8i3} z6Q^(vrGCAf9U_R5Nlgs7PXJ@W4hCqyn_nVbx)tZpARaN# zMzNobZ?4_+8Mpi3ZUb~TlC!ac^6CMur6>B+Ah=F|cz3ncr|L0h`JkliQ5sa#e6}|cIe!U2R@o+AuW2w%@0D}EJ?9AYGGJ&r;xqX(z z3@5%vJEGkg!{(FXJ^AVJ-xp@ePq@#Z8Ljys%Mma%W(|l*;Y?@)y6>!C zDqO?p8u+e*Q*(+|sIL-K z8*U_ab(HRx?zC;tPWtPt0$mT+c#y6>BEMz?gl@g7V7W3L#(241Dy(&T5IhHCDiEgJw92tkWZ`p;IT#Q^X5mmzy3MeqQ^8fI+ z($qzj0`7bas=69|T|AbPBA_quklnlTMxo~TH9GHheGD2$RK;hjw4yAp;*n_iv(s%_ zE3j>Cyl?&`r=%X7{@#$T+4TpUQtCpakiOTBhjpz3t<}JrXc?MIKqm%~=QV&tqj&X5 zIBJ-UMqGD$>^*9a^>|~Hbi!OFr7)FRG zH3VUb9va#>4EfE^P3?a6wo-zXvIs>gSkLqQXW4m-S_gDa2uu3Vz-Kv4{>asF74vTg zbn|E0h4heRD-oG3F;+1*ry(f&fOKk%A2KxqIq6U7uNwiXhv&Jd-pQ8l_=mhdMSI9s zM8!_%)DbD`fP!D~k1^TLRp8h#L3}w73lEWZHBDgr!VD<|5Vj7K{*BoKVa1 zNk_sHU<@CO(<@@~=))t0`SL#X$tnc0lz*>JGKs%CkxBo9vC^XtvmPAX_40ec=I>7% zYn^vU+=!+LP&&Xi5$!bS_&)1-PHBM6ME$^C*aK(|#`pHI$7P4AXG|wrPX<-=| z(p^>8YW5-nt1S}oJ5=6gG-ymGjL}XyGEWn;m5+Wb z1M(H18)b{o9BJHhPjZZgfPyA~jCKjT^?;27bEXsYvtK8nK{pC)O0p2@hIG-L*kX1+ zjJ0up_isB?*Z9B4^*6l1xtyXb->(4=pJr65Bmq2VZz< z+u46|(tW>V5A&IzHXvZio~;e2cTjsrdJH?&CaKp+`ir zG&81kvt{by_6LP_4Ubpj5n~X?!H!`}PRj)sq#(F&%n5Qoy>@axMn@u`BIK>QD3M@eNM2A&k}8^w#RoQ=It;V zd4l8sjFfPIB_=3YF)%1Lx-L&cC2r}4dYw881WjA?2)nFtcn8NycLUxUM$GFv9*m2W*B|MiTfJqVWv&>}jUD2aFr%qA z?&)IcTA;KKa7O*xw|nwy4H*`BPv>B0L+5^2ZI2HCyv?C19{TEB6{%E+KEwxgVRZOt zgT#8lkXS~Xz^v%@!{7D!rWdzE?V+oDr*yI)ym9BAU4=Luo@*{oE97OFC?1N;R-O zff1;NvD`l0(j5h;gZ3ja1U4*>P%*Hm1S%bAEn9U}kx#F!`PM@PKqc_=DJPmrVL+$+ z^LT~}s_H7@~;l%RP zZ|@j0HSU&ym(pPepiM;lskJI7%3ZoyLB-yl4vqPx$md?(Nw)_r*+Cl{a-74# z+PaBz$VkC&Pm;KRlE)0Tq}S@ZmJ1ZeG}~P(RyBM1?vL*?BLIVdwn(H;-b8vg+>ZoH(!E;dyDG$EqGN{8 z+!4gkGO;~Pf}&YA`}k{YHMoUCG-R8Ibbj{Es1H6-0n~-!X zfqvi!*^X(UR)`PY#A97Oka)~X(@OjyYEWEPn!4rhwM|o+3a-}!*tNk2| zU^WyHfVz?_)z4B0FGIgR-WIji*{G;xXkY`ZeL?jRJ|>ti-tcsoupT4Q7x}!HapHL8ww4KD8E2z0I}Y^itJJ*>jRl<9-si#ufoWU{p`s{L%Y4^WTrr|S#S|0 zAEDOT7M_R@(ISO7x1Eds^pk_sEq10UL~IO96kqxn83~smrR>^) zeNkT%9JIO64bpJp&-)>?=#tE2x6SM93K^3cvd$uVzW1{+Y0g%hGzPd$)_sA3ERRcA+rTa~-=9aV>k zaDQc@|9Hc|$%OY8Wq>vwlEwi~16|V9O};fVb-O)8$E_gmkB;Q(T=L3y3;cW>=}e{! zyV6n>O3>XVx~7GyEru3dS11*TJU6`d9dmF-SAn1|H!$O=-*# z?KYm4z|>%iG_jrm;E|EAZ-l~SVj6}M=u=5mIZ=$xDL3r1ueaEUfbsom_P$$^O)HSw z)`}FeYFLO}fD(z=!&Jgbr0~4-(VhhV4@C)5R)=wS8lN{XY z*)dgdzvV^}3jDpLl*`r}0HkFIh@8XW{v*&YVvGvEp%LnMTxa(4_ZRSdB;`gMtW_dI zy&#ufZe2_(nl?G}J0y;h-2H2$hwG!D8ME%Z407@xwJk$@u>q`i#Uh60O*UuqR|hF+n)h0k_OwFsC3NiuR@d~{Q#zIV zip0VLg;a#!Qhx13T*~4uE_W)}UP+Yu0#&ZIX(Oa~yxkTB9jK^^Q24S!o`*ZQy2~Rq zNLe_Ty^aOgjy6{lb#Asx8ehSU+ty%hXI_df1(0lg`u{e+3`0M-xrZzYfn=rO)ewKd zhthP$UM7A@4&Aq=7<ZM>lcl<6 z_?6vtqm=1@I?mIFk+GTL+Bbg?R@JoYz!&Xt;f!rqj?3aYu!J$gf$=-BFT2>dm(C|FESX^Uw8EVghUqBb~p<7@EV zYb1Z5Xh3&0IjPaY#D23B`>8DQF1YENbSM(PWPV%&q@wDuKNeL`##~@IG2_A~x;=}+ zzB#ru=HbQIXA{K7C^(B5(>&)88@>%1EX>+m2Y31aHbGYCYd@J8Iioky4ojE^LFeEi z=I3KyXNiPzZ0O+x-LtNg49I~t1H`rjrUP3Z;l5P;Wap10j+HesDw|jYB0kG7t!XR} zp#=dfDWitPmbbK)__iukOm~Gs$+bgK=QzXQhMQ^&eTKQMQQ<8ob!*~ZTL{n{k=$w(urd>=i-bt&%dIIrg7e0Xy*XTtWW{5eE1XTQT12>8v*HanwVn1F7&e|vm6hbfrxiKNL;wkRX0czjf{(@=f6R1b6?#!qf zo>oOB^&9rSuU73Id#h+JrC0iHizxzyI;C4mEcn zyU6kCWjj87wj~3C71oSM33e#i$#PPQ1NQCbM@DXHMp>4p7+95uh^O{F$(&ygg*G`- z)wm91_fW(0IgU%r`S=rUf1TysUf;_nAfhHT`^69TkIh!!$3v{K+;S1Btvb|}gZc@# z|4LH8LW#;ab$M52{PLHegxv>CYMpY2Zy$LoO4BjxKDXa-z9H;7Y3qhrFtgU&V;Se$ z_M4@DPAF>WAT91oKzU{}RyY`9OJi*@O)8tsEztj>-kH6-Diq5s1F;lp zz%u8@k^h>ohMlVC+PWmHr9Pb)YpS++3YcO<=b(M$cw)nC7vg^WjNp6E`jWn`5)R-Q zB^4+eG-jNmcQ2FO&%R=4y}5xF?h1Lz`a8)x-;E43lM#{hoFjU}@mIx#>@qgdTCOy0 z<^A`hueT4IX8yv-)&U{7@KSh03MV(wI5%JfHojrTjwN-E0`_>=FB5r+PnoS)7in-I zFWU-A8`_3eFQ-ylx|HjtymnfYIojN-5dPKVeCU zC3I&Fo?(0etUF|J^2DQmI^VUR?t@R!li`VljU9|ecfAFMeo z&&I6Y#no@+D>N^RU3L7lj*$h1YSJXj$3_o@+Q_|mZzNti2{7KO?b`J#&+`mq`Gh4u zSfMJ_$2%&vd8fh$3ihEm?K5H@#bMFBwy37Ka0P*2Sq$AU^%>T{=7D{g6+udjRg_%8 zynjf2i&6UhFHzx^0fqK^yt!4%*QkTkLl*5l^-G0p-wonqjX%p^MBoT5Om+U_Vr2*V zaD)906Sz>Mc(@gs*VZEE27jlm>1v!}==dmuoG6Qtx>W2zPcdmpRdE1cRm?=&c4`U_ z5lL-q2IhTTA1|_0^!ZKznR_EprOqDQOBh1~p?qio3{{G0eA5wq&ou>TV* zT2vnNFzS=LL<*PtQl#ikH#stK41JKAp<tpzDOc8(PIU&e0+_dMdY#@9&RnjXC0!5I%8;j4 ztp#JuSB^%jC>5|j*dfw+TNG~C4hIPd@3S}4LuWv;nb!nbkNyE!+onyQ`gchn*R%O;4e!&S3FV`xx-Gx`=3{9;~swkQ#2 z-GvZ$jmnr_o zaD}Fh3N5geJ?awV)ssTgvjMd14W>X;D?3Tv82qD)tMPMTGM6ujjPBc#m0EH z|7Z-OU`Sp`uu*T`CO;lYzIS($_Qd}t5#3vf&PLzJBcF31bq+f)VBQ?gGw1usa1_mZ?@B;xJ2y6 z5&H&HtOUQuE3;ets|rWfuB?J|h++#lD5vb6bp@A8Uf1b+5Q^`*`<2+4T;j}%_Dciz zfkQH76+z5C;Z|U{+DS%x^+-a>6W#S2^}D)V*T>t8N8}P zFx>IwX27yl2BsWRRdam+eqPbKX7@DF2vyc#yRpn0n}d0Kj0a>*Oy=KMlZ{o^_?XZ$ z%xG=%97zPSNGP#@jP7EwpU#EQn(oD2yVo6Z2OoSdvUU#^S~Z8);ctRjK$|Ay(%7+{ zooxa~-fGha?ikT-%V;|RFK?kK7|R3>j_YBH$S`)^vD$)EOfbg(I4rT~ia+2Au6w)k z+=fQXoiBT5C!BNDiu+ikU6Q^0V8{SNu-`QNEVl1z?*2+HBHC)b6^78S#DJjf5obmr z7KQy_^_bhTHgnI;Vdrtr%}GD|^-Obk~dUj(4un^BrS%y-HKr5X(a4Kamk=(LBH+I_|3a!dA$mhQQjVS))F zkOa8bAU^pN7Dq2{@pY*gG04g0gGm)t73wLdY7wC_ZKc5@-o6=+FfV&3@2ZWOK?F5@ k_N2Ks_t}|3Z7H2q4zB!FCHWU3KHIH_!rTj+6a2o{*%rN=M*si- diff --git a/nixos/modules/home-manager/terminals/wezterm/wezterm.lua b/nixos/modules/home-manager/terminals/wezterm/wezterm.lua deleted file mode 100644 index 94eb98e..0000000 --- a/nixos/modules/home-manager/terminals/wezterm/wezterm.lua +++ /dev/null @@ -1,22 +0,0 @@ --- wezterm config file - --- Pull in the wezterm API -local wezterm = require("wezterm") - --- This table will hold the configuration. -local config = {} - --- In newer versions of wezterm, use the config_builder which will --- help provide clearer error messages -if wezterm.config_builder then - config = wezterm.config_builder() -end - --- Config here - -config.color_scheme = "Catppuccin Macchiato" -config.font = wezterm.font("Iosevka SolemnAttic", { weight = "Medium" }) -config.font_size = 16.0 - --- and finally, return the configuration to wezterm -return config diff --git a/nixos/modules/home-manager/tools/oci.nix b/nixos/modules/home-manager/tools/oci.nix deleted file mode 100644 index 7267098..0000000 --- a/nixos/modules/home-manager/tools/oci.nix +++ /dev/null @@ -1,48 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: -with lib; let - cfg = config.modules.tools.oci-script; - script_name = "oci-script"; -in { - imports = []; - - options.modules.tools.oci-script.enable = mkEnableOption "bruh"; - - config = let - phpBin = "${pkgs.php82}/bin/php"; - script = script_name: - pkgs.writeShellScript "${script_name}.sh" '' - set -eou pipefail - PATH=/run/current-system/sw/bin: - cd ${config.home.homeDirectory}/projects/oci-arm-host-capacity - ${phpBin} ./index.php | ${pkgs.jq}/bin/jq ".message" >> ${config.home.homeDirectory}/oci-run-log - ''; - in - mkIf (cfg.enable) { - systemd.user.services.oci-script = { - Unit = { - Description = "script to run oci-thing"; - }; - Install = { - WantedBy = ["default.target"]; - }; - Service = { - ExecStart = "${script script_name}"; - }; - }; - systemd.user.timers.oci-script = { - Install = { - WantedBy = ["timers.target"]; - }; - Timer = { - OnStartupSec = "1m"; - #OnActiveSec = "1m"; - OnUnitActiveSec = "1m"; - }; - }; - }; -} diff --git a/nixos/modules/home-manager/wayland-shell/anyrun/style.css b/nixos/modules/home-manager/wayland-shell/anyrun/style.css deleted file mode 100644 index 7cbadf6..0000000 --- a/nixos/modules/home-manager/wayland-shell/anyrun/style.css +++ /dev/null @@ -1,19 +0,0 @@ -#entry { - background-color: alpha(@theme_fg_color, 0.1); - border: 1px solid rgba(255, 255, 255, 0.15); - border-radius: 16px; -} - -#main { - background-color: alpha(@theme_bg_color, 0.3); - border: 1px solid rgba(255, 255, 255, 0.15); - border-radius: 16px; -} - -#plugin { - background-color: transparent; -} - -#window { - background: none; -} diff --git a/nixos/modules/home-manager/wayland-shell/waybar/config.json b/nixos/modules/home-manager/wayland-shell/waybar/config.json deleted file mode 100644 index 5d5b652..0000000 --- a/nixos/modules/home-manager/wayland-shell/waybar/config.json +++ /dev/null @@ -1,514 +0,0 @@ -[ - { - "layer": "top", - "position": "top", - "height": 30, - "output": "eDP-1", - "width": 1800, - "spacing": 4, - "margin-top": 0, - "name": "ayaya", - "modules-left": ["hyprland/workspaces"], - "modules-center": [], - "modules-right": ["wireplumber", "network", "cpu", "memory", "battery", "temperature", "backlight", "clock"], - "hyprland/workspaces": { - "disable-scroll": true, - "all-outputs": false, - "format": "{id}", - "format-icons": { - "1": "๏„ ", - "2": "๏‰จ", - "3": "๏„ก", - "4": "๏†ผ", - "5": "๏ต", - "urgent": "๏ช", - "focused": "๏†’", - "default": "๏„‘" - }, - "on-click": "activate" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "๏ฎ", - "deactivated": "๏ฐ" - } - }, - "tray": { - "icon-size": 21, - "spacing": 10 - }, - "clock": { - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ๏‹›", - "tooltip": false - }, - "memory": { - "format": "{}% ๏ƒ‰" - }, - "temperature": { - "thermal-zone": 2, - "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - "format-critical": "{temperatureC}ยฐC {icon}", - "format": "{temperatureC}ยฐC {icon}", - "format-icons": ["๏‹‡", "๏‹‰", "๏‹‡"] - }, - "backlight": { - "device": "amdgpu_bl0", - "format": "{percent}% {icon}", - "format-icons": ["๎Ž", "๎“", "๎‘", "๎", "๎Ž", "๎", "๎Š", "๎ˆ", "๎Ž›"] - }, - "battery": { - "states": { - "good": 95, - "warning": 30, - "critical": 15 - }, - "format": "{capacity}% {icon}", - "format-charging": "{capacity}% ๓ฐ‚„", - "format-plugged": "{capacity}% ๏‡ฆ", - "format-alt": "{time} {icon}", - "format-good": "{capacity}% {icon}", - "format-full": "{capacity}% {icon}", - "format-icons": ["๏‰„", "๏‰ƒ", "๏‰‚", "๏‰", "๏‰€"] - }, - "network": { - "format-wifi": "{essid} ({signalStrength}%) ๏‡ซ", - "format-ethernet": "{ipaddr}/{cidr} ๓ฐˆ€", - "tooltip-format": "{ifname} via {gwaddr} ๓ฐˆ€", - "format-linked": "{ifname} (No IP) ๓ฐˆ€", - "format-disconnected": "Disconnected โš ", - "format-alt": "{ifname}: {ipaddr}/{cidr}", - "interface": "wlp1s0" - }, - "pulseaudio": { - "scroll-step": 1, - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon}๏Š” {format_source}", - "format-bluetooth-muted": "๓ฐŸ {icon}๏Š” {format_source}", - "format-muted": "๓ฐŸ {format_source}", - "format-source": "{volume}% ๏„ฐ", - "format-source-muted": "๏„ฑ", - "format-icons": { - "headphone": "๏€ฅ", - "hands-free": "๓ฐ‹Ž", - "headset": "๓ฐ‹Ž", - "phone": "๏‚•", - "portable": "๏‚•", - "car": "๏†น", - "default": ["๏€ฆ", "๏€ง", "๏€จ"] - }, - "on-click": "pavucontrol" - }, - "wireplumber": { - "format": "{volume}% {icon}", - "format-muted": "๓ฐŸ muted", - "on-click": "helvum", - "format-icons": ["๏€ฆ", "๏€ง", "๏€จ"] - } - }, - { - "output": "eDP-1", - "layer": "top", - "position": "bottom", - "height": 30, - "width": 1800, - "spacing": 4, - "margin-bottom": 0, - "name": "bot", - "modules-left": ["hyprland/submap", "tray"], - "modules-center": ["hyprland/window"], - "modules-right": ["mpd"], - "hyprland/window": { - "format": "{}", - "max-length": 30 - }, - "mpd": { - "format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {title} โธจ{songPosition}|{queueLength}โธฉ {volume}% ๏€", - "format-disconnected": "Disconnected ๏€", - "format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ๏€", - "unknown-tag": "N/A", - "interval": 2, - "consume-icons": { - "on": "๏ƒ„ " - }, - "random-icons": { - "off": "๏ด ", - "on": "๏ด " - }, - "repeat-icons": { - "on": "๏€ž " - }, - "single-icons": { - "on": "๏€ž1 " - }, - "state-icons": { - "paused": "๏Œ", - "playing": "๏‹" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "๏ฎ", - "deactivated": "๏ฐ" - } - }, - "tray": { - "icon-size": 21, - "spacing": 10 - }, - "hyprland/submap": { - "format": "hypr:{}", - "max-length": 20, - "tooltip": true - } - }, - { - "layer": "top", - "position": "top", - "height": 30, - "output": "HDMI-A-1", - "width": 1040, - "spacing": 4, - "margin-top": 0, - "name": "ayaya", - "modules-left": ["hyprland/workspaces"], - "modules-center": [], - "modules-right": ["network", "cpu", "memory", "battery", "temperature", "clock"], - "wlr/taskbar": { - "all-outputs": false, - "on-click": "activate", - "active-first": true - }, - "hyprland/workspaces": { - "disable-scroll": true, - "all-outputs": false, - "format": "{id}", - "format-icons": { - "1": "๏„ ", - "2": "๏‰จ", - "3": "๏„ก", - "4": "๏†ผ", - "5": "๏ต", - "urgent": "๏ช", - "focused": "๏†’", - "default": "๏„‘" - }, - "on-click": "activate" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "๏ฎ", - "deactivated": "๏ฐ" - } - }, - "tray": { - "icon-size": 21, - "spacing": 10 - }, - "clock": { - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ๏‹›", - "tooltip": false - }, - "memory": { - "format": "{}% ๏ƒ‰" - }, - "temperature": { - "thermal-zone": 2, - "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - "format-critical": "{temperatureC}ยฐC {icon}", - "format": "{temperatureC}ยฐC {icon}", - "format-icons": ["๏‹‡", "๏‹‰", "๏‹‡"] - }, - "backlight": { - "device": "amdgpu_bl0", - "format": "{percent}% {icon}", - "format-icons": ["๎Ž", "๎“", "๎‘", "๎", "๎Ž", "๎", "๎Š", "๎ˆ", "๎Ž›"] - }, - "battery": { - "states": { - "good": 95, - "warning": 30, - "critical": 15 - }, - "format": "{capacity}% {icon}", - "format-charging": "{capacity}% ๓ฐ‚„", - "format-plugged": "{capacity}% ๏‡ฆ", - "format-alt": "{time} {icon}", - "format-good": "{capacity}% {icon}", - "format-full": "{capacity}% {icon}", - "format-icons": ["๏‰„", "๏‰ƒ", "๏‰‚", "๏‰", "๏‰€"] - }, - "network": { - "format-wifi": "{essid} ({signalStrength}%) ๏‡ซ", - "format-ethernet": "{ipaddr}/{cidr} ๓ฐˆ€", - "tooltip-format": "{ifname} via {gwaddr} ๓ฐˆ€", - "format-linked": "{ifname} (No IP) ๓ฐˆ€", - "format-disconnected": "Disconnected โš ", - "format-alt": "{ifname}: {ipaddr}/{cidr}", - "interface": "wlp1s0" - }, - "pulseaudio": { - "scroll-step": 1, - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon}๏Š” {format_source}", - "format-bluetooth-muted": "๓ฐŸ {icon}๏Š” {format_source}", - "format-muted": "๓ฐŸ {format_source}", - "format-source": "{volume}% ๏„ฐ", - "format-source-muted": "๏„ฑ", - "format-icons": { - "headphone": "๏€ฅ", - "hands-free": "๓ฐ‹Ž", - "headset": "๓ฐ‹Ž", - "phone": "๏‚•", - "portable": "๏‚•", - "car": "๏†น", - "default": ["๏€ฆ", "๏€ง", "๏€จ"] - }, - "on-click": "pavucontrol" - }, - "wireplumber": { - "format": "{volume}% {icon}", - "format-muted": "๓ฐŸ muted", - "on-click": "helvum", - "format-icons": ["๏€ฆ", "๏€ง", "๏€จ"] - } - }, - { - "output": "HDMI-A-1", - "layer": "top", - "position": "bottom", - "height": 30, - "width": 1000, - "spacing": 4, - "margin-bottom": 0, - "name": "bot", - "modules-left": ["tray"], - "modules-center": ["hyprland/window"], - "modules-right": ["mpd"], - "hyprland/window": { - "format": "{}", - "max-length": 30 - }, - "keyboard-state": { - "numlock": true, - "capslock": true, - "format": "{name} {icon}", - "format-icons": { - "locked": "๏€ฃ", - "unlocked": "๏‚œ" - } - }, - "mpd": { - "format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {title} โธจ{songPosition}|{queueLength}โธฉ {volume}% ๏€", - "format-disconnected": "Disconnected ๏€", - "format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ๏€", - "unknown-tag": "N/A", - "interval": 2, - "consume-icons": { - "on": "๏ƒ„ " - }, - "random-icons": { - "off": "๏ด ", - "on": "๏ด " - }, - "repeat-icons": { - "on": "๏€ž " - }, - "single-icons": { - "on": "๏€ž1 " - }, - "state-icons": { - "paused": "๏Œ", - "playing": "๏‹" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "๏ฎ", - "deactivated": "๏ฐ" - } - }, - "tray": { - "icon-size": 21, - "spacing": 10 - }, - "clock": { - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ๏‹›", - "tooltip": false - }, - "memory": { - "format": "{}% ๏ƒ‰" - }, - "temperature": { - "thermal-zone": 2, - "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - "format-critical": "{temperatureC}ยฐC {icon}", - "format": "{temperatureC}ยฐC {icon}", - "format-icons": ["๏‹‡", "๏‹‰", "๏‹‡"] - }, - "backlight": { - "format": "{percent}% {icon}", - "format-icons": ["๎Ž", "๎“", "๎‘", "๎", "๎Ž", "๎", "๎Š", "๎ˆ", "๎Ž›"] - }, - "network": { - "format-wifi": "{essid} ({signalStrength}%) ๏‡ซ", - "format-ethernet": "{ipaddr}/{cidr} ๓ฐˆ€", - "tooltip-format": "{ifname} via {gwaddr} ๓ฐˆ€", - "format-linked": "{ifname} (No IP) ๓ฐˆ€", - "format-disconnected": "Disconnected โš ", - "format-alt": "{ifname}: {ipaddr}/{cidr}" - }, - "pulseaudio": { - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon}๏Š” {format_source}", - "format-bluetooth-muted": "๓ฐŸ {icon}๏Š” {format_source}", - "format-muted": "๓ฐŸ {format_source}", - "format-source": "{volume}% ๏„ฐ", - "format-source-muted": "๏„ฑ", - "format-icons": { - "headphone": "๏€ฅ", - "hands-free": "๓ฐ‹Ž", - "headset": "๓ฐ‹Ž", - "phone": "๏‚•", - "portable": "๏‚•", - "car": "๏†น", - "default": ["๏€ฆ", "๏€ง", "๏€จ"] - }, - "on-click": "pavucontrol" - } - }, - { - "output": "DP-1", - "layer": "top", - "position": "bottom", - "height": 30, - "width": 1000, - "spacing": 4, - "margin-bottom": 0, - "name": "bot", - "modules-left": ["tray"], - "modules-center": ["hyprland/window"], - "modules-right": ["mpd"], - "hyprland/window": { - "format": "{}", - "max-length": 30 - }, - "keyboard-state": { - "numlock": true, - "capslock": true, - "format": "{name} {icon}", - "format-icons": { - "locked": "๏€ฃ", - "unlocked": "๏‚œ" - } - }, - "mpd": { - "format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {title} โธจ{songPosition}|{queueLength}โธฉ {volume}% ๏€", - "format-disconnected": "Disconnected ๏€", - "format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ๏€", - "unknown-tag": "N/A", - "interval": 2, - "consume-icons": { - "on": "๏ƒ„ " - }, - "random-icons": { - "off": "๏ด ", - "on": "๏ด " - }, - "repeat-icons": { - "on": "๏€ž " - }, - "single-icons": { - "on": "๏€ž1 " - }, - "state-icons": { - "paused": "๏Œ", - "playing": "๏‹" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "๏ฎ", - "deactivated": "๏ฐ" - } - }, - "tray": { - "icon-size": 21, - "spacing": 10 - }, - "clock": { - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ๏‹›", - "tooltip": false - }, - "memory": { - "format": "{}% ๏ƒ‰" - }, - "temperature": { - "thermal-zone": 2, - "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - "format-critical": "{temperatureC}ยฐC {icon}", - "format": "{temperatureC}ยฐC {icon}", - "format-icons": ["๏‹‡", "๏‹‰", "๏‹‡"] - }, - "backlight": { - "format": "{percent}% {icon}", - "format-icons": ["๎Ž", "๎“", "๎‘", "๎", "๎Ž", "๎", "๎Š", "๎ˆ", "๎Ž›"] - }, - "network": { - "format-wifi": "{essid} ({signalStrength}%) ๏‡ซ", - "format-ethernet": "{ipaddr}/{cidr} ๓ฐˆ€", - "tooltip-format": "{ifname} via {gwaddr} ๓ฐˆ€", - "format-linked": "{ifname} (No IP) ๓ฐˆ€", - "format-disconnected": "Disconnected โš ", - "format-alt": "{ifname}: {ipaddr}/{cidr}" - }, - "pulseaudio": { - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon}๏Š” {format_source}", - "format-bluetooth-muted": "๓ฐŸ {icon}๏Š” {format_source}", - "format-muted": "๓ฐŸ {format_source}", - "format-source": "{volume}% ๏„ฐ", - "format-source-muted": "๏„ฑ", - "format-icons": { - "headphone": "๏€ฅ", - "hands-free": "๓ฐ‹Ž", - "headset": "๓ฐ‹Ž", - "phone": "๏‚•", - "portable": "๏‚•", - "car": "๏†น", - "default": ["๏€ฆ", "๏€ง", "๏€จ"] - }, - "on-click": "pavucontrol" - } - } -] diff --git a/nixos/modules/home-manager/wayland-shell/waybar/style.css b/nixos/modules/home-manager/wayland-shell/waybar/style.css deleted file mode 100644 index 5de35d2..0000000 --- a/nixos/modules/home-manager/wayland-shell/waybar/style.css +++ /dev/null @@ -1,264 +0,0 @@ -* { - /* `otf-font-awesome` is required to be installed for icons */ - font-family: 'JetBrainsMono Nerd Font', monospace; - font-size: 20px; - min-height: 0; -} - -.modules-left { - margin: 2px 0 0 5px; -} - -.modules-right { - margin: 2px 10px 0 0; -} - -.modules-left.ayaya { -} - -window#waybar.ayaya { - background-color: #1e2030; - /* border: 3px solid rgba(100, 114, 125, 0.5); */ - color: #ffffff; - transition-property: background-color; - transition-duration: 0.5s; - border: none; - border-style: solid; - border-color: #c6a0f6; - border-radius: 0px 0px 10px 10px; -} - -window#waybar.bot { - background-color: #1e2030; - /* border: 3px solid rgba(100, 114, 125, 0.5); */ - color: #ffffff; - transition-property: background-color; - transition-duration: 0.5s; - border: none; - border-style: solid; - border-color: #c6a0f6; - border-radius: 10px 10px 0px 0px; -} - -window#waybar.hidden { - opacity: 0.2; -} - -/* -window#waybar.empty { - background-color: transparent; -} -window#waybar.solo { - background-color: #FFFFFF; -} -*/ - -window#waybar.termite { - background-color: #3f3f3f; -} - -window#waybar.chromium { - background-color: #000000; - border: none; -} - -#workspaces button { - background: transparent; - padding: 0 5px; - margin: 0px; - color: #f5bde6; - /* Use box-shadow instead of border so the text isn't offset */ - box-shadow: inset 0 -3px transparent; - /* Avoid rounded borders under each workspace name */ - border: none; - border-radius: 0; -} - -/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ -#workspaces button:hover { - background: rgba(0, 0, 0, 0.2); - box-shadow: inset 0 -3px #8aadf4; -} - -#workspaces button.visible { - background-color: #64727d; - /* background-color: #2d3436; */ - box-shadow: inset 0 -3px #ed8796; -} - -#workspaces button.active, -button.focused { - background-color: #6e738d; - /* background-color: #2d3436; */ - box-shadow: inset 0 -3px #ed8796; -} - -#workspaces button.urgent { - background-color: #eb4d4b; -} - -#mode { - background-color: #64727d; - border-bottom: 3px solid #ffffff; -} - -#clock, -#battery, -#cpu, -#memory, -#disk, -#backlight, -#temperature, -#network, -#pulseaudio, -#wireplumber, -#custom-media, -#tray, -#mode, -#idle_inhibitor, -#mpd { - padding: 0 10px; - color: #ffffff; -} - -#window { - padding-left: 10px; - padding-right: 10px; - background: transparent; - color: #ffffff; - box-shadow: inset 0 -3px #ffffff; -} - -#window, -#workspaces { - margin: 0 4px; -} - -/* If workspaces is the leftmost module, omit left margin */ -.modules-left > widget:first-child > #workspaces { - margin-left: 0; -} - -/* If workspaces is the rightmost module, omit right margin */ -.modules-right > widget:last-child > #workspaces { - margin-right: 0; -} - -#clock { - background-color: transparent; - color: #f5bde6; - box-shadow: inset 0 -3px #f5bde6; -} - -#battery { - background-color: transparent; - color: #a6da95; - box-shadow: inset 0 -3px #a6da95; -} - -#battery.charging, -#battery.plugged { - color: #a6da95; - background-color: transparent; -} - -@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: transparent; - color: #c6a0f6; - box-shadow: inset 0 -3px #c6a0f6; -} - -#memory { - background-color: transparent; - color: #8aadf4; - box-shadow: inset 0 -3px #8aadf4; -} - -#disk { - background-color: #964b00; -} - -#backlight { - background-color: transparent; - color: #f4dbd6; - box-shadow: inset 0 -3px #f4dbd6; -} - -#network { - background-color: transparent; - color: #7dc4e4; - box-shadow: inset 0 -3px #7dc4e4; -} - -#network.disconnected { - background-color: #f53c3c; -} - -#pulseaudio, -#wireplumber { - background-color: transparent; - color: #8bd5ca; - box-shadow: inset 0 -3px #8bd5ca; -} - -#pulseaudio.muted, -#wireplumber.muted { - background-color: transparent; - color: #8bd5ca; - box-shadow: inset 0 -3px #8bd5ca; -} - -#temperature { - background-color: transparent; - color: #f5a97f; - box-shadow: inset 0 -3px #f5a97f; -} - -#temperature.critical { - background-color: #eb4d4b; - color: #ffffff; -} - -#tray { - background-color: transparent; -} - -#tray > .passive { - -gtk-icon-effect: dim; -} - -#tray > .needs-attention { - -gtk-icon-effect: highlight; - background-color: #eb4d4b; -} - -#mpd { - background-color: transparent; - color: #ee99a0; - box-shadow: inset 0 -3px #ee99a0; -} - -#taskbar { - color: #000000; -} diff --git a/nixos/nix.nix b/nixos/nix.nix new file mode 100644 index 0000000..ef45a2a --- /dev/null +++ b/nixos/nix.nix @@ -0,0 +1,46 @@ +{ + flake, + pkgs, + ... +}: let + inherit (flake) inputs; +in { + nixpkgs = { + config = { + allowUnfree = true; + }; + + # put nixos overlays here + overlays = [inputs.neovim-nightly-overlay.overlays.default]; + }; + + nix = { + nixPath = ["nixpkgs=${flake.inputs.nixpkgs}"]; # Enables use of `nix-shell -p ...` etc + registry.nixpkgs.flake = flake.inputs.nixpkgs; # Make `nix shell` etc use pinned nixpkgs + settings = { + max-jobs = "auto"; + experimental-features = "nix-command flakes repl-flake"; + + # for non intel macs + # extra-platforms = lib.mkIf pkgs.stdenv.isDarwin "aarch64-darwin x86_64-darwin"; + + # Nullify the registry for purity. + flake-registry = builtins.toFile "empty-flake-registry.json" ''{"flakes":[],"version":2}''; + trusted-users = [ + "root" + ( + if pkgs.stdenv.isDarwin + then flake.config.people.myself + else "@wheel" + ) + "luqman" + ]; + + auto-optimise-store = true; + + substituters = ["https://hyprland.cachix.org"]; + trusted-public-keys = ["hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="]; + trusted-substituters = ["https://hyprland.cachix.org"]; + }; + }; +} diff --git a/nixos/nixos-vm-hc.nix b/nixos/nixos-vm-hc.nix deleted file mode 100644 index 8dd11b0..0000000 --- a/nixos/nixos-vm-hc.nix +++ /dev/null @@ -1,40 +0,0 @@ -# Do not modify this file! It was generated by โ€˜nixos-generate-configโ€™ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ - config, - lib, - pkgs, - modulesPath, - ... -}: { - imports = []; - - boot.initrd.availableKernelModules = ["ata_piix" "ohci_pci" "ehci_pci" "sd_mod" "sr_mod"]; - boot.initrd.kernelModules = []; - boot.kernelModules = []; - boot.extraModulePackages = []; - - fileSystems."/" = { - device = "/dev/disk/by-uuid/cc8ea570-938e-44a7-bd4a-06256662218a"; - fsType = "xfs"; - }; - - fileSystems."/boot" = { - device = "/dev/disk/by-uuid/F7ED-1A9B"; - fsType = "vfat"; - }; - - swapDevices = []; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. - networking.useDHCP = lib.mkDefault true; - # networking.interfaces.enp0s3.useDHCP = lib.mkDefault true; - - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; - virtualisation.virtualbox.guest.enable = true; -} diff --git a/nixos/nixos-vm.nix b/nixos/nixos-vm.nix deleted file mode 100644 index 90edb05..0000000 --- a/nixos/nixos-vm.nix +++ /dev/null @@ -1,174 +0,0 @@ -# This is your system's configuration file. -# Use this to configure your system environment (it replaces /etc/nixos/configuration.nix) -{ - inputs, - outputs, - lib, - config, - pkgs, - ... -}: { - # You can import other NixOS modules here - imports = [ - # If you want to use modules your own flake exports (from modules/nixos): - # outputs.nixosModules.example - - # Or modules from other flakes (such as nixos-hardware): - # inputs.hardware.nixosModules.common-cpu-amd - # inputs.hardware.nixosModules.common-ssd - - # You can also split up your configuration and import pieces of it here: - # ./users.nix - - # Import your generated (nixos-generate-config) hardware configuration - ./nixos-vm-hc.nix - ]; - - nixpkgs = { - # You can add overlays here - overlays = [ - # Add overlays your own flake exports (from overlays and pkgs dir): - outputs.overlays.modifications - outputs.overlays.additions - - # You can also add overlays exported from other flakes: - # neovim-nightly-overlay.overlays.default - - # Or define it inline, for example: - # (final: prev: { - # hi = final.hello.overrideAttrs (oldAttrs: { - # patches = [ ./change-hello-to-hi.patch ]; - # }); - # }) - ]; - # Configure your nixpkgs instance - config = { - # Disable if you don't want unfree packages - allowUnfree = true; - }; - }; - - nix = { - # This will add each flake input as a registry - # To make nix3 commands consistent with your flake - registry = lib.mapAttrs (_: value: {flake = value;}) inputs; - - # This will additionally add your inputs to the system's legacy channels - # Making legacy nix commands consistent as well, awesome! - nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry; - - settings = { - # Enable flakes and new 'nix' command - experimental-features = "nix-command flakes"; - # Deduplicate and optimize nix store - auto-optimise-store = true; - }; - }; - - # FIXME: Add the rest of your current configuration - - # Use the systemd-boot EFI boot loader. - boot.loader.systemd-boot.enable = true; - boot.loader.efi.canTouchEfiVariables = true; - - networking.hostName = "nixos-vm"; # Define your hostname. - # Pick only one of the below networking options. - # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. - networking.networkmanager.enable = true; # Easiest to use and most distros use this by default. - - # Set your time zone. - time.timeZone = "Asia/Kuala_Lumpur"; - - # Configure network proxy if necessary - # networking.proxy.default = "http://user:password@proxy:port/"; - # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; - - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; - #console = { - # font = "Lat2-Terminus16"; - # keyMap = "us"; - # useXkbConfig = true; # use xkbOptions in tty. - #}; - - # Enable the X11 windowing system. - # services.xserver.enable = true; - - # Configure keymap in X11 - # services.xserver.layout = "us"; - # services.xserver.xkbOptions = { - # "eurosign:e"; - # "caps:escape" # map caps to escape. - # }; - - # Enable CUPS to print documents. - # services.printing.enable = true; - - # Enable sound. - # sound.enable = true; - # hardware.pulseaudio.enable = true; - - # Enable touchpad support (enabled default in most desktopManager). - # services.xserver.libinput.enable = true; - - # Define a user account. Don't forget to set a password with โ€˜passwdโ€™. - users.users.luqman = { - isNormalUser = true; - extraGroups = ["wheel"]; # Enable โ€˜sudoโ€™ for the user. - shell = pkgs.fish; - packages = with pkgs; [ - tmux - neovim - byobu - ]; - }; - - programs.fish.enable = true; - - # List packages installed in system profile. To search, run: - # $ nix search wget - environment.systemPackages = with pkgs; [ - vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default. - neovim - wget - git - curl - fish - gcc - clang - ]; - - systemd = {tmpfiles = {rules = ["L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" "L+ /lib64 - - - - /lib"];};}; - - # Some programs need SUID wrappers, can be configured further or are - # started in user sessions. - # programs.mtr.enable = true; - # programs.gnupg.agent = { - # enable = true; - # enableSSHSupport = true; - # }; - - # List services that you want to enable: - - # Enable the OpenSSH daemon. - services.openssh.enable = true; - - # Open ports in the firewall. - # networking.firewall.allowedTCPPorts = [ ... ]; - # networking.firewall.allowedUDPPorts = [ ... ]; - # Or disable the firewall altogether. - networking.firewall.enable = false; - - # Copy the NixOS configuration file and link it from the resulting system - # (/run/current-system/configuration.nix). This is useful in case you - # accidentally delete configuration.nix. - # system.copySystemConfiguration = true; - - # This value determines the NixOS release from which the default - # settings for stateful data, like file locations and database versions - # on your system were taken. Itโ€˜s perfectly fine and recommended to leave - # this value at the release version of the first install of this system. - # Before changing this value read the documentation for this option - # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). - system.stateVersion = "22.11"; # Did you read the comment? -} diff --git a/nixos/nixos-wsl.nix b/nixos/nixos-wsl.nix deleted file mode 100644 index fe4016b..0000000 --- a/nixos/nixos-wsl.nix +++ /dev/null @@ -1,76 +0,0 @@ -{ - lib, - pkgs, - config, - modulesPath, - ... -}: -with lib; { - imports = [ - nixos-wsl.nixosModules.wsl - ]; - - wsl = { - enable = true; - automountPath = "/mnt"; - defaultUser = "luqman"; - startMenuLaunchers = true; - - interop = { - register = false; - }; - - wslConf = { - network.hostname = "nixos-wsl"; - }; - - # Enable native Docker support - # docker-native.enable = true; - - # Enable integration with Docker Desktop (needs to be installed) - # docker-desktop.enable = true; - }; - - users.users.luqman = { - isNormalUser = true; - extraGroups = ["wheel"]; # Enable โ€˜sudoโ€™ for the user. - shell = pkgs.fish; - uid = 1000; - createHome = true; - packages = with pkgs; [ - tmux - neovim - byobu - ]; - }; - - environment.systemPackages = with pkgs; [ - vim - neovim - wget - git - curl - fish - gcc - clang - ]; - - # Enable nix flakes - nix.package = pkgs.nixFlakes; - nix.extraOptions = '' - experimental-features = nix-command flakes - ''; - - environment.noXlibs = true; - documentation.enable = true; - documentation.doc.enable = true; - documentation.info.enable = true; - documentation.man.enable = true; - documentation.nixos.enable = true; - - programs.command-not-found.enable = true; - services.logrotate.enable = false; - services.udisks2.enable = false; - - system.stateVersion = "22.05"; -} diff --git a/nixos/secureboot.nix b/nixos/secureboot.nix new file mode 100644 index 0000000..0a85317 --- /dev/null +++ b/nixos/secureboot.nix @@ -0,0 +1,13 @@ +{lib, ...}: { + boot = { + # TODO: reimplement and writeup + # use the experimental bootspec + bootspec.enable = true; + loader.systemd-boot.enable = lib.mkForce false; + lanzaboote = { + enable = true; + pkiBundle = "/etc/secureboot"; + configurationLimit = 10; + }; + }; +} diff --git a/nixos/shells.nix b/nixos/shells.nix new file mode 100644 index 0000000..958da57 --- /dev/null +++ b/nixos/shells.nix @@ -0,0 +1,3 @@ +{ + programs.fish.enable = true; +} diff --git a/nixos/sinon.nix b/nixos/sinon.nix deleted file mode 100644 index 5762efa..0000000 --- a/nixos/sinon.nix +++ /dev/null @@ -1,98 +0,0 @@ -{ - lib, - pkgs, - config, - modulesPath, - inputs, - ... -}: -with lib; { - imports = [ - inputs.nixos-wsl.nixosModules.wsl - ]; - - wsl = { - enable = true; - defaultUser = "luqman"; - startMenuLaunchers = true; - nativeSystemd = true; - - interop = { - register = false; - includePath = false; - }; - - wslConf = { - network.hostname = "sinon"; - automount.root = "/mnt"; - }; - - # Enable native Docker support - # docker-native.enable = true; - - # Enable integration with Docker Desktop (needs to be installed) - # docker-desktop.enable = true; - }; - - users.users.luqman = { - isNormalUser = true; - extraGroups = ["wheel"]; # Enable โ€˜sudoโ€™ for the user. - shell = pkgs.fish; - uid = 1000; - createHome = true; - initialHashedPassword = "$y$j9T$jkFS1qQP.LZx3FHiWHZvk0$xlGgXWMx8nPgHfaVP3ESseZLsQjjoY6k.V4RGHcSpVC"; - description = "Luqmanul Hakim"; - packages = with pkgs; [ - tmux - neovim - byobu - ]; - }; - - environment.systemPackages = with pkgs; [ - vim - neovim - wget - git - curl - fish - gcc - clang - ]; - - # Enable nix flakes - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - nix.package = pkgs.nixFlakes; - nix.extraOptions = '' - experimental-features = nix-command flakes - ''; - - environment.noXlibs = true; - documentation.enable = true; - documentation.doc.enable = true; - documentation.info.enable = true; - documentation.man.enable = true; - documentation.nixos.enable = true; - - programs.command-not-found.enable = true; - programs.fish.enable = true; - services.logrotate.enable = false; - services.udisks2.enable = false; - - security.pam.loginLimits = [ - { - domain = "*"; - type = "soft"; - item = "nofile"; - value = "8192"; - } - ]; - systemd.tmpfiles.rules = [ - "L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" - "L+ /lib64 - - - - /lib" - ]; - - time.timeZone = "Asia/Kuala_Lumpur"; - - system.stateVersion = "22.05"; -} diff --git a/nixos/steam.nix b/nixos/steam.nix new file mode 100644 index 0000000..145c195 --- /dev/null +++ b/nixos/steam.nix @@ -0,0 +1,7 @@ +{ + programs.steam = { + enable = true; + remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play + dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server + }; +} diff --git a/nixos/users.nix b/nixos/users.nix new file mode 100644 index 0000000..4a6da7d --- /dev/null +++ b/nixos/users.nix @@ -0,0 +1,25 @@ +{pkgs, ...}: { + users.users.luqman = { + uid = 1000; + isNormalUser = true; + extraGroups = ["wheel" "audio" "video" "networkmanager" "podman" "adbusers" "mediacenter"]; + shell = pkgs.fish; + hashedPassword = "$y$j9T$eP.N3NAlrWm2f8OHHG4FE.$iBzd8hkR0mERN1K4JkaAueK5NRfO5dXa.zZh7zX8PV/"; + createHome = true; + description = "Luqmanul Hakim"; + }; + + programs.fish.enable = true; + + security.sudo.extraRules = [ + { + users = ["luqman"]; + commands = [ + { + command = "ALL"; + options = ["NOPASSWD"]; + } + ]; + } + ]; +} diff --git a/nixos/wsl.nix b/nixos/wsl.nix new file mode 100644 index 0000000..be87a56 --- /dev/null +++ b/nixos/wsl.nix @@ -0,0 +1,27 @@ +{ + flake, + lib, + ... +}: let + inherit (flake) inputs; +in { + imports = [inputs.nixos-wsl.nixosModules.default]; + + wsl = { + enable = true; + defaultUser = "luqman"; + + startMenuLaunchers = true; + nativeSystemd = true; + + interop = { + register = false; + includePath = false; + }; + + wslConf = { + network.hostname = "sinon"; + automount.root = "/mnt"; + }; + }; +} diff --git a/systems/asuna/default.nix b/systems/asuna/default.nix new file mode 100644 index 0000000..91f0067 --- /dev/null +++ b/systems/asuna/default.nix @@ -0,0 +1,291 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running โ€˜nixos-helpโ€™). +{ + flake, + lib, + pkgs, + ... +}: let + inherit (flake) inputs; + inherit (inputs) self; +in { + imports = [ + self.nixosModules.asuna + + # TODO: move to a module + inputs.xremap-flake.nixosModules.default + # Include the results of the hardware scan. + ./hardware.nix + ]; + + networking = { + hostName = "asuna"; # Define your hostname. + networkmanager.enable = true; + networkmanager.wifi.powersave = false; + + firewall = { + # Open ports in the firewall. + allowedTCPPorts = [22 8989 6881 8112 8096 8920]; + allowedUDPPorts = [6881 1990 7359]; + # Or disable the firewall altogether. + enable = true; + }; + }; + + time = { + # Set your time zone. + timeZone = "Asia/Kuala_Lumpur"; + hardwareClockInLocalTime = true; + }; + + # Select internationalisation properties. + i18n.defaultLocale = "en_US.UTF-8"; + + hardware = { + opengl = { + enable = true; + driSupport = true; + extraPackages = with pkgs; [ + # Vulkan + #amdvlk # Outdated + + # VAAPI + vaapiVdpau + libvdpau-va-gl + ]; + }; + + # bluetooth + bluetooth = { + enable = true; + settings = { + General = { + Enable = "Source,Sink,Media,Socket"; + }; + }; + }; + pulseaudio.enable = false; + }; + + services = { + blueman.enable = true; + + # TODO: maybe find a better alternative? + greetd = { + enable = true; + settings = { + vt = 2; + default_session = { + command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --cmd Hyprland"; + user = "greeter"; + }; + }; + }; + + # Enable CUPS to print documents. + printing.enable = true; + pipewire = { + enable = true; + audio.enable = true; + wireplumber.enable = true; + pulse.enable = true; + alsa.enable = true; + jack.enable = true; + }; + flatpak.enable = true; + # to ease mount of usbs + udisks2.enable = true; + tailscale.enable = true; + + protonvpn = { + enable = true; + autostart = false; + interface = { + ip = "10.2.0.2/32"; + privateKeyFile = "/etc/protonkey"; + dns = { + enable = true; + ip = "10.2.0.1"; + }; + }; + endpoint = { + publicKey = "6vLkUgiS/K8p5dTMwUQo6tiyJ65DrM8E2mwO+QFz/zs="; + ip = "138.199.21.206"; + port = 51820; + }; + }; + + # TODO: move xremap to dedicated module + xremap = { + withHypr = true; + config = { + modmap = [ + { + name = "Emacs pinky"; + remap = { + CapsLock = { + held = "CTRL_L"; + alone = "CapsLock"; + alone_timeout_millis = 200; + }; + }; + } + ]; + }; + userName = "luqman"; + watch = true; + }; + + tlp = { + enable = true; + settings = {}; + }; + + # Enable the OpenSSH daemon. + openssh.enable = true; + }; + + programs = { + dconf.enable = true; + light.enable = true; + git.enable = true; + hyprland = { + enable = true; + package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; + }; + adb.enable = true; + command-not-found.enable = false; + }; + + # Enable sound. + sound.enable = false; + + security = { + rtkit.enable = true; + + pam.loginLimits = [ + { + domain = "*"; + type = "soft"; + item = "nofile"; + value = "8192"; + } + ]; + pam.services.swaylock = {}; + sudo = { + extraRules = [ + { + users = ["luqman"]; + commands = [ + { + command = "ALL"; + options = ["NOPASSWD"]; + } + ]; + } + ]; + extraConfig = '' + Defaults lecture = never + ''; + }; + polkit.enable = true; + }; + + # TODO: refactor into own module + systemd.services.tailscale-funnel = { + unitConfig = { + Description = "Expose the jellyfin instance via tailscale"; + After = ["tailscaled.service"]; + }; + + serviceConfig = { + ExecStart = "${pkgs.tailscale}/bin/tailscale funnel 8096"; + Restart = "on-failure"; + RestartSec = 3; + }; + + wantedBy = ["multi-user.target"]; + }; + + # TODO: refactor into own module + console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz"; + + # TODO: wth do i do with this? + environment.systemPackages = with pkgs; [ + wayland + wayland.dev + wayland-protocols + wayland-utils + wayland-scanner + vim + wget + neovim + git + curl + fish + gcc + clang + python3 + python310Packages.pip + polkit-kde-agent + cloudflare-warp + aria2 + helvum + ntfsprogs + qemu + ( + pkgs.writeShellScriptBin "qemu-system-x86_64-uefi" '' + qemu-system-x86_64 \ + -bios ${pkgs.OVMF.fd}/FV/OVMF.fd \ + "$@" '' + ) + podman-compose + + steam-tui + steamcmd + + sbctl + ]; + + systemd = { + user.services.polkit-kde-authentication-agent-1 = { + description = "polkit-kde-authentication-agent-1"; + wantedBy = ["graphical-session.target"]; + wants = ["graphical-session.target"]; + after = ["graphical-session.target"]; + serviceConfig = { + Type = "simple"; + ExecStart = "${pkgs.polkit-kde-agent}/libexec/polkit-kde-authentication-agent-1"; + Restart = "on-failure"; + RestartSec = 1; + TimeoutStopSec = 10; + }; + }; + }; + + virtualisation = { + waydroid.enable = false; + lxd.enable = false; + podman = { + enable = true; + defaultNetwork.settings.dns_enabled = true; + }; + }; + + # zram swap + zramSwap = { + enable = true; + swapDevices = 1; + memoryPercent = 25; + algorithm = "zstd"; + }; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. Itโ€˜s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "22.11"; # Did you read the comment? +} diff --git a/systems/asuna/hardware.nix b/systems/asuna/hardware.nix new file mode 100644 index 0000000..c799737 --- /dev/null +++ b/systems/asuna/hardware.nix @@ -0,0 +1,100 @@ +{ + config, + pkgs, + lib, + ... +}: { + boot = { + loader = { + systemd-boot.enable = true; + systemd-boot.configurationLimit = 10; + efi.canTouchEfiVariables = true; + }; + + # use the latest zen kernel + kernelPackages = pkgs.linuxKernel.packages.linux_zen; + + initrd = { + # TODO: resetup impermeanance + + availableKernelModules = ["nvme" "xhci_pci" "usb_storage" "usbhid" "sd_mod"]; + kernelModules = []; + + luks.devices."enc".device = "/dev/disk/by-uuid/2f22d311-7714-4816-a444-39c1b87fbe20"; + }; + kernelModules = ["kvm-amd"]; + extraModulePackages = []; + }; + + fileSystems = { + "/" = { + device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; + fsType = "btrfs"; + options = ["subvol=root" "compress=zstd" "noatime"]; + }; + + "/home" = { + device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; + fsType = "btrfs"; + options = ["subvol=home" "compress=zstd" "noatime"]; + }; + + "/var/log" = { + device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; + fsType = "btrfs"; + options = ["subvol=var/log" "compress=zstd" "noatime"]; + }; + + "/var/lib" = { + device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; + fsType = "btrfs"; + options = ["subvol=var/lib" "compress=zstd" "noatime"]; + }; + + "/nix" = { + device = "/dev/disk/by-uuid/4552826e-cbe0-43c4-abd4-1d86248ac5ab"; + fsType = "btrfs"; + options = ["subvol=nix" "compress=zstd" "noatime"]; + }; + + "/boot" = { + device = "/dev/disk/by-uuid/E8FE-853C"; + fsType = "vfat"; + }; + + "/mnt/windowsc" = { + device = "/dev/disk/by-uuid/ACFA1C91FA1C59C2"; + fsType = "ntfs3"; + options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; + }; + + "/mnt/windowsd" = { + device = "/dev/disk/by-uuid/DA1AAC921AAC6CE7"; + fsType = "ntfs3"; + options = ["user" "exec" "rw" "uid=1000" "gid=1000"]; + }; + + "/mnt/storage2/jellyfin" = { + device = "/dev/disk/by-uuid/39ea80c4-e748-47eb-835c-64025de53e26"; + fsType = "btrfs"; + options = ["subvol=jellyfin" "compress=zstd" "rw" "user" "exec" "nofail"]; + }; + + "/mnt/storage2/rustic-repo" = { + device = "/dev/disk/by-uuid/39ea80c4-e748-47eb-835c-64025de53e26"; + fsType = "btrfs"; + options = ["subvol=rustic-repo" "compress=zstd" "rw" "user" "exec" "nofail"]; + }; + }; + swapDevices = []; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.wlp1s0.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} diff --git a/nixos/images/base-iso.nix b/systems/images/base-iso.nix similarity index 100% rename from nixos/images/base-iso.nix rename to systems/images/base-iso.nix diff --git a/nixos/images/default.nix b/systems/images/default.nix similarity index 100% rename from nixos/images/default.nix rename to systems/images/default.nix diff --git a/nixos/kurumi.nix b/systems/kurumi.nix similarity index 100% rename from nixos/kurumi.nix rename to systems/kurumi.nix diff --git a/systems/sinon.nix b/systems/sinon.nix new file mode 100644 index 0000000..b40db56 --- /dev/null +++ b/systems/sinon.nix @@ -0,0 +1,50 @@ +{ + lib, + pkgs, + flake, + ... +}: +with lib; let + inherit (flake) inputs; + inherit (inputs) self; +in { + imports = [ + self.nixosModules.sinon + ]; + + networking.hostName = "sinon"; + nixpkgs.hostPlatform = "x86_64-linux"; + + environment.systemPackages = with pkgs; [ + vim + neovim + wget + git + curl + fish + gcc + clang + ]; + + programs.command-not-found.enable = true; + services.logrotate.enable = false; + services.udisks2.enable = false; + + security.pam.loginLimits = [ + { + domain = "*"; + type = "soft"; + item = "nofile"; + value = "8192"; + } + ]; + + systemd.tmpfiles.rules = [ + "L+ /lib/${builtins.baseNameOf pkgs.stdenv.cc.bintools.dynamicLinker} - - - - ${pkgs.stdenv.cc.bintools.dynamicLinker}" + "L+ /lib64 - - - - /lib" + ]; + + time.timeZone = "Asia/Kuala_Lumpur"; + + system.stateVersion = "22.05"; +}