15 Commits

16 changed files with 480 additions and 195 deletions

View File

@@ -78,6 +78,7 @@
]; ];
}; };
nix = { nix = {
nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
distributedBuilds = true; distributedBuilds = true;
optimise.automatic = true; optimise.automatic = true;
settings = { settings = {

View File

@@ -2,60 +2,82 @@
inputs, inputs,
config, config,
pkgs, pkgs,
lib,
osConfig,
... ...
}: }:
let
inherit (pkgs) fd fzf;
inherit (inputs.jawz-scripts.packages.x86_64-linux) pokemon-colorscripts;
shellType = osConfig.my.shell.type;
commonInit = ''
${pokemon-colorscripts}/bin/pokemon-colorscripts -r --no-title
export command_timeout=60
'';
commonAliases = {
cp = "cp -i";
mv = "mv -i";
mkdir = "mkdir -p";
mkcd = "(){ mkdir -p \"$1\" && cd \"$1\" }";
copy = "xclip -selection clipboard";
cdp = "pwd | copy";
cfp = "(){ readlink -f \"$1\" | copy }";
".." = "cd ..";
"..." = "cd ../..";
".3" = "cd ../../..";
".4" = "cd ../../../..";
".5" = "cd ../../../../..";
c = "cat";
sc = "systemctl --user";
jc = "journalctl --user -xefu";
open-gallery = ''
cd /srv/pool/scrapping/JawZ/gallery-dl &&
xdg-open "$(${fd}/bin/fd . ./ Husbands wikifeet -tdirectory -d 1 | ${fzf}/bin/fzf -i)"'';
};
in
{ {
home.stateVersion = "23.05"; home.stateVersion = "23.05";
programs = { programs = {
direnv = { direnv = {
enable = true; enable = true;
enableBashIntegration = true; enableBashIntegration = shellType == "bash";
enableZshIntegration = shellType == "zsh";
nix-direnv.enable = true; nix-direnv.enable = true;
}; };
git = { git = {
enable = true; enable = true;
delta.enable = true;
userName = "Danilo Reyes"; userName = "Danilo Reyes";
userEmail = "CaptainJawZ@protonmail.com"; userEmail = "CaptainJawZ@protonmail.com";
}; extraConfig = {
bash = init.defaultBranch = "main";
let pull.rebase = true;
inherit (pkgs) fd fzf;
inherit (inputs.jawz-scripts.packages.x86_64-linux) pokemon-colorscripts;
in
{
enable = true;
historyFile = "\${XDG_STATE_HOME}/bash/history";
historyControl = [
"erasedups"
"ignorespace"
"ignoredups"
];
shellAliases = {
cp = "cp -i";
mv = "mv -i";
mkdir = "mkdir -p";
mkcd = "(){ mkdir -p \"$1\" && cd \"$1\" }";
copy = "xclip -selection clipboard";
cdp = "pwd | copy";
cfp = "(){ readlink -f \"$1\" | copy }";
".." = "cd ..";
"..." = "cd ../..";
".3" = "cd ../../..";
".4" = "cd ../../../..";
".5" = "cd ../../../../..";
c = "cat";
sc = "systemctl --user";
jc = "journalctl --user -xefu";
open-gallery = ''
cd /srv/pool/scrapping/JawZ/gallery-dl &&
xdg-open "$(${fd}/bin/fd . ./ Husbands wikifeet -tdirectory -d 1 | ${fzf}/bin/fzf -i)"'';
};
enableVteIntegration = true;
initExtra = ''
${pokemon-colorscripts}/bin/pokemon-colorscripts -r --no-title
export command_timeout=60
'';
}; };
};
bash = lib.mkIf (shellType == "bash") {
enable = true;
historyFile = "\${XDG_STATE_HOME}/bash/history";
shellAliases = commonAliases;
enableVteIntegration = true;
initExtra = commonInit;
historyControl = [
"erasedups"
"ignorespace"
"ignoredups"
];
};
zsh = lib.mkIf (shellType == "zsh") {
enable = true;
dotDir = ".config/zsh";
shellAliases = commonAliases;
initContent = commonInit;
history = {
path = "\${XDG_STATE_HOME}/zsh/history";
expireDuplicatesFirst = true;
ignoreSpace = true;
ignoreAllDups = true;
};
};
}; };
xdg = { xdg = {
enable = true; enable = true;

View File

@@ -38,5 +38,11 @@ _final: prev: {
waybar = prev.waybar.overrideAttrs (old: { waybar = prev.waybar.overrideAttrs (old: {
mesonFlags = old.mesonFlags ++ [ "-Dexperimental=true" ]; mesonFlags = old.mesonFlags ++ [ "-Dexperimental=true" ];
}); });
inherit (pkgsU) symbola mealie flaresolver; inherit (pkgsU)
symbola
mealie
flaresolver
nixd
nix-statix
;
} }

View File

@@ -11,6 +11,7 @@ let
}; };
scheme = schemesFile.schemes.cheems; scheme = schemesFile.schemes.cheems;
cfg = config.my.stylix; cfg = config.my.stylix;
gnomeEnabled = config.services.xserver.desktopManager.gnome.enable;
in in
{ {
options.my.stylix.enable = lib.mkEnableOption "system-wide theming with Stylix"; options.my.stylix.enable = lib.mkEnableOption "system-wide theming with Stylix";
@@ -23,7 +24,7 @@ in
} }
// lib.optionalAttrs (scheme ? base16Scheme) { inherit (scheme) base16Scheme; }; // lib.optionalAttrs (scheme ? base16Scheme) { inherit (scheme) base16Scheme; };
home-manager.users.jawz = { home-manager.users.jawz = {
gtk = lib.mkIf (!cfg.enable) { gtk = lib.mkIf (!cfg.enable && gnomeEnabled) {
enable = true; enable = true;
iconTheme = { iconTheme = {
name = "Papirus-Light"; name = "Papirus-Light";
@@ -33,7 +34,7 @@ in
}; };
}; };
stylix = { stylix = {
enable = true; inherit (cfg) enable;
autoEnable = cfg.enable; autoEnable = cfg.enable;
iconTheme = { iconTheme = {
inherit (cfg) enable; inherit (cfg) enable;

View File

@@ -4,6 +4,7 @@
... ...
}: }:
{ {
qt.enable = true;
services = { services = {
gvfs.enable = true; gvfs.enable = true;
libinput.enable = true; libinput.enable = true;
@@ -32,7 +33,6 @@
totem totem
; ;
}; };
qt.enable = true;
users.users.jawz.packages = builtins.attrValues { users.users.jawz.packages = builtins.attrValues {
inherit (pkgs.gnomeExtensions) inherit (pkgs.gnomeExtensions)
tactile # window manager tactile # window manager

View File

@@ -1,13 +1,36 @@
{ {
pkgs, pkgs,
config,
... ...
}: }:
let let
startupScript = pkgs.pkgs.writeShellScriptBin "start" '' # misc
${pkgs.waybar}/bin/waybar & mod = "SUPER";
${pkgs.swww}/bin/swww init & # waybar
sleep 1 inherit (config.lib.stylix) colors;
''; net-icons = [
"󰣾"
"󰣴"
"󰣶"
"󰣸"
"󰣺"
];
generic-percent-icons = [
""
""
""
""
""
""
""
""
];
temp-icons = [
""
""
""
""
];
in in
{ {
programs.hyprland.enable = true; programs.hyprland.enable = true;
@@ -22,35 +45,144 @@ in
enable = true; enable = true;
extraPortals = [ extraPortals = [
pkgs.xdg-desktop-portal-hyprland pkgs.xdg-desktop-portal-hyprland
pkgs.xdg-desktop-portal-gtk
]; ];
}; };
users.users.jawz.packages = builtins.attrValues { users.users.jawz.packages = builtins.attrValues {
inherit (pkgs) inherit (pkgs)
# Wayland utilities # Wayland utilities
wl-clipboard wl-clipboard-rs
wf-recorder wf-recorder
grim grimblast # screenshots
slurp
wofi # Application launcher mako # notification daemon
mako # Notification daemon
libnotify # dependency of mako libnotify # dependency of mako
swaylock-effects # Screen locker swaylock-effects # screen locker
nautilus # File manager yazi # file manager
imv # images
; ;
}; };
home-manager.users.jawz = { home-manager.users.jawz = {
programs.kitty.enable = true; programs = {
wofi = {
enable = true;
settings = {
allow_images = true;
allow_markup = true;
insensitive = true;
width = "30%";
};
};
waybar = {
enable = true;
systemd.enable = true;
settings.main-bar = {
layer = "top";
tray.spacing = 5;
clock.format = "{:%H:%M %F}";
modules-left = [
"niri/workspaces"
"custom/sep"
"niri/window"
];
modules-center = [
"mpris"
];
modules-right = [
"cpu"
"temperature"
"memory"
"backlight"
"pulseaudio"
"battery"
"custom/recorder"
"clock"
"tray"
];
"hyprland/window".icon = true;
"niri/window".icon = true;
"niri/workspaces" = {
format = "{icon}";
format-icons = {
active = "";
default = "";
};
};
cava = {
format-icons = generic-percent-icons;
bars = 14;
method = "pulse";
framerate = 20;
bar_delimiter = 0;
stereo = false;
};
network = {
format = "{icon} {ipaddr}";
format-icons = net-icons;
};
# pulseaudio = {
# format = "{icon} {volume}%";
# format-muted = "vol: muted";
# format-icons.default = audio-icons;
# on-click = "pavucontrol";
# scroll-step = 1;
# };
cpu = {
interval = 1;
format = " {icon}";
format-icons = generic-percent-icons;
tooltip-format = "usage: {usage}%\nload: {load}";
};
memory = {
interval = 1;
format = " {icon}";
format-icons = generic-percent-icons;
tooltip-format = "{used} GiB / {total} GiB \n{percentage}%";
};
temperature = {
interval = 1;
critical-threshold = 80;
format = "{temperatureC}°C";
format-icons = temp-icons;
};
mpris = {
format = "{status_icon} {dynamic}";
dynamic-len = 60;
interval = 5;
status-icons = {
paused = "";
playing = "";
};
};
};
style = ''
* {
border: none;
font-family: "${config.stylix.fonts.monospace.name}";
font-size: ${toString config.stylix.fonts.sizes.desktop}pt;
color: #${colors.base04};
}
window#waybar {
background: #${colors.base00};
}
.module {
background: #${colors.base00};
margin: 0px 5px 0px 5px;
padding: 0px 0px 0px 5px;
}
#workspaces button {
padding: 0px;
border-bottom: 0px none transparent;
}
'';
};
};
wayland.windowManager.hyprland = { wayland.windowManager.hyprland = {
enable = true; enable = true;
settings = { settings = {
"$mainMod" = "SUPER";
exec-once = "${startupScript}/bin/start";
general = { general = {
gaps_in = 5; gaps_in = 5;
gaps_out = 10; gaps_out = 10;
border_size = 2; border_size = 3;
layout = "dwindle"; layout = "dwindle";
}; };
dwindle = { dwindle = {
@@ -59,49 +191,78 @@ in
force_split = 2; force_split = 2;
}; };
bind = [ bind = [
"$mainMod, return, exec, kitty" "${mod}, return, exec, ghostty"
"$mainMod, Q, killactive," "${mod}, Q, killactive,"
"$mainMod SHIFT, F, togglefloating," "${mod} SHIFT, F, togglefloating,"
"$mainMod, F, fullscreen," "${mod}, F, fullscreen,"
"$mainMod, T, pin," "${mod}, T, pin,"
"$mainMod, G, togglegroup," "${mod}, G, togglegroup,"
"$mainMod, bracketleft, changegroupactive, b" "${mod}, bracketleft, changegroupactive, b"
"$mainMod, bracketright, changegroupactive, f" "${mod}, bracketright, changegroupactive, f"
"$mainMod, S, exec, wofi --show drun icons" "${mod}, S, exec, wofi --show drun icons"
"$mainMod, P, pin, active" "${mod}, P, pin, active"
"${mod}, left, movefocus, l"
"${mod}, right, movefocus, r"
"${mod}, up, movefocus, u"
"${mod}, down, movefocus, d"
"${mod}, h, movefocus, l"
"${mod}, l, movefocus, r"
"${mod}, k, movefocus, u"
"${mod}, j, movefocus, d"
"${mod} SHIFT, left, movewindow, l"
"${mod} SHIFT, right, movewindow, r"
"${mod} SHIFT, up, movewindow, u"
"${mod} SHIFT, down, movewindow, d"
"${mod} SHIFT, h, movewindow, l"
"${mod} SHIFT, l, movewindow, r"
"${mod} SHIFT, k, movewindow, u"
"${mod} SHIFT, j, movewindow, d"
"${mod}, 1, workspace, 1"
"${mod}, 2, workspace, 2"
"${mod}, 3, workspace, 3"
"${mod}, 4, workspace, 4"
"${mod}, 5, workspace, 5"
"${mod}, 6, workspace, 6"
"${mod}, 7, workspace, 7"
"${mod}, 8, workspace, 8"
"${mod}, 9, workspace, 9"
"${mod}, 0, workspace, 10"
"${mod} SHIFT, 1, movetoworkspace, 1"
"${mod} SHIFT, 2, movetoworkspace, 2"
"${mod} SHIFT, 3, movetoworkspace, 3"
"${mod} SHIFT, 4, movetoworkspace, 4"
"${mod} SHIFT, 5, movetoworkspace, 5"
"${mod} SHIFT, 6, movetoworkspace, 6"
"${mod} SHIFT, 7, movetoworkspace, 7"
"${mod} SHIFT, 8, movetoworkspace, 8"
"${mod} SHIFT, 9, movetoworkspace, 9"
"${mod} SHIFT, 0, movetoworkspace, 10"
"${mod}, F3, exec, grimblast save area ~/Pictures/screenshots/$(date +'%Y-%m-%d_%H-%M-%S').png"
"${mod} SHIFT, F3, exec, grimblast save screen ~/Pictures/screenshots/$(date +'%Y-%m-%d_%H-%M-%S').png"
];
binde = [
"${mod} SHIFT, h, moveactive, -20 0"
"${mod} SHIFT, l, moveactive, 20 0"
"${mod} SHIFT, k, moveactive, 0 -20"
"${mod} SHIFT, j, moveactive, 0 20"
"${mod} CTRL, l, resizeactive, 30 0"
"${mod} CTRL, h, resizeactive, -30 0"
"${mod} CTRL, k, resizeactive, 0 -10"
"${mod} CTRL, j, resizeactive, 0 10"
",XF86AudioRaiseVolume, exec, wpctl set-volume -l 1.4 @DEFAULT_AUDIO_SINK@ 5%+" ",XF86AudioRaiseVolume, exec, wpctl set-volume -l 1.4 @DEFAULT_AUDIO_SINK@ 5%+"
",XF86AudioLowerVolume, exec, wpctl set-volume -l 1.4 @DEFAULT_AUDIO_SINK@ 5%-" ",XF86AudioLowerVolume, exec, wpctl set-volume -l 1.4 @DEFAULT_AUDIO_SINK@ 5%-"
"$mainMod, left, movefocus, l"
"$mainMod, right, movefocus, r"
"$mainMod, up, movefocus, u"
"$mainMod, down, movefocus, d"
"$mainMod, h, movefocus, l"
"$mainMod, l, movefocus, r"
"$mainMod, k, movefocus, u"
"$mainMod, j, movefocus, d"
"$mainMod SHIFT, h, movewindow, l"
"$mainMod SHIFT, l, movewindow, r"
"$mainMod SHIFT, k, movewindow, u"
"$mainMod SHIFT, j, movewindow, d"
];
binde = [
"$mainMod SHIFT, h, moveactive, -20 0"
"$mainMod SHIFT, l, moveactive, 20 0"
"$mainMod SHIFT, k, moveactive, 0 -20"
"$mainMod SHIFT, j, moveactive, 0 20"
"$mainMod CTRL, l, resizeactive, 30 0"
"$mainMod CTRL, h, resizeactive, -30 0"
"$mainMod CTRL, k, resizeactive, 0 -10"
"$mainMod CTRL, j, resizeactive, 0 10"
]; ];
bindm = [ bindm = [
"$mainMod, mouse:272, movewindow" "${mod}, mouse:272, movewindow"
"$mainMod, mouse:273, resizewindow" "${mod}, mouse:273, resizewindow"
]; ];
}; };
}; };

80
flake.lock generated
View File

@@ -125,27 +125,28 @@
"systems": "systems" "systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1759135438, "lastModified": 1757147654,
"narHash": "sha256-2GLoM04OmwN7lVxUZI5y4zw/nFbxkVFkJmkOv4kzsdU=", "narHash": "sha256-mGoonbnnd38MZS/H80/vbXCHCxl6KlFup/XKK+zcAuY=",
"owner": "marienz", "owner": "marienz",
"repo": "nix-doom-emacs-unstraightened", "repo": "nix-doom-emacs-unstraightened",
"rev": "7b6f3ca8d26af16e435a9d7d6a27fde60df72312", "rev": "ad01165af00765af07989b6ad14115960ac675f8",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "marienz", "owner": "marienz",
"repo": "nix-doom-emacs-unstraightened", "repo": "nix-doom-emacs-unstraightened",
"rev": "ad01165af00765af07989b6ad14115960ac675f8",
"type": "github" "type": "github"
} }
}, },
"doomemacs": { "doomemacs": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1758860516, "lastModified": 1757106921,
"narHash": "sha256-ulQq9+RHIQELZVQuXsLQInqeAhOCDqRltUDRVBjQ1c0=", "narHash": "sha256-vHwgENjip2+AFzs4oZfnKEAJKwf5Zid7fakImvxxQUw=",
"owner": "doomemacs", "owner": "doomemacs",
"repo": "doomemacs", "repo": "doomemacs",
"rev": "1d1d17e9c910146731cb7b19d5bcbf6c4b283a74", "rev": "8f55404781edacf66fa330205533b002de3fb5ee",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -164,11 +165,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1759111708, "lastModified": 1757124175,
"narHash": "sha256-vFFue5sy7YRPhQQGW9kiCj+tAY3Gfm05svmDLFt5FIw=", "narHash": "sha256-drA0+kWXGrTgvhlsCiEE7VJ+vFsPi74p32n/7L5L5aU=",
"owner": "nix-community", "owner": "nix-community",
"repo": "emacs-overlay", "repo": "emacs-overlay",
"rev": "c8f778ca07cc9d8182599be4e794db6c8e03682e", "rev": "802b82be7856f6350d5e9ccb536fb4e20cb82069",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -304,6 +305,22 @@
"type": "github" "type": "github"
} }
}, },
"fonts": {
"flake": false,
"locked": {
"lastModified": 1759200391,
"narHash": "sha256-S5LwvPL7sKgwKUhCyTpcuWUxCq57RFh7wbZ6rIc5AgU=",
"ref": "refs/heads/master",
"rev": "edea9d2aaf2f4e0481fbbb8e26f68a9f39248e3f",
"revCount": 2,
"type": "git",
"url": "https://git.servidos.lat/jawz/fonts.git"
},
"original": {
"type": "git",
"url": "https://git.servidos.lat/jawz/fonts.git"
}
},
"fromYaml": { "fromYaml": {
"flake": false, "flake": false,
"locked": { "locked": {
@@ -456,11 +473,11 @@
"xdph": "xdph" "xdph": "xdph"
}, },
"locked": { "locked": {
"lastModified": 1759094452, "lastModified": 1759169434,
"narHash": "sha256-j7IOTFnQRDjX4PzYb2p6CPviAc8cDrcorzGpM8J89uM=", "narHash": "sha256-1u6kq88ICeE9IiJPditYa248ZoEqo00kz6iUR+jLvBQ=",
"owner": "hyprwm", "owner": "hyprwm",
"repo": "Hyprland", "repo": "Hyprland",
"rev": "f854b5bffbdd13cfe7edad0ee157d6947ff99619", "rev": "38c1e72c9d81fcdad8f173e06102a5da18836230",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -649,11 +666,11 @@
"sudoku-solver": "sudoku-solver" "sudoku-solver": "sudoku-solver"
}, },
"locked": { "locked": {
"lastModified": 1758693316, "lastModified": 1759213850,
"narHash": "sha256-cy8CdWOyDJdIe2gVPP3mtRIYXwv8m08HhLet8eSyrHM=", "narHash": "sha256-KnFUzXjSOtSG9U4U4OJonCTZaMWqJjXvHL1PQW994A4=",
"ref": "refs/heads/master", "ref": "refs/heads/master",
"rev": "64a81ca78d03816ddcbbdc8a7b6186c975c6653a", "rev": "38959dc37b09d1cb037df02086e4d07b9ef30b80",
"revCount": 104, "revCount": 105,
"type": "git", "type": "git",
"url": "https://git.servidos.lat/jawz/scripts.git" "url": "https://git.servidos.lat/jawz/scripts.git"
}, },
@@ -770,11 +787,11 @@
}, },
"nixpkgs-small": { "nixpkgs-small": {
"locked": { "locked": {
"lastModified": 1759008180, "lastModified": 1759250113,
"narHash": "sha256-hVpxYhilbBxQj0D6u6hUb6OXhNl85xIdhUE23AmqBdA=", "narHash": "sha256-apF3ww4pPkxHI5c424Z6VYdImge1iZSP6TOH45lIqxU=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "9a51fe84a7214f70a17e5d7ce085385baa24ee29", "rev": "f579c51fd27e9f66c8236b26a47ed78b315f785d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -786,11 +803,11 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1758690382, "lastModified": 1759036355,
"narHash": "sha256-NY3kSorgqE5LMm1LqNwGne3ZLMF2/ILgLpFr1fS4X3o=", "narHash": "sha256-0m27AKv6ka+q270dw48KflE0LwQYrO7Fm4/2//KCVWg=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "e643668fd71b949c53f8626614b21ff71a07379d", "rev": "e9f00bd893984bc8ce46c895c3bf7cac95331127",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -802,11 +819,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1758791193, "lastModified": 1759143472,
"narHash": "sha256-F8WmEwFoHsnix7rt290R0rFXNJiMbClMZyIC/e+HYf0=", "narHash": "sha256-TvODmeR2W7yX/JmOCmP+lAFNkTT7hAxYcF3Kz8SZV3w=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "25e53aa156d47bad5082ff7618f5feb1f5e02d01", "rev": "5ed4e25ab58fd4c028b59d5611e14ea64de51d23",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -845,11 +862,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1759136191, "lastModified": 1759260470,
"narHash": "sha256-1FhgEzYRwLWUWjm/csTr+OmzRVGgvlUDySqhFOyhPGM=", "narHash": "sha256-7KFWm6l+qJl+b1XAx9D8isjCb2kluJEGzquZxmJPEL4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nur", "repo": "nur",
"rev": "c7f19a28eaa25be9451bd48508eabf2b386fb72d", "rev": "2b8508603232941676978619d6d4b34fc9e0b486",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -910,6 +927,7 @@
"root": { "root": {
"inputs": { "inputs": {
"doom-emacs": "doom-emacs", "doom-emacs": "doom-emacs",
"fonts": "fonts",
"home-manager": "home-manager", "home-manager": "home-manager",
"hyprland": "hyprland", "hyprland": "hyprland",
"jawz-scripts": "jawz-scripts", "jawz-scripts": "jawz-scripts",
@@ -933,11 +951,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1759030640, "lastModified": 1759188042,
"narHash": "sha256-53VP3BqMXJqD1He1WADTFyUnpta3mie56H7nC59tSic=", "narHash": "sha256-f9QC2KKiNReZDG2yyKAtDZh0rSK2Xp1wkPzKbHeQVRU=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "9ac51832c70f2ff34fcc97b05fa74b4a78317f9e", "rev": "9fcfabe085281dd793589bdc770a2e577a3caa5d",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -6,7 +6,7 @@
nixpkgs-unstable.url = "github:nixos/nixpkgs?ref=nixos-unstable"; nixpkgs-unstable.url = "github:nixos/nixpkgs?ref=nixos-unstable";
ucodenix.url = "github:e-tho/ucodenix"; ucodenix.url = "github:e-tho/ucodenix";
doom-emacs = { doom-emacs = {
url = "github:marienz/nix-doom-emacs-unstraightened"; url = "github:marienz/nix-doom-emacs-unstraightened/ad01165af00765af07989b6ad14115960ac675f8";
inputs.nixpkgs.follows = ""; inputs.nixpkgs.follows = "";
}; };
jawz-scripts = { jawz-scripts = {
@@ -17,6 +17,10 @@
url = "git+https://git.servidos.lat/jawz/wallpapers.git"; url = "git+https://git.servidos.lat/jawz/wallpapers.git";
flake = false; flake = false;
}; };
fonts = {
url = "git+https://git.servidos.lat/jawz/fonts.git";
flake = false;
};
nur = { nur = {
url = "github:nix-community/nur"; url = "github:nix-community/nur";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";

View File

@@ -1,8 +1,11 @@
{ {
lib,
pkgs, pkgs,
config,
... ...
}: }:
let let
shellType = config.my.shell.type;
krita-thumbnailer = pkgs.writeTextFile { krita-thumbnailer = pkgs.writeTextFile {
name = "krita-thumbnailer"; name = "krita-thumbnailer";
destination = "/share/thumbnailers/kra.thumbnailer"; destination = "/share/thumbnailers/kra.thumbnailer";
@@ -38,7 +41,8 @@ in
ghostty = { ghostty = {
enable = true; enable = true;
package = pkgs.ghostty; package = pkgs.ghostty;
enableBashIntegration = true; enableBashIntegration = shellType == "bash";
enableZshIntegration = shellType == "zsh";
installBatSyntax = true; installBatSyntax = true;
installVimSyntax = true; installVimSyntax = true;
}; };
@@ -130,7 +134,7 @@ in
../../secrets/ssh/root-private-ca.pem ../../secrets/ssh/root-private-ca.pem
]; ];
services = { services = {
flatpak.enable = true; flatpak.enable = lib.mkDefault false;
open-webui.enable = true; open-webui.enable = true;
scx = { scx = {
enable = true; enable = true;
@@ -151,7 +155,7 @@ in
}; };
sunshine = { sunshine = {
enable = true; enable = true;
autoStart = true; autoStart = false;
capSysAdmin = true; capSysAdmin = true;
openFirewall = true; openFirewall = true;
}; };

View File

@@ -24,25 +24,18 @@ in
cpuModelId = "00A50F00"; cpuModelId = "00A50F00";
}; };
}; };
hardware = { hardware.bluetooth = {
bluetooth = { enable = true;
enable = true; settings.General = {
settings.General = { Enable = "Source,Sink,Media,Socket";
Enable = "Source,Sink,Media,Socket"; Experimental = true;
Experimental = true;
};
};
opentabletdriver = {
enable = true;
daemon.enable = true;
}; };
}; };
boot = { boot = {
plymouth.enable = true; plymouth.enable = true;
consoleLogLevel = 0; consoleLogLevel = 0;
loader.timeout = 0; loader.timeout = 3;
kernelParams = [ kernelParams = [
"quiet"
"splash" "splash"
"boot.shell_on_fail" "boot.shell_on_fail"
"loglevel=3" "loglevel=3"
@@ -84,17 +77,11 @@ in
"usb_storage" "usb_storage"
"sd_mod" "sd_mod"
]; ];
luks.devices = luks.devices.nvme = {
let device = getUUID "e9618e85-a631-4374-b2a4-22c376d6e41b";
decryptLuks = uuid: { keyFile = "/keyfile";
device = getUUID uuid; preLVM = true;
keyFile = "/keyfile"; };
preLVM = true;
};
in
{
nvme = decryptLuks "e9618e85-a631-4374-b2a4-22c376d6e41b";
};
}; };
}; };
fileSystems = fileSystems =

View File

@@ -2,13 +2,30 @@
config, config,
lib, lib,
pkgs, pkgs,
inputs,
... ...
}: }:
let
customFonts = pkgs.stdenvNoCC.mkDerivation {
name = "custom-fonts";
src = inputs.fonts;
installPhase = ''
mkdir -p $out/share/fonts
find $src -type f \( \
-name "*.ttf" -o \
-name "*.otf" -o \
-name "*.woff" -o \
-name "*.woff2" \
\) -exec cp {} $out/share/fonts/ \;
'';
};
in
{ {
options.my.apps.fonts.enable = lib.mkEnableOption "additional fonts and typography"; options.my.apps.fonts.enable = lib.mkEnableOption "additional fonts and typography";
config = lib.mkIf config.my.apps.fonts.enable { config = lib.mkIf config.my.apps.fonts.enable {
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "corefonts" ]; nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "corefonts" ];
fonts.packages = builtins.attrValues { fonts.packages = builtins.attrValues {
inherit customFonts;
inherit (pkgs) inherit (pkgs)
symbola symbola
comic-neue comic-neue

View File

@@ -14,7 +14,7 @@
"doom/templates/programming.org".source = ../../dotfiles/doom/templates/programming.org; "doom/templates/programming.org".source = ../../dotfiles/doom/templates/programming.org;
}; };
services.lorri.enable = true; services.lorri.enable = true;
programs.bash.shellAliases = { programs.${config.my.shell.type}.shellAliases = {
edit = "emacsclient -t"; edit = "emacsclient -t";
e = "edit"; e = "edit";
}; };

View File

@@ -5,11 +5,14 @@
... ...
}: }:
let let
shellType = config.my.shell.type;
packages = builtins.attrValues { packages = builtins.attrValues {
inherit (pkgs) inherit (pkgs)
nixfmt-rfc-style # formatting nixfmt-rfc-style # formatting
nixfmt-tree # formatting
cachix # binary cache management cachix # binary cache management
nixd # language server for Nix nixd # language server for Nix
deadnix # detext unused/uneeded dependencies
statix # linter for Nix expressions statix # linter for Nix expressions
; ;
}; };
@@ -31,5 +34,12 @@ in
}; };
config = lib.mkIf config.my.dev.nix.enable { config = lib.mkIf config.my.dev.nix.enable {
users.users.jawz = { inherit packages; }; users.users.jawz = { inherit packages; };
home-manager.users.jawz.programs.${shellType}.shellAliases = {
nixformat = ''
deadnix -- -e && \
nixfmt-tree && \
statix fix
'';
};
}; };
} }

View File

@@ -16,21 +16,33 @@
inherit (inputs.jawz-scripts.packages.x86_64-linux) download; inherit (inputs.jawz-scripts.packages.x86_64-linux) download;
in in
{ {
home-manager.users.jawz = { home-manager.users.jawz.programs.${config.my.shell.type} = {
programs.bash = { shellAliases = {
shellAliases = { dl = "${download}/bin/download -u jawz -i";
dl = "${download}/bin/download -u jawz -i"; comic = ''dl "$(cat "$LC" | fzf --multi --exact -i)"'';
comic = ''dl "$(cat "$LC" | fzf --multi --exact -i)"''; gallery = ''dl "$(cat "$LW" | fzf --multi --exact -i)"'';
gallery = ''dl "$(cat "$LW" | fzf --multi --exact -i)"'';
};
initExtra = ''
list_root=$XDG_CONFIG_HOME/jawz/lists/jawz
export LW=$list_root/watch.txt
export LI=$list_root/instant.txt
export LC=$list_root/comic.txt
'';
}; };
}; }
// (
if config.my.shell.type == "bash" then
{
initExtra = ''
list_root=$XDG_CONFIG_HOME/jawz/lists/jawz
export LW=$list_root/watch.txt
export LI=$list_root/instant.txt
export LC=$list_root/comic.txt
'';
}
else
{
initContent = ''
list_root=$XDG_CONFIG_HOME/jawz/lists/jawz
export LW=$list_root/watch.txt
export LI=$list_root/instant.txt
export LC=$list_root/comic.txt
'';
}
);
systemd.user = { systemd.user = {
services = services =
let let

20
modules/shell/config.nix Normal file
View File

@@ -0,0 +1,20 @@
{
config,
lib,
pkgs,
...
}:
{
options.my.shell.type = lib.mkOption {
type = lib.types.enum [
"bash"
"zsh"
];
default = "bash";
description = "The shell to use system-wide (bash or zsh)";
};
config = {
users.users.jawz.shell = pkgs.${config.my.shell.type};
programs.zsh.enable = config.my.shell.type == "zsh";
};
}

View File

@@ -5,6 +5,9 @@
inputs, inputs,
... ...
}: }:
let
shellType = config.my.shell.type;
in
{ {
options.my.shell.tools.enable = lib.mkEnableOption "shell tools and utilities"; options.my.shell.tools.enable = lib.mkEnableOption "shell tools and utilities";
config = lib.mkIf config.my.shell.tools.enable { config = lib.mkIf config.my.shell.tools.enable {
@@ -14,29 +17,15 @@
enable = true; enable = true;
package = pkgs.htop-vim; package = pkgs.htop-vim;
}; };
eza = {
enable = true;
git = true;
icons = "auto";
};
zoxide = { zoxide = {
enable = true; enable = true;
enableBashIntegration = true; enableBashIntegration = shellType == "bash";
}; enableZshIntegration = shellType == "zsh";
bash = {
initExtra = ''
if command -v fzf-share >/dev/null; then
source "$(fzf-share)/key-bindings.bash"
source "$(fzf-share)/completion.bash"
fi
'';
shellAliases = {
cd = "z";
hh = "hstr";
ls = "eza --icons --group-directories-first";
rm = "trash";
b = "bat";
f = "fzf --multi --exact -i";
unique-extensions = ''
fd -tf | rev | cut -d. -f1 | rev |
tr '[:upper:]' '[:lower:]' | sort |
uniq --count | sort -rn'';
};
}; };
bat = { bat = {
enable = true; enable = true;
@@ -67,6 +56,40 @@
PASSWORD_STORE_SAFECONTENT = "true"; PASSWORD_STORE_SAFECONTENT = "true";
}; };
}; };
${shellType} = {
shellAliases = {
cd = "z";
hh = "hstr";
ls = "eza --icons --group-directories-first";
rm = "trash";
b = "bat";
f = "fzf --multi --exact -i";
unique-extensions = ''
fd -tf | rev | cut -d. -f1 | rev |
tr '[:upper:]' '[:lower:]' | sort |
uniq --count | sort -rn'';
};
}
// (
if shellType == "bash" then
{
initExtra = ''
if command -v fzf-share >/dev/null; then
source "$(fzf-share)/key-bindings.bash"
source "$(fzf-share)/completion.bash"
fi
'';
}
else
{
initContent = ''
if command -v fzf-share >/dev/null; then
source "$(fzf-share)/key-bindings.bash"
source "$(fzf-share)/completion.bash"
fi
'';
}
);
}; };
programs = { programs = {
starship.enable = true; starship.enable = true;
@@ -81,7 +104,6 @@
inherit (pkgs) inherit (pkgs)
ripgrep # modern grep ripgrep # modern grep
du-dust # rusty du similar to gdu du-dust # rusty du similar to gdu
eza # like ls but with colors
fd # modern find, faster searches fd # modern find, faster searches
fzf # fuzzy finder! super cool and useful fzf # fuzzy finder! super cool and useful
gdu # disk-space utility checker, somewhat useful gdu # disk-space utility checker, somewhat useful