forked from Bun/nixos-config
Generalize some more files, make hidden use Intel microcode and not AMD
This commit is contained in:
parent
2e483af205
commit
3f257e006c
8 changed files with 31 additions and 16 deletions
|
@ -18,5 +18,5 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,18 +1,14 @@
|
||||||
{ config, lib, ... }:
|
{ lib, ... }:
|
||||||
{
|
{
|
||||||
options.home = with lib; {
|
imports = [
|
||||||
guifull.enable = mkEnableOption "Enable most other GUI profiles";
|
./generic
|
||||||
|
./guifull
|
||||||
|
];
|
||||||
|
|
||||||
|
options.home = with lib; {
|
||||||
desktop.enable = mkEnableOption "Desktop programs and services";
|
desktop.enable = mkEnableOption "Desktop programs and services";
|
||||||
gaming.enable = mkEnableOption "Gaming apps and programs";
|
gaming.enable = mkEnableOption "Gaming apps and programs";
|
||||||
production.enable = mkEnableOption "Apps for visual productivity";
|
production.enable = mkEnableOption "Apps for visual productivity";
|
||||||
|
|
||||||
school.enable = mkEnableOption "Apps for school and college";
|
school.enable = mkEnableOption "Apps for school and college";
|
||||||
};
|
};
|
||||||
|
|
||||||
config.home = lib.mkIf config.home.guifull.enable {
|
|
||||||
desktop.enable = true;
|
|
||||||
gaming.enable = true;
|
|
||||||
production.enable = true;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
8
modules/home/profiles/generic/default.nix
Normal file
8
modules/home/profiles/generic/default.nix
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
{
|
||||||
|
config = lib.mkIf config.targets.genericLinux.enable {
|
||||||
|
home = {
|
||||||
|
sessionVariables.PATH = "$HOME/.nix-profile/bin:$PATH";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
12
modules/home/profiles/guifull/default.nix
Normal file
12
modules/home/profiles/guifull/default.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
{
|
||||||
|
options.home = with lib; {
|
||||||
|
guifull.enable = mkEnableOption "Enable most other GUI profiles";
|
||||||
|
};
|
||||||
|
|
||||||
|
config.home = lib.mkIf config.home.guifull.enable {
|
||||||
|
desktop.enable = true;
|
||||||
|
gaming.enable = true;
|
||||||
|
production.enable = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -3,8 +3,7 @@
|
||||||
imports = [ impermanence.homeManagerModules.default ];
|
imports = [ impermanence.homeManagerModules.default ];
|
||||||
|
|
||||||
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}" = {
|
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}" = {
|
||||||
enable = true;
|
enable = !config.targets.genericLinux.enable;
|
||||||
allowOther = if !config.targets.genericLinux.enable then true else false;
|
|
||||||
removePrefixDirectory = true;
|
removePrefixDirectory = true;
|
||||||
directories = let
|
directories = let
|
||||||
home = config.home.homeDirectory;
|
home = config.home.homeDirectory;
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
nix = {
|
nix = {
|
||||||
package = lib.mkForce pkgs.lix;
|
package = lib.mkForce pkgs.nix;
|
||||||
settings.experimental-features = [
|
settings.experimental-features = [
|
||||||
"flakes"
|
"flakes"
|
||||||
"nix-command"
|
"nix-command"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
nixGL = lib.mkIf config.targets.genericLinux.enable {
|
nixGL = {
|
||||||
installScripts = [
|
installScripts = [
|
||||||
"mesa"
|
"mesa"
|
||||||
"nvidia"
|
"nvidia"
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
XDG_GAMES_DIR = "${homeDirectory}/Games";
|
XDG_GAMES_DIR = "${homeDirectory}/Games";
|
||||||
XDG_KEEPERS_DIR = "${homeDirectory}/Keepers";
|
XDG_KEEPERS_DIR = "${homeDirectory}/Keepers";
|
||||||
XDG_NETWORK_DIR = "${homeDirectory}/Network";
|
XDG_NETWORK_DIR = "${homeDirectory}/Network";
|
||||||
XDG_PERSIST_DIR = if !config.targets.genericLinux.enable then "/persist${homeDirectory}" else "${homeDirectory}/.stow";
|
XDG_PERSIST_DIR = "/persist${homeDirectory}";
|
||||||
XDG_PROJECTS_DIR = "${homeDirectory}/Projects";
|
XDG_PROJECTS_DIR = "${homeDirectory}/Projects";
|
||||||
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue