Skip to content

Instantly share code, notes, and snippets.

@chaoflow
Created July 27, 2023 09:37
Show Gist options
  • Save chaoflow/86368138b2519ecfee081bf38e557697 to your computer and use it in GitHub Desktop.
Save chaoflow/86368138b2519ecfee081bf38e557697 to your computer and use it in GitHub Desktop.
{
inputs = {
# emacs.url = github:nix-community/emacs-overlay;
nixpkgs.url = github:NixOS/nixpkgs/nixos-23.05;
nixpkgs-unstable.url = github:NixOS/nixpkgs/nixos-unstable;
nixos-hardware.url = github:NixOS/nixos-hardware;
# home-manager.url = github:nix-community/home-manager;
};
outputs = {
self,
# emacs,
nixpkgs,
nixpkgs-unstable,
nixos-hardware,
...
} @ attrs: let
system = "x86_64-linux";
overlay-unstable = final: prev: {
# same without unfree
# unstable = nixpkgs-unstable.legacyPackages.${prev.system};
unstable = import nixpkgs-unstable {
inherit system;
config.allowUnfree = true;
};
};
in {
nixosConfigurations.xin = nixpkgs.lib.nixosSystem {
inherit system;
specialArgs = attrs;
modules = [
nixos-hardware.nixosModules.lenovo-thinkpad-p14s-amd-gen2
({
config,
pkgs,
...
}: {
nixpkgs.overlays = [
# emacs.overlay
overlay-unstable
];
})
./configuration.nix
];
};
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment