feat: hyprland, neovim, zsh changes

This commit is contained in:
2026-01-17 13:43:34 -05:00
parent 01f32d795c
commit 23a642f6f7
11 changed files with 71 additions and 33 deletions

6
flake.lock generated
View File

@@ -673,11 +673,11 @@
}, },
"unstable": { "unstable": {
"locked": { "locked": {
"lastModified": 1766651565, "lastModified": 1768564909,
"narHash": "sha256-QEhk0eXgyIqTpJ/ehZKg9IKS7EtlWxF3N7DXy42zPfU=", "narHash": "sha256-Kell/SpJYVkHWMvnhqJz/8DqQg2b6PguxVWOuadbHCc=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "3e2499d5539c16d0d173ba53552a4ff8547f4539", "rev": "e4bae1bd10c9c57b2cf517953ab70060a828ee6f",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -59,7 +59,7 @@
"col.inactive_border" = "rgba(595959aa)"; "col.inactive_border" = "rgba(595959aa)";
# Set to true enable resizing windows by clicking and dragging on borders and gaps # Set to true enable resizing windows by clicking and dragging on borders and gaps
resize_on_border = false; resize_on_border = true;
# Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on # Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on
allow_tearing = false; allow_tearing = false;
@@ -192,7 +192,7 @@
"$mainMod, F, fullscreen" "$mainMod, F, fullscreen"
# bind = $mainMod, J, togglesplit, # dwindle # bind = $mainMod, J, togglesplit, # dwindle
"$mainMod SHIFT, L, exec, ${scripts.lock}" "$mainMod SHIFT, Q, exec, ${scripts.lock}"
# Move focus with mainMod + arrow keys # Move focus with mainMod + arrow keys
"$mainMod, H, movefocus, l" "$mainMod, H, movefocus, l"
@@ -200,6 +200,12 @@
"$mainMod, K, movefocus, u" "$mainMod, K, movefocus, u"
"$mainMod, J, movefocus, d" "$mainMod, J, movefocus, d"
# Swap window with mainMod + shift + arrow keys
"$mainMod SHIFT, H, swapwindow, l"
"$mainMod SHIFT, L, swapwindow, r"
"$mainMod SHIFT, K, swapwindow, u"
"$mainMod SHIFT, J, swapwindow, d"
# Switch workspaces with mainMod + [0-9] # Switch workspaces with mainMod + [0-9]
"$mainMod, 1, workspace, 1" "$mainMod, 1, workspace, 1"
"$mainMod, 2, workspace, 2" "$mainMod, 2, workspace, 2"

View File

@@ -11,7 +11,6 @@
"bluetooth", "bluetooth",
"network", "network",
"pulseaudio", "pulseaudio",
"cpu",
"battery" "battery"
], ],
"hyprland/workspaces": { "hyprland/workspaces": {
@@ -29,14 +28,13 @@
"8": "8", "8": "8",
"9": "9", "9": "9",
"10": "0", "10": "0",
"active": "󱓻" "active": ""
}, },
"persistent-workspaces": { "persistent-workspaces": {
"1": [], "1": [],
"2": [], "2": [],
"3": [], "3": [],
"4": [], "4": []
"5": []
} }
}, },
"custom/logo": { "custom/logo": {
@@ -45,12 +43,6 @@
"on-click-right": "xdg-terminal-exec", "on-click-right": "xdg-terminal-exec",
"tooltip-format": "" "tooltip-format": ""
}, },
"cpu": {
"interval": 5,
"format": "󰍛",
"on-click": "omarchy-launch-or-focus-tui btop",
"on-click-right": "alacritty"
},
"clock": { "clock": {
"format": "{:L%A %I:%M}", "format": "{:L%A %I:%M}",
"format-alt": "{:L%d %B W%V %Y}", "format-alt": "{:L%d %B W%V %Y}",

View File

@@ -0,0 +1,6 @@
{ ... }:
{
services.displayManager.cosmic-greeter.enable = true;
services.desktopManager.cosmic.enable = true;
}

View File

@@ -1,7 +1,6 @@
{ ... }: { ... }:
{ {
imports = [ imports = [
./hyprland/font.nix
./hyprland/cursor.nix ./hyprland/cursor.nix
./hyprland/packages.nix ./hyprland/packages.nix
./hyprland/greeter.nix ./hyprland/greeter.nix

View File

@@ -8,6 +8,8 @@
./sops.nix ./sops.nix
../common/optional/desktop/hyprland.nix ../common/optional/desktop/hyprland.nix
# ../common/optional/desktop/cosmic.nix
../common/optional/font.nix
../common/optional/yubikey.nix ../common/optional/yubikey.nix
@@ -33,6 +35,15 @@
}; };
}; };
hardware.opengl = {
enable = true;
extraPackages = with pkgs; [
mesa.opencl
];
};
services.upower.enable = true;
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
hardware.bluetooth = { hardware.bluetooth = {
@@ -61,11 +72,12 @@
just just
# mpc # mpc
gurk-rs
libreoffice-qt libreoffice-qt
# ncmpcpp # ncmpcpp
pkgs-unstable.signal-desktop-bin pkgs-unstable.signal-desktop-bin
pkgs-unstable.gurk-rs
gnupg gnupg
(pass.withExtensions (exts: [ exts.pass-otp ])) (pass.withExtensions (exts: [ exts.pass-otp ]))
@@ -112,6 +124,14 @@
${mpg123}/bin/mpg123 "$url" ${mpg123}/bin/mpg123 "$url"
fi fi
'') '')
(pkgs.writeShellScriptBin "battery-graph" ''
${pkgs.coreutils}/bin/tail -n 20 /var/lib/upower/history-charge-bq40z651-69-F8Y3262H468Q1LTA1.dat | ${pkgs.coreutils}/bin/cut -f1,2 | RUBYOPT='-W0' ${pkgs.youplot}/bin/uplot line -w 70
'')
(pkgs.writeShellScriptBin "ocr-clip" ''
${pkgs.grimblast}/bin/grimblast -f save area - | ${pkgs.tesseract}/bin/tesseract stdin stdout | ${pkgs.wl-clipboard}/bin/wl-copy
'')
]; ];
programs.zsh.enable = true; programs.zsh.enable = true;

View File

@@ -20,6 +20,9 @@
cursorline = true; cursorline = true;
number = true; number = true;
tabstop = 2;
expandtab = true;
signcolumn = "yes"; signcolumn = "yes";
updatetime = 250; updatetime = 250;
@@ -107,7 +110,6 @@
gitsigns.enable = true; gitsigns.enable = true;
highlight-colors.enable = true; highlight-colors.enable = true;
todo-comments.enable = true; todo-comments.enable = true;
# smear-cursor.enable = true;
goyo.enable = true; goyo.enable = true;
treesitter = { treesitter = {
@@ -241,6 +243,7 @@
neo-tree = { neo-tree = {
enable = true; enable = true;
settings = { settings = {
window.width = 25;
filesystem = { filesystem = {
filtered_items = { filtered_items = {
visible = true; visible = true;
@@ -273,15 +276,6 @@
extraPlugins = with pkgs.vimPlugins; [ extraPlugins = with pkgs.vimPlugins; [
stay-centered-nvim stay-centered-nvim
mini-ai mini-ai
(pkgs.vimUtils.buildVimPlugin {
name = "neominimap";
src = pkgs.fetchFromGitHub {
owner = "Isrothy";
repo = "neominimap.nvim";
rev = "c827a43e5cad146e007c8b1f2a9744798d029e6f";
hash = "sha256-MQxeYIm0QLS2HROvGLD6Rc21Hqx3USF9OXcw1shNTWg=";
};
})
]; ];
}; };

View File

@@ -61,16 +61,22 @@
bindkey '^G' fzf-project bindkey '^G' fzf-project
fzf-files() { fzf-files() {
selected=$(rg --files | fzf) local selected
selected=$(${pkgs.ripgrep}/bin/rg --files | ${pkgs.fzf}/bin/fzf) || return
if [[ -n $selected ]]; then if [[ -n $selected ]]; then
xargs $EDITOR $selected BUFFER="v $selected"
zle reset-prompt print -s -- "$BUFFER"
zle accept-line
fi fi
zle redisplay
} }
zle -N fzf-files zle -N fzf-files
bindkey -M viins '^F' fzf-files bindkey '^V' fzf-files
'';
envExtra = ''
export PER_DIRECTORY_HISTORY_TOGGLE="^H"
''; '';
shellAliases = { shellAliases = {
@@ -100,6 +106,15 @@
src = pkgs.zsh-vi-mode; src = pkgs.zsh-vi-mode;
file = "share/zsh-vi-mode/zsh-vi-mode.plugin.zsh"; file = "share/zsh-vi-mode/zsh-vi-mode.plugin.zsh";
} }
{
name = "per-directory-history";
src = pkgs.fetchFromGitHub {
owner = "jimhester";
repo = "per-directory-history";
rev = "95f06973e9f2ff0ff75f3cebd0a2ee5485e27834";
sha256 = "sha256-EV9QPBndwAWzdOcghDXrIIgP0oagVMOTyXzoyt8tXRo=";
};
}
]; ];
}; };

View File

@@ -13,6 +13,12 @@ rebuild:
git add . git add .
sudo nixos-rebuild switch --flake '.?submodules=1#max' sudo nixos-rebuild switch --flake '.?submodules=1#max'
rebuild-boot:
just add-secrets
git add .
sudo nixos-rebuild boot --flake '.?submodules=1#max'
rebuild-offline: rebuild-offline:
just add-secrets just add-secrets

Submodule secrets updated: 1fd5856d0b...7bf9979dac