summaryrefslogtreecommitdiff
path: root/modules/basic-tools
diff options
context:
space:
mode:
authorGrigory Shipunov2023-01-24 11:26:32 +0100
committerGrigory Shipunov2023-01-24 14:16:24 +0100
commitda02a4363337a2303db8d88e8c1c318b98aa63d3 (patch)
treed2ac65f06b5a5b3783d68e8fcfedc76814a7cc09 /modules/basic-tools
parenta2732c6e6ace0faebbc0b78b4010315709fac9c4 (diff)
add nix-output-monitor
Diffstat (limited to 'modules/basic-tools')
-rw-r--r--modules/basic-tools/default.nix18
1 files changed, 17 insertions, 1 deletions
diff --git a/modules/basic-tools/default.nix b/modules/basic-tools/default.nix
index 94cdcec..8725e38 100644
--- a/modules/basic-tools/default.nix
+++ b/modules/basic-tools/default.nix
@@ -58,7 +58,8 @@
# set appropriate environ variables
environment.variables = {
EDITOR = "nvim";
- PAGER = "less -F";
+ PAGER = "less";
+ LESS = "-X -R -F";
};
environment.shellAliases = {
@@ -72,6 +73,8 @@
vff = "$EDITOR $(ls|fzf)";
mutt = "neomutt";
grep = "grep --color=auto";
+ nix-build="${pkgs.nix-output-monitor}/bin/nom-build";
+ nix-shell="${pkgs.nix-output-monitor}/bin/nom-shell";
};
users.defaultUserShell = pkgs.zsh;
@@ -86,6 +89,19 @@
export SAVEHIST=10000000
# allow comments
setopt interactivecomments
+
+ # hacky wrapper for nix, so we can use nom automagically
+ export _nom_cmd=${pkgs.nix-output-monitor}/bin/nom
+ function nix {
+ case $1 in
+ build|shell|develop)
+ echo \[SUBSTITUTION\] ''$_nom_cmd ''${@:1} 1>&2
+ ''$_nom_cmd ''${@:1}
+ ;;
+ *)
+ ${pkgs.nix}/bin/nix $@
+ esac
+ }
'';
promptInit = ''
source ${pkgs.liquidprompt}/share/zsh/plugins/liquidprompt/liquidprompt