Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 32 additions & 22 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,26 +10,7 @@
};

outputs = inputs: let
packages = inputs.flake-utils.lib.eachDefaultSystem (system: let
flakePackage = flake: package: flake.packages."${system}"."${package}";
flakeDefaultPackage = flake: flakePackage flake "default";

pkgs = import inputs.nixpkgs {
inherit system;
overlays = [
(self: super: {
hyprland = flakeDefaultPackage inputs.hyprland;
})
];
};

# - [Get-flake: builtins.getFlake without the restrictions - Announcements - NixOS Discourse](https://discourse.nixos.org/t/get-flake-builtins-getflake-without-the-restrictions/17662)
# hyprland-flake = import "${inputs.hyprland}/flake.nix";
# hyprland-outputs = hyprland-flake.outputs {
# nixpkgs = inputs.nixpkgs-unstable;
# };
# hyprland-outputs = inputs.hyprland;

packages' = pkgs: let
meta = {
homepage = manifest.repository;
description = manifest.description;
Expand Down Expand Up @@ -106,6 +87,33 @@
echo "This package is a placeholder. See the warning during evaluation." > $out/README.md
'');

stdenv = pkgs.clangStdenv;
in {
inherit hyprkool-rs hyprkool-plugin hyprkool-plugin-dev;
};

packages = inputs.flake-utils.lib.eachDefaultSystem (system: let
flakePackage = flake: package: flake.packages."${system}"."${package}";
flakeDefaultPackage = flake: flakePackage flake "default";

pkgs = import inputs.nixpkgs {
inherit system;
overlays = [
(self: super: {
hyprland = flakeDefaultPackage inputs.hyprland;
})
];
};

inherit (packages' pkgs) hyprkool-rs hyprkool-plugin hyprkool-plugin-dev;

# - [Get-flake: builtins.getFlake without the restrictions - Announcements - NixOS Discourse](https://discourse.nixos.org/t/get-flake-builtins-getflake-without-the-restrictions/17662)
# hyprland-flake = import "${inputs.hyprland}/flake.nix";
# hyprland-outputs = hyprland-flake.outputs {
# nixpkgs = inputs.nixpkgs-unstable;
# };
# hyprland-outputs = inputs.hyprland;

fhs = pkgs.buildFHSEnv {
name = "fhs-shell";
targetPkgs = p: (env-packages p) ++ (custom-commands p);
Expand Down Expand Up @@ -229,7 +237,9 @@
'';
};
});
vm = {
outputs = {
overlays.default = self: _super: packages' self;

nixosConfigurations.test = let
system = "x86_64-linux";
username = "kool";
Expand Down Expand Up @@ -358,5 +368,5 @@
};
};
in
inputs.nixpkgs.lib.attrsets.recursiveUpdate packages vm;
inputs.nixpkgs.lib.attrsets.recursiveUpdate packages outputs;
}