summaryrefslogtreecommitdiff
path: root/users/seth/custom/standalone.nix
diff options
context:
space:
mode:
Diffstat (limited to 'users/seth/custom/standalone.nix')
-rw-r--r--users/seth/custom/standalone.nix36
1 files changed, 36 insertions, 0 deletions
diff --git a/users/seth/custom/standalone.nix b/users/seth/custom/standalone.nix
new file mode 100644
index 0000000..6bb85a1
--- /dev/null
+++ b/users/seth/custom/standalone.nix
@@ -0,0 +1,36 @@
+{
+ config,
+ lib,
+ pkgs,
+ ...
+}:
+
+let
+ cfg = config.seth.standalone;
+
+ inherit (pkgs.stdenv.hostPlatform) isDarwin;
+in
+
+{
+
+ options.seth.standalone = {
+ enable = lib.mkEnableOption "standalone configuration mode";
+ };
+
+ config = lib.mkIf cfg.enable {
+ # This won't be set in standalone configurations
+ _module.args.osConfig = { };
+
+ # Make sure we can switch & update
+ programs.home-manager.enable = true;
+
+ home = {
+ username = "seth";
+ homeDirectory = (if isDarwin then "/Users" else "/home") + "/${config.home.username}";
+ };
+
+ nix = {
+ package = lib.mkDefault pkgs.nix;
+ };
+ };
+}