-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathflake.nix
88 lines (80 loc) · 2.54 KB
/
flake.nix
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
{
# This file is mainly for setting up overarching configuration
# like which repositories to use as sources and which architectures to build
# the configuration for the systems themselves is handled in the hosts directory
description = "Soxyn configuration";
outputs = inputs:
inputs.flake-parts.lib.mkFlake {inherit inputs;} {
systems = ["x86_64-linux"];
# this is the meat and potatoes here, imports ./hosts/default.nix where all the hosts are defined
flake = {
nixosConfigurations = import ./hosts inputs;
};
# this is a bit of extra config for packages, formatting and a devShell
perSystem = {
config,
system,
pkgs,
inputs',
...
}: {
legacyPackages = import inputs.nixpkgs {
config.allowUnfree = true;
config.allowUnsupportedSystem = true;
inherit system;
};
imports = [{_module.args.pkgs = config.legacyPackages;}];
devShells.default = pkgs.mkShell {
name = "soxyn";
packages = with pkgs; [
# basics -- should already be available on systems running soxyn
nix
home-manager
git
# nix lsp and formatting
nil
alejandra
# secrets management
inputs'.agenix.packages.default
# packages for ags development
bun
nodePackages.typescript
nodePackages.typescript-language-server
];
NIX_CONFIG = "extra-experimental-features = nix-command flakes";
DIRENV_LOG_FORMAT = "";
};
formatter = pkgs.alejandra;
};
};
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixos-hardware.url = "github:nixos/nixos-hardware";
nur.url = "github:nix-community/NUR";
agenix = {
url = "github:ryantm/agenix";
inputs.nixpkgs.follows = "nixpkgs";
inputs.darwin.follows = "";
};
ags = {
url = "github:Aylur/ags/v1";
inputs.nixpkgs.follows = "nixpkgs";
};
flake-parts = {
url = "github:hercules-ci/flake-parts";
inputs.nixpkgs-lib.follows = "nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
spicetify = {
url = "github:Gerg-L/spicetify-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
umu = {
url = "github:Open-Wine-Components/umu-launcher?dir=packaging/nix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
}