blob: dadea53316bf5402d35096ea5623377c94d80655 [file] [log] [blame]
Skyler Grey252927a2022-10-18 22:18:15 +01001{ pkgs, ... }: {
Skyler Grey7418e822022-09-01 23:57:06 +01002 # Basic shell scripting utilities, they don't deserve their own file but I use
3 # them
Skyler Grey341ba3c2022-10-31 00:09:34 +00004 config = {
5 environment.systemPackages = with pkgs; [
6 jq
7 bc
8 (sd.overrideAttrs (oldAttrs: {
9 postInstall = ''
10 mv $out/bin/sd $out/bin/s
11 '';
12 }))
13 lnav
14 dogdns
15 iproute2
Skyler Grey341ba3c2022-10-31 00:09:34 +000016 fd
17 procs
18 grex
Skyler Greycb2e9482022-10-31 00:15:16 +000019 btop
20 rustscan
Skyler Grey5385f042022-10-31 00:24:37 +000021 gping
Skyler Greybb2e74c2023-01-26 00:50:09 +000022 curlie
Skyler Grey341ba3c2022-10-31 00:09:34 +000023 ];
Skyler Grey341ba3c2022-10-31 00:09:34 +000024 };
Skyler Grey59e2ebe2022-09-04 19:14:20 +010025
26 home = {
27 programs = {
28 exa.enable = true;
29 bat.enable = true;
30 zsh.initExtra = ''
Skyler Grey1010db92022-09-05 03:21:48 +010031 function ls {
32 if [ -t 1 ] ; then
33 ${pkgs.exa}/bin/exa --icons -lghF --git --group-directories-first --color always "$@" | less --quit-if-one-screen
34 else
35 ${pkgs.coreutils}/bin/ls "$@"
36 fi
37 }
38 unalias ls
Skyler Grey59e2ebe2022-09-04 19:14:20 +010039 '';
40 };
41 home.shellAliases = {
42 cat = "${pkgs.bat}/bin/bat --wrap never --pager \"less -+S\"";
Skyler Grey341ba3c2022-10-31 00:09:34 +000043 dig = "${pkgs.dogdns}/bin/dog";
44 ip = "${pkgs.iproute2}/bin/ip -c --brief";
45 ipo = "${pkgs.iproute2}/bin/ip";
Skyler Grey341ba3c2022-10-31 00:09:34 +000046 ps = "${pkgs.procs}/bin/procs";
Skyler Greycb2e9482022-10-31 00:15:16 +000047 htop = "${pkgs.btop}/bin/btop";
Skyler Greyc07d8e72022-10-31 00:33:48 +000048 ping = "${pkgs.gping}/bin/gping";
49 pingo = "${pkgs.inetutils}/bin/ping";
Skyler Greybb2e74c2023-01-26 00:50:09 +000050 curl = "${pkgs.curlie}/bin/curlie";
51 curio = "${pkgs.curl}/bin/curl";
Skyler Greyf09390e2022-11-02 08:11:29 +000052 nix-provider = "${./utilities/nix-provider.sh}";
Skyler Grey59e2ebe2022-09-04 19:14:20 +010053 };
54 };
Skyler Grey7418e822022-09-01 23:57:06 +010055}