2022-05-06 03:01:56 +00:00
|
|
|
{ config, lib, pkgs, ... }: {
|
2022-05-02 03:39:50 +00:00
|
|
|
|
2022-05-22 23:43:46 +00:00
|
|
|
imports = [
|
|
|
|
../modules/hardware
|
|
|
|
../modules/system
|
|
|
|
../modules/graphical
|
|
|
|
../modules/shell
|
|
|
|
../modules/gaming
|
|
|
|
../modules/applications
|
|
|
|
../modules/editor
|
|
|
|
../modules/mail/himalaya.nix
|
|
|
|
];
|
2022-05-02 03:39:50 +00:00
|
|
|
|
2022-05-29 17:44:45 +00:00
|
|
|
options = with lib; {
|
|
|
|
dotfilesPath = mkOption {
|
|
|
|
type = types.path;
|
|
|
|
description = "Path of dotfiles repository.";
|
|
|
|
default = builtins.toPath "/home/${config.user}/dev/personal/dotfiles";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2022-05-22 23:43:46 +00:00
|
|
|
config = {
|
2022-05-02 03:39:50 +00:00
|
|
|
|
2022-05-29 17:44:45 +00:00
|
|
|
# Enable features in Nix commands
|
2022-05-22 23:43:46 +00:00
|
|
|
nix.extraOptions = "experimental-features = nix-command flakes";
|
|
|
|
|
2022-05-29 17:44:45 +00:00
|
|
|
# Basic common system packages for all devices
|
|
|
|
environment.systemPackages = with pkgs; [ git vim wget curl ];
|
|
|
|
|
|
|
|
# Use the system-level nixpkgs instead of Home Manager's
|
2022-05-22 23:43:46 +00:00
|
|
|
home-manager.useGlobalPkgs = true;
|
2022-05-29 17:44:45 +00:00
|
|
|
|
|
|
|
# Install packages to /etc/profiles instead of ~/.nix-profile, useful when
|
|
|
|
# using multiple profiles
|
2022-05-22 23:43:46 +00:00
|
|
|
home-manager.useUserPackages = true;
|
|
|
|
|
2022-05-29 17:44:45 +00:00
|
|
|
# Set a variable for dotfiles repo, not necessary but convenient
|
|
|
|
home-manager.users.${config.user} = {
|
|
|
|
home.sessionVariables = { DOTS = config.dotfilesPath; };
|
|
|
|
};
|
2022-05-22 23:43:46 +00:00
|
|
|
|
|
|
|
};
|
2022-05-02 03:39:50 +00:00
|
|
|
|
|
|
|
}
|