-
Notifications
You must be signed in to change notification settings - Fork 73
Expand file tree
/
Copy pathflake.nix
More file actions
68 lines (60 loc) · 1.74 KB
/
flake.nix
File metadata and controls
68 lines (60 loc) · 1.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
{
description = "Ambxst - An Axtremely customizable shell by Axenide";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
axctl = {
url = "github:Axenide/axctl";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs, axctl, ... }:
let
ambxstLib = import ./nix/lib.nix { inherit nixpkgs; };
in {
nixosModules.default = { pkgs, lib, ... }: {
imports = [ ./nix/modules ];
programs.ambxst.enable = lib.mkDefault true;
programs.ambxst.package = lib.mkDefault self.packages.${pkgs.system}.default;
};
packages = ambxstLib.forAllSystems (system:
let
pkgs = import nixpkgs {
inherit system;
config.allowUnfree = true;
};
lib = nixpkgs.lib;
Ambxst = import ./nix/packages {
inherit pkgs lib self system axctl;
};
in {
default = Ambxst;
Ambxst = Ambxst;
}
);
devShells = ambxstLib.forAllSystems (system:
let
pkgs = import nixpkgs { inherit system; };
Ambxst = self.packages.${system}.default;
in {
default = pkgs.mkShell {
packages = [ Ambxst ];
shellHook = ''
export QML2_IMPORT_PATH="${Ambxst}/lib/qt-6/qml:$QML2_IMPORT_PATH"
export QML_IMPORT_PATH="$QML2_IMPORT_PATH"
echo "Ambxst dev environment loaded."
'';
};
}
);
apps = ambxstLib.forAllSystems (system:
let
Ambxst = self.packages.${system}.default;
in {
default = {
type = "app";
program = "${Ambxst}/bin/ambxst";
};
}
);
};
}