mirror of
https://github.com/Gerg-L/nixos.git
synced 2025-12-10 00:43:56 -05:00
feat: auto zellij script
This commit is contained in:
parent
3295aa7421
commit
c0ca8281f3
2 changed files with 66 additions and 0 deletions
|
|
@ -130,6 +130,27 @@
|
|||
silent = true;
|
||||
};
|
||||
|
||||
|
||||
zsh = {
|
||||
interactiveShellInit =
|
||||
let
|
||||
monitorScript = pkgs.replaceVarsWith {
|
||||
src = ./monitor.ps;
|
||||
replacements = builtins.mapAttrs (_: lib.getExe) {
|
||||
inherit (pkgs) perl xdotool;
|
||||
};
|
||||
isExecutable = true;
|
||||
};
|
||||
in
|
||||
''
|
||||
if [[ -z "$ZELLIJ" ]]; then
|
||||
MONITOR="$(${monitorScript} || true)"
|
||||
zellij attach -c "''${MONITOR:+"$MONITOR@"}$USER"
|
||||
exit
|
||||
fi
|
||||
'';
|
||||
};
|
||||
|
||||
nix-index = {
|
||||
enable = true;
|
||||
package = nix-index-database.packages.nix-index-with-db;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue