Split mac-portable module out
This commit is contained in:
@@ -60,8 +60,11 @@
|
||||
);
|
||||
});
|
||||
|
||||
homeModules.main = {
|
||||
imports = [ ./modules/home.nix ];
|
||||
homeModules = {
|
||||
main = import ./modules/home.nix;
|
||||
};
|
||||
darwinModules = {
|
||||
mac-portable = import ./modules/mac-portable.nix;
|
||||
};
|
||||
|
||||
homeConfigurations."artem@deimos" = home-manager.lib.homeManagerConfiguration {
|
||||
@@ -85,6 +88,7 @@
|
||||
system = "x86_64-darwin";
|
||||
specialArgs.primaryUser = "artem";
|
||||
modules = [
|
||||
self.darwinModules.mac-portable
|
||||
inputs.fw_nix.nixosModules.tools
|
||||
inputs.fw_nix.nixosModules.nix-settings
|
||||
inputs.fw_nix.nixosModules.futureware
|
||||
|
||||
@@ -1,62 +1,5 @@
|
||||
{ pkgs, primaryUser, ... }:
|
||||
{
|
||||
nixpkgs.hostPlatform = "x86_64-darwin";
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
system.primaryUser = primaryUser;
|
||||
users.users.${primaryUser} = {
|
||||
home = "/Users/${primaryUser}";
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
|
||||
security.pam.services.sudo_local.touchIdAuth = true;
|
||||
|
||||
system = {
|
||||
startup.chime = false;
|
||||
|
||||
defaults = {
|
||||
loginwindow = {
|
||||
GuestEnabled = false;
|
||||
DisableConsoleAccess = true;
|
||||
};
|
||||
|
||||
finder = {
|
||||
AppleShowAllFiles = true; # hidden files
|
||||
AppleShowAllExtensions = true; # file extensions
|
||||
_FXShowPosixPathInTitle = true; # title bar full path
|
||||
ShowPathbar = true; # breadcrumb nav at bottom
|
||||
ShowStatusBar = true; # file count & disk space
|
||||
};
|
||||
|
||||
NSGlobalDomain = {
|
||||
NSAutomaticSpellingCorrectionEnabled = false;
|
||||
NSAutomaticCapitalizationEnabled = false;
|
||||
NSAutomaticPeriodSubstitutionEnabled = false;
|
||||
NSAutomaticWindowAnimationsEnabled = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Create /etc/zshrc that loads the nix-darwin environment.
|
||||
programs.zsh.enable = true;
|
||||
|
||||
nix-homebrew = {
|
||||
# Initial install of homebrew.
|
||||
enable = true;
|
||||
user = primaryUser;
|
||||
autoMigrate = true;
|
||||
};
|
||||
homebrew = {
|
||||
enable = true;
|
||||
onActivation = {
|
||||
cleanup = "zap";
|
||||
autoUpdate = false;
|
||||
upgrade = true;
|
||||
};
|
||||
casks = [
|
||||
"bambu-studio"
|
||||
];
|
||||
};
|
||||
|
||||
system.stateVersion = 6; # Never change.
|
||||
_: {
|
||||
homebrew.casks = [
|
||||
"bambu-studio"
|
||||
];
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
stow
|
||||
wget
|
||||
gemini-cli
|
||||
silver-searcher
|
||||
];
|
||||
|
||||
programs.zsh = {
|
||||
|
||||
59
modules/mac-portable.nix
Normal file
59
modules/mac-portable.nix
Normal file
@@ -0,0 +1,59 @@
|
||||
{ pkgs, primaryUser, ... }:
|
||||
{
|
||||
nixpkgs.hostPlatform = "x86_64-darwin";
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
system.primaryUser = primaryUser;
|
||||
users.users.${primaryUser} = {
|
||||
home = "/Users/${primaryUser}";
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
|
||||
security.pam.services.sudo_local.touchIdAuth = true;
|
||||
|
||||
system = {
|
||||
startup.chime = false;
|
||||
|
||||
defaults = {
|
||||
loginwindow = {
|
||||
GuestEnabled = false;
|
||||
DisableConsoleAccess = true;
|
||||
};
|
||||
|
||||
finder = {
|
||||
AppleShowAllFiles = true; # hidden files
|
||||
AppleShowAllExtensions = true; # file extensions
|
||||
_FXShowPosixPathInTitle = true; # title bar full path
|
||||
ShowPathbar = true; # breadcrumb nav at bottom
|
||||
ShowStatusBar = true; # file count & disk space
|
||||
};
|
||||
|
||||
NSGlobalDomain = {
|
||||
NSAutomaticSpellingCorrectionEnabled = false;
|
||||
NSAutomaticCapitalizationEnabled = false;
|
||||
NSAutomaticPeriodSubstitutionEnabled = false;
|
||||
NSAutomaticWindowAnimationsEnabled = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Create /etc/zshrc that loads the nix-darwin environment.
|
||||
programs.zsh.enable = true;
|
||||
|
||||
nix-homebrew = {
|
||||
# Initial install of homebrew.
|
||||
enable = true;
|
||||
user = primaryUser;
|
||||
autoMigrate = true;
|
||||
};
|
||||
homebrew = {
|
||||
enable = true;
|
||||
onActivation = {
|
||||
cleanup = "zap";
|
||||
autoUpdate = false;
|
||||
upgrade = true;
|
||||
};
|
||||
};
|
||||
|
||||
system.stateVersion = 6; # Never change.
|
||||
}
|
||||
Reference in New Issue
Block a user