refactor: organize hosts configs into dedicated directory
- Move and rename host-specific configurations (e.g., wsl to hosts/wsl) - Add home.nix files for mbp and wsl, importing common modules - Update mbp flake.nix path to new hosts/mbp/configuration.nix - Integrate home-manager for user environments on macOS/WSL - Update flake.lock inputs (nixpkgs, home-manager, homebrew) for latest versions - Add README.md with project overview and setup instructions This restructures the repo for multi-host support, improves modularity, and ensures reproducible builds with updated dependencies.
This commit is contained in:
parent
42b2706505
commit
665a701aaa
21 changed files with 331 additions and 418 deletions
31
modules/common.nix
Normal file
31
modules/common.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{ pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
# Define home options directly if this is a standalone home.nix
|
||||
# or within config if it's a module
|
||||
home = {
|
||||
packages = with pkgs; [
|
||||
age
|
||||
ansible
|
||||
bat
|
||||
deploy-rs
|
||||
fzf-preview
|
||||
kubectl
|
||||
kubectx
|
||||
kubernetes-helm
|
||||
nerd-fonts.jetbrains-mono
|
||||
nixfmt-rfc-style
|
||||
opentofu
|
||||
sops
|
||||
talosctl
|
||||
teleport
|
||||
zsh-forgit
|
||||
zsh-fzf-history-search
|
||||
zsh-fzf-tab
|
||||
rclone
|
||||
];
|
||||
stateVersion = "25.11";
|
||||
};
|
||||
|
||||
#nixpkgs.config.allowUnfree = true; # It's better to put this in configuration.nix or a more specific place if it's only meant for certain hosts.
|
||||
}
|
||||
40
modules/homebrew.nix
Normal file
40
modules/homebrew.nix
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
homebrew = {
|
||||
enable = true;
|
||||
|
||||
onActivation.autoUpdate = true;
|
||||
onActivation.upgrade = true;
|
||||
#onActivation.cleanup = "zap";
|
||||
|
||||
casks = [
|
||||
"arc"
|
||||
"bettermouse"
|
||||
"blender"
|
||||
"citrix-workspace"
|
||||
"cryptomator"
|
||||
"Discord"
|
||||
"Element"
|
||||
"ghostty"
|
||||
"IINA"
|
||||
"Keka"
|
||||
"meta"
|
||||
"mullvad-vpn"
|
||||
"obs"
|
||||
"Obsidian"
|
||||
"orion"
|
||||
"Secretive"
|
||||
"tailscale-app"
|
||||
"telegram"
|
||||
"UTM"
|
||||
"vscodium"
|
||||
];
|
||||
|
||||
masApps = {
|
||||
"Bitwarden" = 1352778147;
|
||||
"DropOver" = 1355679052;
|
||||
"Yubico Authenticator" = 1497506650;
|
||||
};
|
||||
};
|
||||
}
|
||||
7
modules/programs/bat.nix
Normal file
7
modules/programs/bat.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.bat = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
8
modules/programs/eza.nix
Normal file
8
modules/programs/eza.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.eza = {
|
||||
enableZshIntegration = true;
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
35
modules/programs/fzf.nix
Normal file
35
modules/programs/fzf.nix
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.fzf = {
|
||||
colors = {
|
||||
fg = "-1";
|
||||
"fg+" = "#d0d0d0";
|
||||
bg = "-1";
|
||||
"bg+" = "#262626";
|
||||
hl = "#5f87af";
|
||||
"hl+" = "#5fd7ff";
|
||||
info = "#afaf87";
|
||||
marker = "#87ff00";
|
||||
prompt = "#d7005f";
|
||||
spinner = "#af5fff";
|
||||
pointer = "#af5fff";
|
||||
header = "#87afaf";
|
||||
border = "#262626";
|
||||
label = "#aeaeae";
|
||||
query = "#d9d9d9";
|
||||
};
|
||||
defaultOptions = [
|
||||
"--border=rounded"
|
||||
"--border-label"
|
||||
"--preview-window=border-rounded"
|
||||
"--prompt=> "
|
||||
"--marker=>"
|
||||
"--pointer=◆"
|
||||
"--separator=─"
|
||||
"--scrollbar=│"
|
||||
];
|
||||
enableZshIntegration = true;
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
9
modules/programs/git.nix
Normal file
9
modules/programs/git.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "Den Afanasyev";
|
||||
userEmail = "ceo@furry.industries";
|
||||
};
|
||||
}
|
||||
52
modules/programs/k9s.nix
Normal file
52
modules/programs/k9s.nix
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
{
|
||||
programs.k9s = {
|
||||
skins = {
|
||||
transparent = {
|
||||
k9s = {
|
||||
body.bgColor = "default";
|
||||
prompt.bgColor = "default";
|
||||
info.sectionColor = "default";
|
||||
dialog = {
|
||||
bgColor = "default";
|
||||
labelFgColor = "default";
|
||||
fieldFgColor = "default";
|
||||
};
|
||||
frame = {
|
||||
crumbs.bgColor = "default";
|
||||
title = {
|
||||
bgColor = "default";
|
||||
counterColor = "default";
|
||||
};
|
||||
menu.fgColor = "default";
|
||||
};
|
||||
views = {
|
||||
charts.bgColor = "default";
|
||||
table = {
|
||||
bgColor = "default";
|
||||
header = {
|
||||
fgColor = "default";
|
||||
bgColor = "default";
|
||||
};
|
||||
};
|
||||
xray.bgColor = "default";
|
||||
logs = {
|
||||
bgColor = "default";
|
||||
indicator = {
|
||||
bgColor = "default";
|
||||
toggleOnColor = "default";
|
||||
toggleOffColor = "default";
|
||||
};
|
||||
};
|
||||
yaml = {
|
||||
colonColor = "default";
|
||||
valueColor = "default";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
enable = true;
|
||||
|
||||
};
|
||||
}
|
||||
11
modules/programs/micro.nix
Normal file
11
modules/programs/micro.nix
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.micro = {
|
||||
settings = {
|
||||
colorscheme = "simple";
|
||||
scrollbar = true;
|
||||
};
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
8
modules/programs/ssh.nix
Normal file
8
modules/programs/ssh.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.ssh = {
|
||||
enable = true;
|
||||
enableDefaultConfig = false;
|
||||
};
|
||||
}
|
||||
8
modules/programs/zoxide.nix
Normal file
8
modules/programs/zoxide.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.zoxide = {
|
||||
enableZshIntegration = true;
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
53
modules/programs/zsh.nix
Normal file
53
modules/programs/zsh.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
enableCompletion = true;
|
||||
syntaxHighlighting.enable = true;
|
||||
|
||||
prezto = {
|
||||
prompt = { theme = "powerlevel10k"; };
|
||||
enable = true;
|
||||
};
|
||||
|
||||
autosuggestion = {
|
||||
#highlight = "fg=#ff00ff,bg=cyan,bold,underline";
|
||||
#strategy = [ "completion" "history" ];
|
||||
enable = true;
|
||||
};
|
||||
|
||||
plugins = [
|
||||
{
|
||||
name = "fzf-tab";
|
||||
src = "${pkgs.zsh-fzf-tab}/share/fzf-tab";
|
||||
}
|
||||
];
|
||||
|
||||
history = {
|
||||
append = true;
|
||||
expireDuplicatesFirst = true;
|
||||
};
|
||||
|
||||
initContent = lib.mkOrder 500 ''
|
||||
source ~/.p10k.zsh
|
||||
echo "Hey there raccoon! 🦝🍁"
|
||||
'';
|
||||
localVariables = {
|
||||
PURE_GIT_PULL = "0";
|
||||
TELEPORT_ADD_KEYS_TO_AGENT = "no";
|
||||
K9S_SKIN = "transparent";
|
||||
};
|
||||
|
||||
shellAliases = {
|
||||
ls = "eza";
|
||||
cd = "z";
|
||||
cat = "bat";
|
||||
k = "kubectl";
|
||||
m = "micro";
|
||||
h = "helm";
|
||||
tp = "teleport";
|
||||
t = "talosctl";
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue