2024-01-03 22:53:34 -03:00
|
|
|
{
|
|
|
|
|
description = "Nixos config flake";
|
|
|
|
|
|
|
|
|
|
inputs = {
|
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
|
|
|
|
|
|
|
|
home-manager = {
|
|
|
|
|
url = "github:nix-community/home-manager";
|
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
|
};
|
|
|
|
|
|
2024-01-06 22:06:26 -03:00
|
|
|
# Declaratively install flatpaks
|
2024-01-09 16:52:28 -03:00
|
|
|
flatpaks.url = "github:gmodena/nix-flatpak"; # Fork is being used until #24 merges
|
|
|
|
|
# flatpaks.url = "github:Tomaszal/nix-flatpak/feature/overrides";
|
2024-01-05 19:49:31 -03:00
|
|
|
|
|
|
|
|
# Used for theming the OS, see modules/home-manager/theme.nix
|
|
|
|
|
nix-colors.url = "github:misterio77/nix-colors";
|
|
|
|
|
|
2024-01-05 19:49:55 -03:00
|
|
|
# Necessary for modules/home-manager/programs/tmux.nix
|
|
|
|
|
tmux-plugin-manager = {
|
|
|
|
|
url = "github:tmux-plugins/tpm";
|
|
|
|
|
flake = false;
|
|
|
|
|
};
|
2024-01-03 22:53:34 -03:00
|
|
|
};
|
|
|
|
|
|
2024-01-07 15:45:18 -03:00
|
|
|
outputs = { self, nixpkgs, home-manager, ... }@inputs:
|
|
|
|
|
let
|
|
|
|
|
create-host = (configs: builtins.listToAttrs (map
|
|
|
|
|
(c: {
|
|
|
|
|
name = c;
|
|
|
|
|
value = nixpkgs.lib.nixosSystem {
|
|
|
|
|
specialArgs = { inherit inputs; };
|
|
|
|
|
modules = [
|
|
|
|
|
inputs.home-manager.nixosModules.default
|
|
|
|
|
(./. + ("/hosts/" + builtins.replaceStrings [ "@" ] [ "/" ] c) + /configuration.nix)
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
})
|
|
|
|
|
configs));
|
|
|
|
|
in
|
|
|
|
|
{
|
|
|
|
|
nixosConfigurations = (create-host [
|
|
|
|
|
"desktop@default"
|
|
|
|
|
"desktop@work"
|
|
|
|
|
]);
|
2024-01-03 22:53:34 -03:00
|
|
|
};
|
|
|
|
|
}
|
2024-01-07 15:45:18 -03:00
|
|
|
|