feat(home): Set up base home
This commit is contained in:
parent
577bce9d3a
commit
cf7f94d270
3 changed files with 41 additions and 67 deletions
|
@ -1,8 +1,15 @@
|
||||||
{ namespace, lib, ... }:
|
{
|
||||||
|
lib,
|
||||||
|
namespace,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
inherit (lib.${namespace}) enabled;
|
inherit (lib.${namespace}) enabled;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
# Anything in this folder should not include an enable/disable option. This is
|
||||||
|
# the only folder that is always applied.
|
||||||
config = {
|
config = {
|
||||||
${namespace}.my = {
|
${namespace}.my = {
|
||||||
name = "marley";
|
name = "marley";
|
||||||
|
@ -11,6 +18,18 @@ in
|
||||||
email = "marley@punkfairie.net";
|
email = "marley@punkfairie.net";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Tell nix what version it is.
|
||||||
|
nix.package = pkgs.nix;
|
||||||
|
|
||||||
|
home.language.base = "en_US.UTF-8";
|
||||||
|
|
||||||
programs.home-manager = enabled;
|
programs.home-manager = enabled;
|
||||||
|
|
||||||
|
# Autostart wanted systemd services.
|
||||||
|
systemd.user.startServices = true;
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./nix.nix
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
21
modules/home/base/nix.nix
Normal file
21
modules/home/base/nix.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{ _ }:
|
||||||
|
{
|
||||||
|
config = {
|
||||||
|
nix = {
|
||||||
|
# Enable flakes.
|
||||||
|
settings.experimental-features = [
|
||||||
|
"nix-command"
|
||||||
|
"flakes"
|
||||||
|
];
|
||||||
|
|
||||||
|
# Disable that annoying "git tree is dirty" warning.
|
||||||
|
extraOptions = ''
|
||||||
|
warn-dirty = false
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Garbage collection.
|
||||||
|
gc.automatic = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,66 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
me = {
|
|
||||||
username = "punkfairie";
|
|
||||||
email = "marley@punkfairie.net";
|
|
||||||
};
|
|
||||||
|
|
||||||
targets.genericLinux.enable = lib.mkIf pkgs.stdenv.isLinux true;
|
|
||||||
|
|
||||||
home.language.base = "en_US.UTF-8";
|
|
||||||
|
|
||||||
# Tell nix what version it is.
|
|
||||||
nix.package = pkgs.nix;
|
|
||||||
|
|
||||||
nix = {
|
|
||||||
# Enable flakes.
|
|
||||||
settings.experimental-features = [
|
|
||||||
"nix-command"
|
|
||||||
"flakes"
|
|
||||||
];
|
|
||||||
|
|
||||||
# Disable that annoying "git tree is dirty" warning.
|
|
||||||
extraOptions = ''
|
|
||||||
warn-dirty = false
|
|
||||||
'';
|
|
||||||
|
|
||||||
# Garbage collection.
|
|
||||||
gc.automatic = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg.configFile."nixpkgs/config.nix".text = # nix
|
|
||||||
''
|
|
||||||
{
|
|
||||||
allowUnfree = true;
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
|
|
||||||
# Autostart wanted systemd services.
|
|
||||||
systemd.user.startServices = true;
|
|
||||||
|
|
||||||
imports = [
|
|
||||||
./appearance
|
|
||||||
./languages
|
|
||||||
./profile
|
|
||||||
./programs
|
|
||||||
./services
|
|
||||||
./xorg
|
|
||||||
];
|
|
||||||
|
|
||||||
# This value determines the Home Manager release that your configuration is
|
|
||||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
|
||||||
# introduces backwards incompatible changes.
|
|
||||||
#
|
|
||||||
# You should not change this value, even if you update Home Manager. If you do
|
|
||||||
# want to update the value, then make sure to first check the Home Manager
|
|
||||||
# release notes.
|
|
||||||
# home.stateVersion = "24.05"; # Please read the comment before changing.
|
|
||||||
# ((this is set in flake.nix but I wanted to keep the explanation here.))
|
|
||||||
|
|
||||||
# Let home Manager install and manage itself.
|
|
||||||
programs.home-manager.enable = true;
|
|
||||||
}
|
|
Loading…
Reference in a new issue