feat: add home-manager + dotfiles via git way (Option 3)

This commit is contained in:
2026-06-14 12:15:48 -04:00
parent 36359de6aa
commit 424e66c78f
3 changed files with 109 additions and 2 deletions

View File

@@ -0,0 +1,12 @@
{ config, pkgs, lib, inputs, ... }:
{
imports = [ inputs.home-manager.nixosModules.home-manager ];
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
users.gortium = import ./dotfiles.nix { inherit config pkgs lib inputs; };
};
}

View File

@@ -0,0 +1,87 @@
{ config, pkgs, lib, inputs, ... }:
{
home = {
username = "gortium";
homeDirectory = "/home/gortium";
stateVersion = "25.11";
};
# Import dotfiles as-is via home.file (Option 3 — git way)
# Hyprland
home.file.".config/hypr/hyprland.conf".source =
"${inputs.dotfiles}/hypr/.config/hypr/hyprland.conf";
home.file.".config/hypr/mocha.conf".source =
"${inputs.dotfiles}/hypr/.config/hypr/mocha.conf";
home.file.".config/hypr/hyprlock.conf".source =
"${inputs.dotfiles}/hypr/.config/hypr/hyprlock.conf";
home.file.".config/hypr/hypridle.conf".source =
"${inputs.dotfiles}/hypr/.config/hypr/hypridle.conf";
home.file.".config/hypr/hyprpaper.conf".source =
"${inputs.dotfiles}/hypr/.config/hypr/hyprpaper.conf";
home.file.".config/hypr/hyprshade.toml".source =
"${inputs.dotfiles}/hypr/.config/hypr/hyprshade.toml";
# Host-specific overrides: sourced from hyprland.conf
# hyprland.conf includes: source = ~/.config/hypr/hosts/$HOST.conf
# This file is created per-host and contains only the diffs.
home.file.".config/hypr/hosts" = {
source = "${inputs.dotfiles}/hypr/.config/hypr/hosts";
recursive = true;
};
# Zsh
home.file.".zshrc".source = "${inputs.dotfiles}/zsh/.zshrc";
# Tmux
home.file.".tmux.conf".source = "${inputs.dotfiles}/tmux/.tmux.conf";
# Neovim
home.file.".config/nvim" = {
source = "${inputs.dotfiles}/nvim/.config/nvim";
recursive = true;
};
# Wallpapers
home.file.".config/wallpapers" = {
source = "${inputs.dotfiles}/wallpapers/.config/wallpapers";
recursive = true;
};
# Wofi
home.file.".config/wofi" = {
source = "${inputs.dotfiles}/wofi/.config/wofi";
recursive = true;
};
# Packages that should be installed with home-manager
home.packages = with pkgs; [
# CLI tools
ripgrep
fd
jq
fzf
bat
eza
zoxide
# Development
git
lazygit
gh
# Hyprland extras
hyprshot
swaync
swww
wofi
waybar
kitty
foot
brightnessctl
playerctl
udiskie
hyprshade
pyprland
];
}