reorganize "hosts/" into "users/"

the plan here is a user owns one or multiple machines:

users/
+-- chloe/
|   +-- home.nix               # apply to all
|   +-- sandwich/
|   |   +-- configuration.nix  # per machine
|   |   +-- home.nix
|   +-- paperback/
|       ...
+-- natalie/
    ...
This commit is contained in:
chloe caruso 2025-05-05 19:05:37 -07:00
parent 8cf0abc715
commit 24d8eeb413
11 changed files with 61 additions and 4 deletions

BIN
.DS_Store vendored

Binary file not shown.

View file

@ -120,7 +120,7 @@
# natalie's desktop computer
nixosConfigurations.nixos = mkSystem "nixos" {
userSettings = users.nmarks;
configDir = ./hosts/desktop;
configDir = ./hosts/natalie/desktop;
system = "x86_64-linux";
extraModules = [
nixos-cosmic.nixosModules.default
@ -129,20 +129,20 @@
# natalie's laptop
darwinConfigurations."Natalies-MacBook-Air" = mkSystem "Natalies-MacBook-Air" {
userSettings = users.nmarks;
configDir = ./hosts/laptop;
configDir = ./hosts/natalie/laptop;
system = "aarch64-darwin";
};
# chloe's mac studio "sandwich"
darwinConfigurations.sandwich = mkSystem "sandwich" {
userSettings = users.paper_clover;
configDir = ./hosts/laptop;
configDir = ./hosts/chloe;
system = "aarch64-darwin";
};
# chloe's macbook air "paperback"
darwinConfigurations.paperback = mkSystem "paperback" {
userSettings = users.paper_clover;
configDir = ./hosts/laptop;
configDir = ./hosts/chloe;
system = "aarch64-darwin";
};
};

BIN
hosts/.DS_Store vendored

Binary file not shown.

BIN
hosts/laptop/.DS_Store vendored

Binary file not shown.

View file

@ -0,0 +1,28 @@
{
pkgs,
userSettings,
...
}: {
environment.systemPackages = with pkgs; [
neovim
pinentry_mac
signal-desktop-bin
];
# Create /etc/zshrc that loads the nix-darwin environment.
programs = {
gnupg.agent.enable = true;
zsh.enable = true; # default shell on catalina
};
# When opening an interactive shell that isnt fish move into fish
programs.zsh = {
interactiveShellInit = ''
if [[ $(${pkgs.procps}/bin/ps -p $PPID -o comm) != "fish" && -z ''${ZSH_EXUCTION_STRING} ]]
then
[[ -o login ]] && LOGIN_OPTION='--login' || LOGIN_OPTION=""
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
fi
'';
};
}

View file

@ -0,0 +1,29 @@
{
inputs,
config,
pkgs,
lib,
userSettings,
systemSettings,
...
}: {
imports = [
inputs.nixvim.homeManagerModules.nixvim
#set up nixvim
# ../../modules/nixvim
];
programs = import ../../modules/shared/homeManagerPrograms.nix {inherit inputs config pkgs lib userSettings systemSettings;};
home = {
inherit (userSettings) username;
# homeDirectory = systemSettings.homeConfig;
# shell = pkgs.fish;
stateVersion = "23.05"; # Please read the comment before changing.
packages = pkgs.callPackage ../../modules/shared/packages.nix {inherit systemSettings;};
sessionPath = [
"$HOME/.emacs.d/bin"
];
};
}