This commit is contained in:
2025-11-01 19:09:24 -05:00
parent ba40661f5e
commit 93e1150a56
15 changed files with 141 additions and 123 deletions

View File

@@ -1,8 +1,17 @@
{ {
pkgs, pkgs,
lib,
config, config,
... ...
}: { }: let
program = "<placeholder>";
cfg = config.dots.${program};
#sec = sops.secrets;
in {
config = lib.mkIf cfg.enable {
programs.${program} = {
enable = true;
};
};
} }

View File

@@ -0,0 +1,15 @@
{
pkgs,
lib,
config,
...
}: let
program = "dunst";
cfg = config.dots.${program};
#sec = sops.secrets;
in {
config = lib.mkIf cfg.enable {
programs.${program} = {
};
};
}

View File

@@ -4,20 +4,16 @@
lib, lib,
inputs, inputs,
... ...
}: }: let
let
program = "git"; program = "git";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
# configure git # configure git
programs.${program} = { programs.${program} = {
enable = true; enable = true;

View File

@@ -3,19 +3,16 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "gpg"; program = "gpg";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
programs.${program} = { programs.${program} = {
enable = true; enable = true;
}; };

View File

@@ -3,20 +3,16 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "hypr"; program = "hypr";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [
nwg-displays nwg-displays
posy-cursors posy-cursors
@@ -221,8 +217,8 @@ in {
services.hyprpaper = { services.hyprpaper = {
enable = true; enable = true;
settings = { settings = {
preload = [ "~/.nix/users/blake/assets/wallpapers/antartica.png" ]; preload = ["~/.nix/users/blake/assets/wallpapers/antartica.png"];
wallpaper = [ ",~/.nix/users/blake/assets/wallpapers/antartica.png" ]; wallpaper = [",~/.nix/users/blake/assets/wallpapers/antartica.png"];
ipc = "off"; ipc = "off";
splash = false; splash = false;
}; };
@@ -306,8 +302,7 @@ in {
inner_color = "$surface0"; inner_color = "$surface0";
font_color = "$text"; font_color = "$text";
fade_on_empty = false; fade_on_empty = false;
placeholder_text = placeholder_text = "# <span foreground=\"##$textAlpha\"><i>󰌾 Logged in as </i><span foreground=\"##$accentAlpha\">$USER</span></span>";
"# <span foreground=\"##$textAlpha\"><i>󰌾 Logged in as </i><span foreground=\"##$accentAlpha\">$USER</span></span>";
hide_input = false; hide_input = false;
check_color = "rgb(0047ab)"; check_color = "rgb(0047ab)";
fail_color = "rgb(ff0000)"; fail_color = "rgb(ff0000)";
@@ -322,7 +317,6 @@ in {
}; };
}; };
# idle daemon # idle daemon
services.hypridle = { services.hypridle = {
enable = true; enable = true;

View File

@@ -3,13 +3,11 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "lf"; program = "lf";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };

View File

@@ -3,13 +3,11 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "librewolf"; program = "librewolf";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };

View File

@@ -4,14 +4,11 @@
lib, lib,
inputs, inputs,
... ...
}: }: let
let
program = "nvf"; program = "nvf";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
@@ -21,8 +18,6 @@ in {
]; ];
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
programs.${program} = { programs.${program} = {
enable = true; enable = true;
settings = { settings = {
@@ -44,13 +39,13 @@ in {
# visual line movement (insert mode) # visual line movement (insert mode)
{ {
key = "<Up>"; key = "<Up>";
mode = [ "i" ]; mode = ["i"];
action = "<C-o>gk"; action = "<C-o>gk";
desc = "Visual Line Up (Insert)"; desc = "Visual Line Up (Insert)";
} }
{ {
key = "<Down>"; key = "<Down>";
mode = [ "i" ]; mode = ["i"];
action = "<C-o>gj"; action = "<C-o>gj";
desc = "Visual Line Down (Insert)"; desc = "Visual Line Down (Insert)";
} }
@@ -82,7 +77,7 @@ in {
{ {
key = "gd"; key = "gd";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.lsp.buf.definition()<CR>"; action = "<cmd>lua vim.lsp.buf.definition()<CR>";
desc = "Go to definition"; desc = "Go to definition";
@@ -90,7 +85,7 @@ in {
# Hover info # Hover info
{ {
key = "K"; key = "K";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.lsp.buf.hover()<CR>"; action = "<cmd>lua vim.lsp.buf.hover()<CR>";
desc = "Hover info"; desc = "Hover info";
@@ -98,7 +93,7 @@ in {
# Format buffer (Alejandra for Nix) # Format buffer (Alejandra for Nix)
{ {
key = "<leader>F"; key = "<leader>F";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.lsp.buf.format({ async = true })<CR>"; action = "<cmd>lua vim.lsp.buf.format({ async = true })<CR>";
desc = "Format buffer"; desc = "Format buffer";
@@ -106,7 +101,7 @@ in {
# Code actions / quickfix # Code actions / quickfix
{ {
key = "<leader>a"; key = "<leader>a";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.lsp.buf.code_action()<CR>"; action = "<cmd>lua vim.lsp.buf.code_action()<CR>";
desc = "Code action"; desc = "Code action";
@@ -114,7 +109,7 @@ in {
# Rename symbol # Rename symbol
{ {
key = "<leader>r"; key = "<leader>r";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.lsp.buf.rename()<CR>"; action = "<cmd>lua vim.lsp.buf.rename()<CR>";
desc = "Rename symbol"; desc = "Rename symbol";
@@ -122,21 +117,21 @@ in {
# Diagnostics # Diagnostics
{ {
key = "<leader>e"; key = "<leader>e";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.diagnostic.open_float()<CR>"; action = "<cmd>lua vim.diagnostic.open_float()<CR>";
desc = "Show diagnostic"; desc = "Show diagnostic";
} }
{ {
key = "[d"; key = "[d";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.diagnostic.goto_prev()<CR>"; action = "<cmd>lua vim.diagnostic.goto_prev()<CR>";
desc = "Previous diagnostic"; desc = "Previous diagnostic";
} }
{ {
key = "]d"; key = "]d";
mode = [ "n" ]; mode = ["n"];
silent = true; silent = true;
action = "<cmd>lua vim.diagnostic.goto_next()<CR>"; action = "<cmd>lua vim.diagnostic.goto_next()<CR>";
desc = "Next diagnostic"; desc = "Next diagnostic";
@@ -193,7 +188,6 @@ in {
markdown.enable = true; markdown.enable = true;
rust.enable = true; rust.enable = true;
lua.enable = true; lua.enable = true;
}; };
}; };
}; };

View File

@@ -3,13 +3,11 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "ssh"; program = "ssh";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
@@ -39,7 +37,6 @@ in {
#home.file.".ssh/id_snowbelle".source = config.lib.file.mkOutOfStoreSymlink /home/blake/.nix/.keyring/ssh/id_snowbelle; #home.file.".ssh/id_snowbelle".source = config.lib.file.mkOutOfStoreSymlink /home/blake/.nix/.keyring/ssh/id_snowbelle;
#home.file.".ssh/id_snowbelle.pub".source = config.lib.file.mkOutOfStoreSymlink /home/blake/.nix/.keyring/ssh/id_snowbelle.pub; #home.file.".ssh/id_snowbelle.pub".source = config.lib.file.mkOutOfStoreSymlink /home/blake/.nix/.keyring/ssh/id_snowbelle.pub;
# manage secrets with sops # manage secrets with sops
sops.secrets = { sops.secrets = {
"id_snowbelle" = { "id_snowbelle" = {

View File

@@ -4,21 +4,16 @@
lib, lib,
inputs, inputs,
... ...
}: }: let
let
program = "stylix"; program = "stylix";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
imports = [inputs.stylix.homeManagerModules.default]; imports = [inputs.stylix.homeManagerModules.default];
}; };
} }

View File

@@ -0,0 +1,36 @@
{
pkgs,
lib,
config,
...
}: let
program = "tofi";
cfg = config.dots.${program};
#sec = sops.secrets;
in {
config = lib.mkIf cfg.enable {
programs.${program} = {
enable = true;
settings = {
anchor = "top";
width = "100%";
height = 25;
horizontal = true;
font-size = 12;
prompt-text = " select: ";
outline-width = 0;
border-width = 0;
corner-radius = 9;
background-color = "#2f1730";
selection-color = "#ffffff";
text-color = "#888888";
min-input-width = 120;
result-spacing = 15;
padding-top = 0;
padding-bottom = 0;
padding-left = 0;
padding-right = 0;
};
};
};
}

View File

@@ -3,20 +3,16 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "waybar"; program = "waybar";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
# just using the normal lfrc # just using the normal lfrc
programs.${program} = { programs.${program} = {
enable = true; enable = true;
@@ -29,8 +25,8 @@ in {
height = 25; height = 25;
margin-top = 0; margin-top = 0;
modules-left = [ "hyprland/workspaces" ]; modules-left = ["hyprland/workspaces"];
modules-center = [ "hyprland/window" ]; modules-center = ["hyprland/window"];
modules-right = [ modules-right = [
"tray" "tray"
"temperature" "temperature"
@@ -92,12 +88,12 @@ in {
backlight = { backlight = {
device = "intel_backlight"; device = "intel_backlight";
format = "{icon} {percent}%"; format = "{icon} {percent}%";
"format-icons" = [ "" "" "" "" ]; "format-icons" = ["" "" "" ""];
interval = 60; interval = 60;
}; };
temperature = { temperature = {
"hwmon-path" = [ "/sys/class/hwmon/hwmon3/temp1_input" ]; "hwmon-path" = ["/sys/class/hwmon/hwmon3/temp1_input"];
"critical-threshold" = 70; "critical-threshold" = 70;
format = ""; format = "";
"format-critical" = " {temperatureC}°C"; "format-critical" = " {temperatureC}°C";
@@ -114,7 +110,7 @@ in {
}; };
format = "{icon} {capacity}%"; format = "{icon} {capacity}%";
"format-charging" = " {capacity}%"; "format-charging" = " {capacity}%";
"format-icons" = [ "" "" "" "" "" ]; "format-icons" = ["" "" "" "" ""];
interval = 30; interval = 30;
}; };
@@ -122,10 +118,8 @@ in {
"format-wifi" = ""; "format-wifi" = "";
"format-ethernet" = "󰈀"; "format-ethernet" = "󰈀";
"format-disconnected" = "󰖪"; "format-disconnected" = "󰖪";
"tooltip-format-wifi" = "tooltip-format-wifi" = "{ifname} / {essid}\n\n {ipaddr}\n\n 󰘊 {signalStrength}% / 󰥛 {frequency}\n\n 󰕒 {bandwidthUpBits} / 󰇚 {bandwidthDownBits}";
"{ifname} / {essid}\n\n {ipaddr}\n\n 󰘊 {signalStrength}% / 󰥛 {frequency}\n\n 󰕒 {bandwidthUpBits} / 󰇚 {bandwidthDownBits}"; "tooltip-format-ethernet" = "{ifname} / {gwaddr}\n\n {ipaddr}\n\n 󰕒 {bandwidthUpBits} / 󰇚 {bandwidthDownBits}";
"tooltip-format-ethernet" =
"{ifname} / {gwaddr}\n\n {ipaddr}\n\n 󰕒 {bandwidthUpBits} / 󰇚 {bandwidthDownBits}";
"tooltip-format-disconnected" = "Disconnected"; "tooltip-format-disconnected" = "Disconnected";
interval = 5; interval = 5;
"on-click" = "kitty nmtui"; "on-click" = "kitty nmtui";
@@ -147,17 +141,12 @@ in {
"format-connected" = "󰂯 {device_alias}"; "format-connected" = "󰂯 {device_alias}";
"format-connected-battery" = "󰥉 {device_alias} ({device_battery_percentage}%)"; "format-connected-battery" = "󰥉 {device_alias} ({device_battery_percentage}%)";
"tooltip-format-off" = "Controller Powered Off"; "tooltip-format-off" = "Controller Powered Off";
"tooltip-format" = "tooltip-format" = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
"{controller_alias}\t{controller_address}\n\n{num_connections} connected"; "tooltip-format-connected" = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
"tooltip-format-connected" = "tooltip-format-enumerate-connected" = "{device_alias}\t{device_address}";
"{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}"; "tooltip-format-enumerate-connected-battery" = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
"tooltip-format-enumerate-connected" =
"{device_alias}\t{device_address}";
"tooltip-format-enumerate-connected-battery" =
"{device_alias}\t{device_address}\t{device_battery_percentage}%";
"on-click" = "kitty bluetuith --no-warning"; "on-click" = "kitty bluetuith --no-warning";
"on-click-right" = "on-click-right" = "if bluetoothctl show|grep -q 'Powered: yes';then bluetoothctl power off;else bluetoothctl power on;fi";
"if bluetoothctl show|grep -q 'Powered: yes';then bluetoothctl power off;else bluetoothctl power on;fi";
}; };
idle_inhibitor = { idle_inhibitor = {

View File

@@ -3,22 +3,22 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "xdg"; program = "xdg";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
home.packages = with pkgs; [xdg-ninja]; home.packages = with pkgs; [xdg-ninja];
xdg = if pkgs.system == "x86_64-darwin" then {} else { xdg =
if pkgs.system == "x86_64-darwin"
then {}
else {
enable = true; enable = true;
configHome = "/home/blake/.config"; configHome = "/home/blake/.config";
cacheHome = "/home/blake/.cache"; cacheHome = "/home/blake/.cache";
@@ -40,10 +40,12 @@ in {
}; };
# misc env variables to get things out of ~ (<3 xdg-ninja) # misc env variables to get things out of ~ (<3 xdg-ninja)
home.sessionVariables = if pkgs.system == "x86_64-darwin" then {} else { home.sessionVariables =
GOPATH="$XDG_DATA_HOME/go"; if pkgs.system == "x86_64-darwin"
_JAVA_OPTIONS=''-Djava.util.prefs.userRoot="$XDG_CONFIG_HOME"/java''; then {}
else {
GOPATH = "$XDG_DATA_HOME/go";
_JAVA_OPTIONS = ''-Djava.util.prefs.userRoot="$XDG_CONFIG_HOME"/java'';
}; };
}; };
} }

View File

@@ -3,19 +3,16 @@
lib, lib,
config, config,
... ...
}: }: let
let
program = "zsh"; program = "zsh";
cfg = config.dots.${program}; cfg = config.dots.${program};
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}"; enable = lib.mkEnableOption "enables ${program}";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
# export some defaults # export some defaults
home.sessionVariables = { home.sessionVariables = {
EDITOR = "nvim"; EDITOR = "nvim";

View File

@@ -17,6 +17,7 @@
librewolf.enable = true; librewolf.enable = true;
waybar.enable = true; waybar.enable = true;
hypr.enable = true; hypr.enable = true;
tofi.enable = true;
nvf.enable = true; nvf.enable = true;
zsh.enable = true; zsh.enable = true;
ssh.enable = true; ssh.enable = true;