nixos-config/.my_old_dotfiles/backups/.dotfiles/imported_files/flake.nix
2024-07-17 16:50:35 +02:00

37 lines
1.2 KiB
Nix
Executable file

{
description = "My first flake!";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; # which is the branch. You should use the last version or the unstable
home-manager.url = "github:nix-community/home-manager/master"; # master == unstable
home-manager.inputs.nixpkgs.follows = "nixpkgs"; # check that versions of nixpkgs and flake? are equal
}; # git links
outputs = { self, nixpkgs, home-manager, ... }:
let
lib = nixpkgs.lib; # we pass lib to be able to use ie: lib.nixosSystem and others
system = "x86_64-linux";
pkgs = nixpkgs.legacyPackages.${system};
in {
nixosConfigurations = {
nixosaku = lib.nixosSystem { # nixosaku to match the hostname
inherit system;
modules = [ ./configuration.nix ];
};
};
homeConfigurations = {
akunito = home-manager.lib.homeManagerConfiguration { # akunito to match the username
inherit pkgs;
modules = [ ./home.nix ];
};
};
# # Exceptions
# nixpkgs.config = {
# allowUnfree = true;
# permittedInsecurePackages = pkgs.lib.optional (pkgs.obsidian.version == "1.5.12") "electron-25.9.0";
# };
};
}