major fix macos
This commit is contained in:
+4
-1
@@ -1,5 +1,8 @@
|
|||||||
{
|
{
|
||||||
myConfig = {
|
myConfig = {
|
||||||
|
macos = {
|
||||||
|
Username = "lsoriano";
|
||||||
|
};
|
||||||
essentials = {
|
essentials = {
|
||||||
# !!! replace it with your own, else system might malfunction.
|
# !!! replace it with your own, else system might malfunction.
|
||||||
Username = "kenji";
|
Username = "kenji";
|
||||||
@@ -65,7 +68,7 @@
|
|||||||
sshUser = "";
|
sshUser = "";
|
||||||
sshKey = "";
|
sshKey = "";
|
||||||
system = "";
|
system = "";
|
||||||
supportedFeatures = ["big-parallel" "kvm" "nixos-test"];
|
supportedFeatures = ["apple-virt" "big-parallel" "kvm" "nixos-test"];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -11,8 +11,10 @@
|
|||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
hyprland.url = "github:hyprwm/Hyprland";
|
hyprland = {
|
||||||
hyprland.inputs.nixpkgs.follows = "nixpkgs";
|
url = "github:hyprwm/Hyprland";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
@@ -37,66 +39,55 @@
|
|||||||
home-manager,
|
home-manager,
|
||||||
darwin,
|
darwin,
|
||||||
chaotic,
|
chaotic,
|
||||||
nixovim,
|
|
||||||
jovian,
|
jovian,
|
||||||
...
|
...
|
||||||
} @ inputs: let
|
} @ inputs: let
|
||||||
config = import ./config.nix;
|
config = import ./config.nix;
|
||||||
|
system = "x86_64-linux";
|
||||||
mkArgs = system:
|
args =
|
||||||
{
|
{
|
||||||
inherit inputs system;
|
inherit inputs system;
|
||||||
}
|
}
|
||||||
// config;
|
// config;
|
||||||
|
in {
|
||||||
systems = ["x86_64-linux" "aarch64-linux"];
|
nixosConfigurations = {
|
||||||
in
|
hakase = nixpkgs.lib.nixosSystem {
|
||||||
flake-utils.lib.eachSystem systems (system: let
|
specialArgs = args;
|
||||||
pkgs = import nixpkgs {
|
modules = [
|
||||||
inherit system;
|
chaotic.nixosModules.default
|
||||||
config.allowUnfree = true;
|
home-manager.nixosModules.home-manager
|
||||||
};
|
jovian.nixosModules.default
|
||||||
args = mkArgs system;
|
./hosts/hakase/configuration.nix
|
||||||
in {
|
];
|
||||||
})
|
|
||||||
// {
|
|
||||||
nixosConfigurations = {
|
|
||||||
hakase = nixpkgs.lib.nixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
specialArgs = mkArgs "x86_64-linux";
|
|
||||||
modules = [
|
|
||||||
chaotic.nixosModules.default
|
|
||||||
home-manager.nixosModules.home-manager
|
|
||||||
jovian.nixosModules.default
|
|
||||||
nixovim.nixosModules.default
|
|
||||||
./hosts/hakase/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
homeConfigurations = {
|
|
||||||
hakase = home-manager.lib.homeManagerConfiguration {
|
|
||||||
pkgs = import nixpkgs {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
config.allowUnfree = true;
|
|
||||||
extraSpecialArgs = mkArgs "x86_64-linux";
|
|
||||||
};
|
|
||||||
modules = [
|
|
||||||
home-manager.nixosModules.home-manager
|
|
||||||
./home/hakase.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
darwinConfigurations = {
|
|
||||||
macos = darwin.lib.darwinSystem {
|
|
||||||
system = "aarch64-darwin";
|
|
||||||
specialArgs = mkArgs "aarch64-darwin";
|
|
||||||
modules = [
|
|
||||||
home-manager.darwinModules.home-manager
|
|
||||||
./hosts/macos/darwin.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
homeConfigurations = {
|
||||||
|
hakase = home-manager.lib.homeManagerConfiguration {
|
||||||
|
pkgs = import nixpkgs {
|
||||||
|
config.allowUnfree = true;
|
||||||
|
extraSpecialArgs = args;
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
./home/hakase.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
darwinConfigurations = {
|
||||||
|
macos = darwin.lib.darwinSystem {
|
||||||
|
system = "aarch64-darwin";
|
||||||
|
specialArgs =
|
||||||
|
{
|
||||||
|
inherit inputs;
|
||||||
|
system = "aarch64-darwin";
|
||||||
|
}
|
||||||
|
// config;
|
||||||
|
modules = [
|
||||||
|
home-manager.darwinModules.home-manager
|
||||||
|
./hosts/macos/darwin.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
+7
-19
@@ -3,44 +3,32 @@
|
|||||||
myConfig,
|
myConfig,
|
||||||
inputs,
|
inputs,
|
||||||
system,
|
system,
|
||||||
mkArgs,
|
specialArgs,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
imports = [
|
imports = [
|
||||||
../../modules/default/darwin.nix
|
../../modules/default/darwin.nix
|
||||||
];
|
];
|
||||||
# List packages installed in system profile. To search by name, run:
|
|
||||||
# $ nix-env -qaP | grep wget
|
|
||||||
environment.systemPackages = [];
|
environment.systemPackages = [];
|
||||||
|
|
||||||
# Auto upgrade nix package and the daemon service.
|
|
||||||
# services.nix-daemon.enable = true;
|
|
||||||
# services.karabiner-elements.enable = true;
|
|
||||||
# nix.package = pkgs.nix;
|
|
||||||
|
|
||||||
# Necessary for using flakes on this system.
|
|
||||||
nix.settings.experimental-features = "nix-command flakes";
|
nix.settings.experimental-features = "nix-command flakes";
|
||||||
nix.settings.trusted-users = myConfig.optionals.Builds.trustedUsers;
|
# nix.settings.trusted-users = myConfig.optionals.Builds.trustedUsers;
|
||||||
|
|
||||||
# Create /etc/zshrc that loads the nix-darwin environment.
|
|
||||||
programs.zsh.enable = true; # default shell on catalina
|
programs.zsh.enable = true; # default shell on catalina
|
||||||
programs.fish.enable = true;
|
programs.fish.enable = true;
|
||||||
|
|
||||||
# $ darwin-rebuild changelog
|
|
||||||
system.stateVersion = 5;
|
system.stateVersion = 5;
|
||||||
|
|
||||||
# The platform the configuration will be used on.
|
|
||||||
nixpkgs.hostPlatform = "aarch64-darwin";
|
nixpkgs.hostPlatform = "aarch64-darwin";
|
||||||
security.pam.services.sudo_local.touchIdAuth = true;
|
security.pam.services.sudo_local.touchIdAuth = true;
|
||||||
|
|
||||||
users.users.${myConfig.essentials.Username} = {
|
users.users.${myConfig.macos.Username} = {
|
||||||
name = "${myConfig.essentials.Username}";
|
name = "${myConfig.macos.Username}";
|
||||||
home = "/Users/${myConfig.essentials.Username}";
|
home = "/Users/${myConfig.macos.Username}";
|
||||||
# shell = pkgs.${myConfig.general.terminal.Shell}; # no support for nix-darwin, but can be changed via chsh.
|
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
home-manager.extraSpecialArgs = mkArgs system;
|
home-manager.extraSpecialArgs = specialArgs;
|
||||||
home-manager.users.${myConfig.essentials.Username} = import ../../home/darwin.nix;
|
home-manager.users.${myConfig.macos.Username} = import ../../home/darwin.nix;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
../../packages/python/default.nix
|
../../packages/python/default.nix
|
||||||
../../packages/virtualbox/default.nix
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user