Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [[machinename.nix]]
- {pkgs, lib, ...}:
- with lib;
- {
- imports = [ ./home.nix];
- options = {
- host = mkOption {
- hostname = mkOption {
- type = types.string;
- default = "";
- description = ''
- Hostname used to differ between configurations of different machienes
- '';
- };
- };
- };
- host.hostname = "machinename";
- }
- [[home.nix]]
- { config, pkgs, ... }:
- with import <nixpkgs> {};
- with builtins;
- with lib;
- with import <home-manager/modules/lib/dag.nix> { inherit lib; };
- {
- home.packages = if host.hostname == "machinename" then [ htop] else [];
- }
- [[command to build homemanager configuration]]
- home-manager -f ~/experimentdir/machinename.nix switch
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement