begin to modularise

This commit is contained in:
Tristan 2023-05-06 18:38:35 +01:00
parent bbd26675f8
commit a1175ba492
10 changed files with 311 additions and 93 deletions

View file

@ -62,18 +62,6 @@ let
${my-deps.notify-send} "Brightness" -h int:value:$(light) -a brightness-up -t 1000
'');
open-code = (pkgs.writeShellScriptBin "open-code" ''
code_dir=~/Documents/code
cd $code_dir
repo=$({ ls && echo clone-repo; } | ${my-deps.menu})
case $repo in
clone-repo)
url=$(wl-paste)
${my-deps.terminal} -e -- git clone "$url" ;;
*) [ -e "$repo" ] && my-editor $repo ;;
esac
'');
switch-window = (pkgs.writeShellScriptBin "switch-window" ''
${my-deps.hyprctl} clients -j | \
${my-deps.jq} '.[] | .title' -r | \
@ -187,7 +175,6 @@ in
bind = SUPER, Z, exec, ${pkgs.wlogout}/bin/wlogout
bind = SUPER, M, exec, ${ my-deps.terminal } -e ncmpcpp
bind = SUPER, O, exec, pcmanfm
bind = SUPER, C, exec, ${ my-scripts.open-code }/bin/open-code
bind = SUPER, TAB, exec, ${ my-scripts.switch-window }/bin/switch-window
bind = SUPER, G, exec, ${ pkgs.hyprpicker }/bin/hyprpicker | wl-copy && notify-send "Copied Colour" "$(wl-paste)"
bind = SUPER, EQUAL, exec, hyprctl keyword misc:cursor_zoom_factor 2
@ -441,8 +428,6 @@ in
};
programs.vscode = {
enable = true;
package = pkgs.vscodium;
extensions = with pkgs; [
vscode-extensions.asvetliakov.vscode-neovim
vscode-extensions.jnoortheen.nix-ide
@ -915,7 +900,6 @@ color body red default "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-
"${modifier}+SHIFT+P" = "exec ${ my-scripts.bwotpmenu }/bin/bwotpmenu";
"${modifier}+SHIFT+S" = "exec ${ my-scripts.screenshot }/bin/screenshot";
"${modifier}+M" = "exec ${ my-deps.terminal } -e ncmpcpp";
"${modifier}+C" = "exec ${ my-scripts.open-code }/bin/open-code";
"${modifier}+Z" = "exec ${pkgs.swaylock-effects}/bin/swaylock -f";
};
bars = [ ];