From 2a9e3d876f7ae9db7733c2644fd283a9ed152879 Mon Sep 17 00:00:00 2001 From: Miran Bastaja Date: Sun, 30 Jun 2024 15:50:54 +0200 Subject: hyprdesktop: add xdg-utils --- flake.nix | 63 +++++++++++++++++++++------------------- share/hm-modules/hyprdesktop.nix | 2 ++ 2 files changed, 35 insertions(+), 30 deletions(-) diff --git a/flake.nix b/flake.nix index aeaf818..e309883 100644 --- a/flake.nix +++ b/flake.nix @@ -41,7 +41,8 @@ }; }; - outputs = inputs@{ flake-parts, ... }: + outputs = + inputs@{ flake-parts, ... }: inputs.flake-parts.lib.mkFlake { inherit inputs; } { systems = [ "x86_64-linux" ]; imports = [ @@ -70,8 +71,7 @@ }; }; # wrapper around nixpkgs.lib.nixosSystem to enable using it on attrsets - generateNixosSystem = _name: value: - inputs.nixpkgs.lib.nixosSystem value; + generateNixosSystem = _name: value: inputs.nixpkgs.lib.nixosSystem value; hosts = builtins.readDir ./hosts; nixosConfigs = builtins.mapAttrs generateNixosConfig hosts; @@ -81,37 +81,40 @@ in builtins.mapAttrs generateNixosSystem nixosConfigs; - perSystem = { pkgs, config, ... }: { - devshells.default = { - name = "nixconf-sh"; + perSystem = + { pkgs, config, ... }: + { + devshells.default = { + name = "nixconf-sh"; - devshell.startup.pre-commit-install.text = - config.pre-commit.installationScript; + devshell.startup.pre-commit-install.text = config.pre-commit.installationScript; - packages = (builtins.attrValues config.treefmt.build.programs); - commands = with pkgs; [ - { package = git; } - { package = gitui; } - { package = sops; } - { package = config.treefmt.build.wrapper; } - ]; - }; - - treefmt = { - projectRootFile = ./flake.nix; - programs = { nixpkgs-fmt.enable = true; }; - }; + packages = (builtins.attrValues config.treefmt.build.programs); + commands = with pkgs; [ + { package = git; } + { package = gitui; } + { package = sops; } + { package = config.treefmt.build.wrapper; } + ]; + }; - pre-commit = { - check.enable = false; - settings = { - hooks = { - treefmt.enable = true; - treefmt.package = config.treefmt.build.wrapper; - deadnix.enable = true; + treefmt = { + projectRootFile = ./flake.nix; + programs = { + nixpkgs-fmt.enable = true; }; }; - }; # end of pre-commit - }; # end of perSystem + + pre-commit = { + check.enable = false; + settings = { + hooks = { + treefmt.enable = true; + treefmt.package = config.treefmt.build.wrapper; + deadnix.enable = true; + }; + }; + }; # end of pre-commit + }; # end of perSystem }; # end of inputs.flake-parts.lib.mkFlake } diff --git a/share/hm-modules/hyprdesktop.nix b/share/hm-modules/hyprdesktop.nix index c6d103a..3bf1c62 100644 --- a/share/hm-modules/hyprdesktop.nix +++ b/share/hm-modules/hyprdesktop.nix @@ -94,6 +94,7 @@ in wget pup oil + xdg-utils # TUI/GUI programs cmus # music player @@ -192,6 +193,7 @@ in music = "${annex}/Music"; documents = "${annex}/Documents"; }; + portal.xdgOpenUsePortal = true; }; gtk = { -- cgit v1.3.1