diff --git a/config/neovim/coc-settings.nix b/config/neovim/coc-settings.nix index 0bd9218..65f9d1c 100644 --- a/config/neovim/coc-settings.nix +++ b/config/neovim/coc-settings.nix @@ -24,6 +24,11 @@ command = "rnix-lsp"; filetypes = [ "nix" ]; }; + + zig = { + command = "zls"; + filetypes = [ "zig" ]; + }; }; "yank.highlight.duration" = 700; diff --git a/flake.lock b/flake.lock index 1e1c46d..3b3278e 100755 --- a/flake.lock +++ b/flake.lock @@ -88,23 +88,6 @@ "type": "github" } }, - "meson": { - "flake": false, - "locked": { - "lastModified": 1640155612, - "narHash": "sha256-XrEIlf0W8mKEa97Uyc0w/187KBGEZOD+dJFNsn3UeNg=", - "owner": "mesonbuild", - "repo": "meson", - "rev": "06aad5233e6bec97bfe21ae79c85aa7171089d3b", - "type": "github" - }, - "original": { - "owner": "mesonbuild", - "ref": "0.60", - "repo": "meson", - "type": "github" - } - }, "nixos-hardware": { "locked": { "lastModified": 1639986101, @@ -208,28 +191,10 @@ "inputs": { "agenix": "agenix", "home-manager": "home-manager", - "meson": "meson", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", "nixpkgs-unstable": "nixpkgs-unstable", - "polymc": "polymc", - "sway-borders": "sway-borders" - } - }, - "sway-borders": { - "flake": false, - "locked": { - "lastModified": 1640037473, - "narHash": "sha256-gCdnim7excF11GEoni5YbIGTWSIx+wjHc8NO8lVNFts=", - "owner": "fluix-dev", - "repo": "sway-borders", - "rev": "5f4162f449b19f6d198b365fc6d3dd0febc065e2", - "type": "github" - }, - "original": { - "owner": "fluix-dev", - "repo": "sway-borders", - "type": "github" + "polymc": "polymc" } } }, diff --git a/flake.nix b/flake.nix index 3b3e880..4cad7bc 100755 --- a/flake.nix +++ b/flake.nix @@ -29,11 +29,6 @@ asyncrun-vim.url = "github:skywind3000/asyncrun.vim"; asyncrun-vim.flake = false; */ - meson.url = "github:mesonbuild/meson/0.60"; - meson.flake = false; - - sway-borders.url = "github:fluix-dev/sway-borders"; - sway-borders.flake = false; # blender-30.url = "github:blender/blender/blender-v3.0-release"; # blender-30.flake = false; @@ -59,15 +54,11 @@ packages."${system}" = mapModules ./packages (p: pkgs.callPackage p {}); overlay = final: prev: { _ = self.packages."${system}"; -# meson = inputs.meson; -# sway-unwrapped = inputs.sway-borders; -# blender = inputs.blender-30; unstable = mkPkgs nixpkgs-unstable []; }; overlays = mapModules ./overlays import; nixosModules = mapModulesRec ./modules import; nixosConfigurations = mapModules ./hosts (mkHost system); - devShell."${system}" = - import ./shell.nix { inherit pkgs; }; + devShell."${system}" = import ./shell.nix { inherit pkgs; }; }; } diff --git a/hosts/firepit/default.nix b/hosts/firepit/default.nix index 8d154e5..0d915f5 100644 --- a/hosts/firepit/default.nix +++ b/hosts/firepit/default.nix @@ -14,7 +14,7 @@ defaultUsers = { aether = { packages = [ ]; - shell = "zsh"; + shell = "fish"; extraGroups = [ "wheel" ]; }; oatmealine = { @@ -22,6 +22,11 @@ shell = "zsh"; extraGroups = [ "wheel" ]; }; + skye = { + packages = [ ]; + shell = "fish"; + extraGroups = [ "wheel" ]; + }; }; keyboard = { @@ -49,6 +54,11 @@ enable = true; site = "git.oat.zone"; }; + wireguard = { + enable = true; + server = true; + interfaces = mkMerge (import ./interfaces); + }; }; }; diff --git a/hosts/firepit/hardware-configuration.nix b/hosts/firepit/hardware-configuration.nix new file mode 100644 index 0000000..0a460ea --- /dev/null +++ b/hosts/firepit/hardware-configuration.nix @@ -0,0 +1,47 @@ +{ config, lib, pkgs, inputs, modulesPath, ... }: + +{ + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot = { + initrd.availableKernelModules = [ "xhci_pci" "nvme" "usbhid" "usb_storage" "sd_mod" ]; + initrd.kernelModules = [ ]; + kernelPackages = pkgs.linuxPackages_hardened; + kernelModules = [ "kvm-intel" ]; + loader = { + systemd-boot = { + enable = true; + configurationLimit = 10; + }; + efi.canTouchEfiVariables = true; + }; + }; + + modules.hardware.fs = { + enable = true; + ssd.enable = true; + }; + + extraModulePackages = with config.boot.kernelPackages; [ v4l2loopback ]; + + fileSystems = { + "/" = { + device = "/dev/disk/by-uuid/?"; + fsType = "?"; + options = [ "defaults" "noatime" "nodiratime" ]; + }; + + "/etc/dotfiles" = { + device = "/dev/disk/by-uuid/?"; + fsType = "f2fs"; + options = [ "defaults" "noatime" "nodiratime" ]; + }; + + "/boot" = { + device = "/dev/disk/by-uuid/?"; + fsType = "vfat"; + }; + }; +} diff --git a/hosts/firepit/interfaces/default.nix b/hosts/firepit/interfaces/default.nix new file mode 100644 index 0000000..41b42e6 --- /dev/null +++ b/hosts/firepit/interfaces/default.nix @@ -0,0 +1,3 @@ +[ + +] diff --git a/hosts/firepit/secrets/secrets.nix b/hosts/firepit/secrets/secrets.nix index 814c36d..f91db83 100644 --- a/hosts/firepit/secrets/secrets.nix +++ b/hosts/firepit/secrets/secrets.nix @@ -1,11 +1,14 @@ let - userAether = "<...>"; - userOatmealine = "<...>"; + subsurface.Access = "<...>"; + void-defragmented.Access = "<...>"; + userSkye.Access = "<...>"; in { - "aether" = { - "userAether.age".publicKeys = [ userAether ]; - }; - "oatmealine" = { - "userOatmealine.age".publicKeys = [ userOatmealine ]; - }; + "subsurface.age".publicKeys = attrValues subsurface; + "subsurface.age".owner = "aether"; + + "void-defragmented.age".publicKeys = attrValues void-defragmented; + "void-defragmented.age".owner = "oatmealine"; + + "skye.age".publicKeys = attrValues userSkye; + "skye.age".owner = "skye"; } diff --git a/hosts/subsurface/default.nix b/hosts/subsurface/default.nix index 556b41d..d90434c 100644 --- a/hosts/subsurface/default.nix +++ b/hosts/subsurface/default.nix @@ -7,7 +7,7 @@ defaultUsers = { aether = { - packages = with pkgs; [ htop curl mpc_cli gammastep discord obs-studio youtube-dl inkscape audacity dolphin firefox-wayland wl-clipboard steam bitwarden blender neofetch krita celluloid imv firefox zathura ]; + packages = with pkgs; with pkgs._; [ htop discord youtube-dl inkscape audacity dolphin steam bitwarden blender neofetch krita celluloid imv firefox zathura zip unzip ffmpeg pijul pavucontrol killall ripcord steam-run appimage-run openjdk11 ]; uid = 1024; isNormalUser = true; shell = "zsh"; @@ -44,11 +44,9 @@ neovim.enable = true; codium.enable = true; }; -/* gaming = { minecraft.enable = true; }; -*/ }; dev = { llvm.enable = true; @@ -57,14 +55,16 @@ version = "ghc902"; }; c.enable = true; + rust.enable = true; + zig.enable = true; }; services = { ssh.enable = true; mpd = { enable = true; # TODO: Make this more dynamic? - musicDir = "/home/aether/Music"; - user = "aether"; + musicDir = "/home/aether/Music"; + user = "aether"; }; geoclue2.enable = true; }; diff --git a/hosts/subsurface/hardware-configuration.nix b/hosts/subsurface/hardware-configuration.nix index 092756a..9d8622c 100644 --- a/hosts/subsurface/hardware-configuration.nix +++ b/hosts/subsurface/hardware-configuration.nix @@ -110,6 +110,16 @@ device = "/run/media/aether/bf2d91f1-a6b3-4629-8755-76301b3f6f56/home delta/home delta delta/Music"; options = [ "bind" ]; }; + + "/home/aether/Textures" = { + device = "/run/media/aether/bf2d91f1-a6b3-4629-8755-76301b3f6f56/home\ delta/Textures"; + options = [ "bind" ]; + }; + + "/home/aether/Porn" = { + device = "/run/media/aether/bf2d91f1-a6b3-4629-8755-76301b3f6f56/home\ delta/Porn"; + options = [ "bind" ]; + }; }; swapDevices = [{ device = "/dev/disk/by-uuid/e4a7edca-2c4e-4979-8368-377bc067b8bd"; }]; diff --git a/hosts/subsurface/secrets/firepitAccess.age b/hosts/subsurface/secrets/firepitAccess.age new file mode 100644 index 0000000..712fb87 Binary files /dev/null and b/hosts/subsurface/secrets/firepitAccess.age differ diff --git a/hosts/subsurface/secrets/secrets.nix b/hosts/subsurface/secrets/secrets.nix index 86214e1..77ec04b 100644 --- a/hosts/subsurface/secrets/secrets.nix +++ b/hosts/subsurface/secrets/secrets.nix @@ -1,5 +1,5 @@ let - firepitAccess = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCoaiYQuYPYO217IA8rGIVvbQCoVaqERGAGevq+WxutrcdUZraa2Zp44GEZEmNFVNlgm2FtkOV42vqwnx2gfkHmuYA38Cov9jbxtIv4ytaWve+UniNBtUF9De0ULqKTUErk5iBX7gBpg4hY2+GVSSrYJ4KZIwDbA6uNj7PTyQDSZrGfQMbFR52HEXttehg7/vMXUVwhnakpKk3v21bCQRNzc3K9dcFUDSTH1uOE1oEfKhGp2zHtnknLDlMIhGQcpwfOKPqURsbzXpln1EyEMlrudjMRDg/ZKsKxYuW0Lnbxqqifgm9ERvSeq+517j3QA2Z6EWLY5yejgcDiyDy8bvqV"; + firepitAccess = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC4lh7dN9Ohh2/WoGiZ4WlpVb01YPNto/9ungOAk6TH+65wkxMjY4a+1OsO8Znguj46tXVErn8xv2ZVX0K7ql0hzypPkP2Dvvim99tz6FKSf9Nwj6RRtIKPoYkJjtGYAqLJl8JPy50HkFXkDVQ/z4d4iwpneSODIJdkUFSzZR91jz9FX+4t2h+2xtuuRDI43+gHRqvwPP8XaE0srtMzZoQDUBKhwOynoo2vZnyd3O7kkpD9T+jzYEeLKppHdaoYN5UxZ4L0xnig0WFZiBH36/YGXA8gT56FHRw5GKhwWwfSvliEw63/6IxiVZBuM1Mj7syg2Ndhhmmay05QqvyTrdHA9veyzJG5l0HlnCmXe7ss9lVQnxxPfbHbnDZUhH1ax01sQUeTK3Bs3AvbsTLyXBbd4NCY5ovz85MqzM/Q84B1zX1i8KbFEBh0xkumNsPAXzY8ar+tq5rFa23bY9qF4s6CMv++JEXSJJufcf3BS2dBlw0lTGBn7UEO9FHHsU3xKCc= aether@aether"; in { "firepitAccess.age".publicKeys = [ firepitAccess ]; "firepitAccess.age".owner = "aether"; diff --git a/lib/modules.nix b/lib/modules.nix index 84c72a8..cd45615 100644 --- a/lib/modules.nix +++ b/lib/modules.nix @@ -15,8 +15,8 @@ in rec { in if type == "directory" then nameValuePair name (dirfn path) -# else if type == "regular" && name != "default.nix" && hasSuffix ".nix" name then - else if type == "regular" && hasSuffix ".nix" name then + else if type == "regular" && name != "default.nix" && hasSuffix ".nix" name then +# else if type == "regular" && hasSuffix ".nix" name then nameValuePair (removeSuffix ".nix" name) (fn path) else nameValuePair "" null diff --git a/modules/agenix.nix b/modules/agenix.nix index 4082fea..dfeb249 100644 --- a/modules/agenix.nix +++ b/modules/agenix.nix @@ -8,19 +8,17 @@ let secretsDir = "${toString ../hosts}/${config.networking.hostName}/secrets"; secretsFile = "${secretsDir}/secrets.nix"; in { -/* imports = [ agenix.nixosModules.age ]; environment.systemPackages = [ agenix.defaultPackage.x86_64-linux ]; age = { - secrets = mkIf (pathExists secretsFile) (mapAttrs (n: o: { - file = "${secretsDir}/" + n; - owner = o.owner; - }) (import secretsFile)); - identityPaths = options.age.identityPaths.default ++ (filter pathExists [ -# ".ssh/id_ed25519" -# ".ssh/id_rsa" - ]); + secrets = mkMerge (map (x: {"x".file = "${secretsDir}/${x}";}) (attrNames (import secretsFile))); + identityPaths = options.age.identityPaths.default ++ (foldr (l: r: l ++ r) [] (map (user: + let + d = "/home/${user}/.ssh"; + fs = map (f: d + "/" + f) + (filter (f: (f != "known_hosts") && (f != "*.old")) + (attrNames (readDir d))); + in fs) (attrNames config.defaultUsers))); }; -*/ } diff --git a/modules/desktop/apps/firefox.nix b/modules/desktop/apps/firefox.nix index 81c6af5..41045f8 100644 --- a/modules/desktop/apps/firefox.nix +++ b/modules/desktop/apps/firefox.nix @@ -13,12 +13,10 @@ in { }; config = mkIf cfg.enable { -/* user.packages = if wayland then (with pkgs; [ firefox-wayland ]) else (with pkgs; [ firefox ]); -*/ }; } diff --git a/modules/desktop/apps/mpc.nix b/modules/desktop/apps/mpc.nix index f7d8057..3f72c6d 100644 --- a/modules/desktop/apps/mpc.nix +++ b/modules/desktop/apps/mpc.nix @@ -13,10 +13,10 @@ in { config = mkIf cfg.enable { modules.services.mpd.enable = true; -/* + user.packages = with pkgs; [ mpc_cli ]; -*/ + }; } diff --git a/modules/desktop/apps/obs.nix b/modules/desktop/apps/obs.nix index e39829c..1c059eb 100644 --- a/modules/desktop/apps/obs.nix +++ b/modules/desktop/apps/obs.nix @@ -12,10 +12,8 @@ in { }; config = mkIf cfg.enable { -/* user.packages = with pkgs; [ obs-studio ]; -*/ }; } diff --git a/modules/desktop/default.nix b/modules/desktop/desktop.nix similarity index 100% rename from modules/desktop/default.nix rename to modules/desktop/desktop.nix diff --git a/modules/desktop/editors/neovim.nix b/modules/desktop/editors/neovim.nix index 229e4d4..b996f4a 100644 --- a/modules/desktop/editors/neovim.nix +++ b/modules/desktop/editors/neovim.nix @@ -41,7 +41,9 @@ in { ghcid fzf-vim # inputs.fzf-hoogle-vim - ] else [ ]); + ] else if config.modules.dev.zig.enable then with pkgs.vimPlugins; [ + zig-vim + ] else []); viAlias = true; vimAlias = true; diff --git a/modules/desktop/gaming/minecraft.nix b/modules/desktop/gaming/minecraft.nix index 89a4eb0..96760f6 100644 --- a/modules/desktop/gaming/minecraft.nix +++ b/modules/desktop/gaming/minecraft.nix @@ -13,6 +13,6 @@ in { }; config = mkIf cfg.enable { -# user.packages = [ polymc ]; + environment.systemPackages = with pkgs; [ polymc ]; }; } diff --git a/modules/desktop/river.nix b/modules/desktop/river.nix new file mode 100644 index 0000000..2d8ff52 --- /dev/null +++ b/modules/desktop/river.nix @@ -0,0 +1,28 @@ +{ options, config, lib, pkgs, ... }: + +with lib; +let + cfg = config.modules.desktop.river; + audioSupport = config.modules.hardware.audio.enable; +in { + options.modules.desktop.river = { + enable = mkOption { + type = tyoes.bool; + default = false; + description = "Enables the river wayland compositor."; + }; + menu = mkOption { + type = types.str; + default = "nwggrid"; + description = "Which application launch menu to use. Defaults to nwggrid."; + }; + term = mkOption { + type = types.str; + default = "alacritty"; + description = "Which terminal river should use. Defaults to alacritty."; + }; + }; + + config = mkIf cfg.enable { + }; +} diff --git a/modules/desktop/sway.nix b/modules/desktop/sway.nix index 351ee21..9ec1a4c 100644 --- a/modules/desktop/sway.nix +++ b/modules/desktop/sway.nix @@ -31,7 +31,6 @@ in { extraPackages = with pkgs; [ xwayland ]; }; -/* user.packages = with pkgs; [ grim slurp @@ -40,10 +39,10 @@ in { autotiling brightnessctl wdisplays + gammastep ] ++ (if audioSupport then (with pkgs; [ playerctl ]) else [ ]); -*/ xdg.portal = { enable = true; @@ -101,6 +100,7 @@ in { bg = "${config.modules.theme.wallpaper} fill"; scale = "1.5"; }; + output."DP-4".bg = "${config.modules.theme.wallpaper} fill"; keybindings = let mod = config.home._.wayland.windowManager.sway.config.modifier; scProc = "wl-copy -t image/png && notify-send \"Screenshot Taken\""; in { # "${mod}+l" = "exec lock"; "${mod}+q" = "reload"; @@ -131,7 +131,9 @@ in { "${mod}+Shift+9" = "move container to workspace 9"; "${mod}+Shift+0" = "move container to workspace 10"; - "Print" = "exec grim -g \"$(slurp -d)\" - | ${scProc}"; + "Print" = "exec grim -g \"$(slurp -d)\" - | ${scProc}"; + "XF86AudioPlay" = "playerctl play-pause"; + "Shift+XF86AudioPlay" = "playerctl loop"; }; }; extraSessionCommands = '' diff --git a/modules/dev/c.nix b/modules/dev/c.nix index 070271d..9b1c92e 100644 --- a/modules/dev/c.nix +++ b/modules/dev/c.nix @@ -13,7 +13,7 @@ in { }; config = mkIf cfg.enable { - environment.systemPackages = if !withLLVM then with pkgs; [ + user.packages = if !withLLVM then with pkgs; [ gcc ] else with pkgs; [ clang_12 diff --git a/modules/dev/default.nix b/modules/dev/dev.nix similarity index 100% rename from modules/dev/default.nix rename to modules/dev/dev.nix diff --git a/modules/dev/haskell.nix b/modules/dev/haskell.nix index 8f7bf45..e286f78 100644 --- a/modules/dev/haskell.nix +++ b/modules/dev/haskell.nix @@ -20,7 +20,7 @@ in { }; config = mkIf cfg.enable { - environment.systemPackages = with pkgs.haskell.packages."${cfg.version}"; [ + user.packages = with pkgs.haskell.packages."${cfg.version}"; [ ghc cabal-install ] ++ config.modules.dev.haskell.packages; diff --git a/modules/dev/rust.nix b/modules/dev/rust.nix new file mode 100644 index 0000000..6fc62c5 --- /dev/null +++ b/modules/dev/rust.nix @@ -0,0 +1,22 @@ +{ pkgs, lib, config, options, ... }: + +with lib; +let + cfg = config.modules.dev.rust; +in { + options.modules.dev.rust = { + enable = mkOption { + type = types.bool; + default = false; + }; + }; + + config = mkIf cfg.enable { + user.packages = with pkgs; [ + cargo + rustc + ]; + + environment.sessionVariables.RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}"; + }; +} diff --git a/modules/dev/zig.nix b/modules/dev/zig.nix new file mode 100644 index 0000000..e63994e --- /dev/null +++ b/modules/dev/zig.nix @@ -0,0 +1,20 @@ +{ config, options, lib, pkgs, ... }: + +with lib; +let + cfg = config.modules.dev.zig; +in { + options.modules.dev.zig = { + enable = mkOption { + type = types.bool; + default = false; + description = "Adds zig tools to the environment."; + }; + }; + + config = mkIf cfg.enable { + user.packages = with pkgs; [ + zig + ]; + }; +} diff --git a/modules/services/geoclue2.nix b/modules/services/geoclue2.nix index 5c1493a..3c8eec5 100644 --- a/modules/services/geoclue2.nix +++ b/modules/services/geoclue2.nix @@ -6,7 +6,7 @@ let in { options.modules.services.geoclue2 = { enable = mkOption { - type = types.bool + type = types.bool; default = false; }; }; diff --git a/modules/services/wiregaurd.nix b/modules/services/wiregaurd.nix new file mode 100644 index 0000000..ac38216 --- /dev/null +++ b/modules/services/wiregaurd.nix @@ -0,0 +1,47 @@ +{ config, lib, pkgs, options, ... }: + +with lib; +let + cfg = config.modules.services.wireguard; + opt = options.modules.services.wireguard; +in { + options.modules.services.wireguard = { + enable = mkOption { + type = types.bool; + default = false; + description = "Enables the wiregyard VPN service."; + }; + server = mkOption { + type = types.bool; + default = false; + description = "Configures this module to allow wireguard to act as a VPN provider on this host."; + }; + interfaces = mkOption { + type = types.attrs; + default = {}; + description = "Which interfaces wireguard should atach itself to. The first one is prioritized over all others."; + }; + port = mkOption { + type = types.int; + default = 51820; + description = "The default listen port."; + }; + }; + + config = mkIf cfg.enable (mkMerge [ + { + networking.firewall.allowedUDPPorts = [ cfg.port ]; + + networking.wireguard.interfaces = mapAttrs (i: c: mkMerge [c { + listenPort = cfg.port; + }]) (mkAliasDefinitions options.modules.services.wireguard.interfaces); + } + (mkIf cfg.server { + networking.nat = { + enable = true; +# externalInterfaces = head cfg.interfaces; +# internalInterfaces = cfg.interfaces; + }; + }) + ]); +} diff --git a/modules/shell/fish.nix b/modules/shell/fish.nix index 7b03f6d..ef511df 100644 --- a/modules/shell/fish.nix +++ b/modules/shell/fish.nix @@ -25,7 +25,7 @@ in { home.configFile = { "fish" = { source = "${cfgDir}/fish"; - target = "$HOME.config/fish"; + target = "$HOME/.config/fish"; }; }; }; diff --git a/modules/theme/default.nix b/modules/theme.nix similarity index 100% rename from modules/theme/default.nix rename to modules/theme.nix diff --git a/modules/theme/still/background.png b/modules/themes/still/background.png similarity index 100% rename from modules/theme/still/background.png rename to modules/themes/still/background.png diff --git a/modules/theme/still/config/nwggrid/style.css b/modules/themes/still/config/nwggrid/style.css similarity index 100% rename from modules/theme/still/config/nwggrid/style.css rename to modules/themes/still/config/nwggrid/style.css diff --git a/modules/theme/still/config/sway/config b/modules/themes/still/config/sway/config similarity index 100% rename from modules/theme/still/config/sway/config rename to modules/themes/still/config/sway/config diff --git a/modules/theme/still/config/waybar/style.css b/modules/themes/still/config/waybar/style.css similarity index 100% rename from modules/theme/still/config/waybar/style.css rename to modules/themes/still/config/waybar/style.css diff --git a/modules/theme/still/default.nix b/modules/themes/still/theme.nix similarity index 100% rename from modules/theme/still/default.nix rename to modules/themes/still/theme.nix diff --git a/modules/users.nix b/modules/users.nix index 9891f67..03066bb 100644 --- a/modules/users.nix +++ b/modules/users.nix @@ -34,21 +34,14 @@ with lib; config = { home-manager.useUserPackages = true; -/* user = { packages = with pkgs; [ curl ]; extraGroups = [ "wheel" ]; - shell = {}; - home = "/home/default"; - isNormalUser = false; - isSystemUser = false; - group = ""; }; -*/ home._ = { home.stateVersion = config.system.stateVersion; -# home.file = mkAliasDefinitions options.home.file; + home.file = mkAliasDefinitions options.home.configFile; xdg.enable = true; xdg.configFile = mkAliasDefinitions options.home.configFile; }; @@ -63,14 +56,14 @@ with lib; }; }; - users.users = mapAttrs (user: prop: /* (mkAliasDefinitions options.user) // */ { + users.users = mapAttrs (user: prop: mkMerge [(mkAliasDefinitions options.user) { packages = prop.packages; extraGroups = prop.extraGroups; - shell = pkgs."${config.defaultUsers."${user}".shell}"; + shell = trace "penis" pkgs."${config.defaultUsers."${user}".shell}"; home = "/home/${user}"; isNormalUser = true; group = user; - }) config.defaultUsers; + }]) config.defaultUsers; home-manager.users = mapAttrs (user: prop: mkAliasDefinitions options.home._ ) config.defaultUsers; diff --git a/packages/soundux.nix b/packages/soundux.nix new file mode 100644 index 0000000..b700a78 --- /dev/null +++ b/packages/soundux.nix @@ -0,0 +1,33 @@ +{ stdenv, lib, fetchurl +, cmake +, alsaLib +, glib +, gtk3 +, xorg +, webkitgtk +, libxkbcommon +, pulseaudio +, pipewire +}: + +stdenv.mkDerivation rec { + pname = "soundux"; + version = "0.2.6"; + + src = fetchurl { + url = "https://github.com/Soundux/Soundux/releases/download/${version}/${pname}-${version}.tar.gz"; + sha256 = "0cffff520b3d1e69ccbb10599ff1ff3c911d74eb01a4af8dc3d5132fa5535c63"; + }; + + nativeBuildInputs = [ cmake ]; + buildInputs = with xorg; [ + alsaLib glib gtk3 webkitgtk libxkbcommon pulseaudio pipewire libX11 + ]; + + meta = with lib; { + description = "A universal soundboard that uses PulseAudio modules or PipeWire linking"; + homepage = "https://soundux.rocks/"; + license = lib.licenses.gpl3Plus; + platforms = lib.platforms.linux; + }; +}