[shell] Adds lots of little utilities

This commit is contained in:
2025-05-26 20:37:34 -07:00
parent 2253423fc4
commit 30ad37c30f
5 changed files with 55 additions and 22 deletions

30
flake.lock generated
View File

@@ -7,11 +7,11 @@
]
},
"locked": {
"lastModified": 1747556831,
"narHash": "sha256-Qb84nbYFFk0DzFeqVoHltS2RodAYY5/HZQKE8WnBDsc=",
"lastModified": 1748226808,
"narHash": "sha256-GaBRgxjWO1bAQa8P2+FDxG4ANBVhjnSjBms096qQdxo=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "d0bbd221482c2713cccb80220f3c9d16a6e20a33",
"rev": "83665c39fa688bd6a1f7c43cf7997a70f6a109f9",
"type": "github"
},
"original": {
@@ -28,11 +28,11 @@
]
},
"locked": {
"lastModified": 1747834438,
"narHash": "sha256-AHJt79W8wADzur2htCx1U8FtEk4XjvrHb9/3iDfNedI=",
"lastModified": 1748227609,
"narHash": "sha256-SaSdslyo6UGDpPUlmrPA4dWOEuxCy2ihRN9K6BnqYsA=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "6c2eb1e24cd0e76d88bdd633ef4c50d6286586e0",
"rev": "d23d20f55d49d8818ac1f1b2783671e8a6725022",
"type": "github"
},
"original": {
@@ -43,11 +43,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1747610100,
"narHash": "sha256-rpR5ZPMkWzcnCcYYo3lScqfuzEw5Uyfh+R0EKZfroAc=",
"lastModified": 1748162331,
"narHash": "sha256-rqc2RKYTxP3tbjA+PB3VMRQNnjesrT0pEofXQTrMsS8=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "ca49c4304acf0973078db0a9d200fd2bae75676d",
"rev": "7c43f080a7f28b2774f3b3f43234ca11661bf334",
"type": "github"
},
"original": {
@@ -59,11 +59,11 @@
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1747744144,
"narHash": "sha256-W7lqHp0qZiENCDwUZ5EX/lNhxjMdNapFnbErcbnP11Q=",
"lastModified": 1748190013,
"narHash": "sha256-R5HJFflOfsP5FBtk+zE8FpL8uqE7n62jqOsADvVshhE=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "2795c506fe8fb7b03c36ccb51f75b6df0ab2553f",
"rev": "62b852f6c6742134ade1abdd2a21685fd617a291",
"type": "github"
},
"original": {
@@ -89,11 +89,11 @@
]
},
"locked": {
"lastModified": 1743756170,
"narHash": "sha256-2b11EYa08oqDmF3zEBLkG1AoNn9rB1k39ew/T/mSvbU=",
"lastModified": 1747603214,
"narHash": "sha256-lAblXm0VwifYCJ/ILPXJwlz0qNY07DDYdLD+9H+Wc8o=",
"owner": "Mic92",
"repo": "sops-nix",
"rev": "cff8437c5fe8c68fc3a840a21bf1f4dc801da40d",
"rev": "8d215e1c981be3aa37e47aeabd4e61bb069548fd",
"type": "github"
},
"original": {

View File

@@ -1,4 +1,4 @@
{ ... }:
{ pkgs, ... }:
{
imports = [
# Dev apps
@@ -13,6 +13,10 @@
./sh.nix
];
home.packages = with pkgs; [
hyperfine # Benchmarking tool
];
programs.direnv = {
enable = true;
enableBashIntegration = true;

View File

@@ -12,9 +12,6 @@
"l" = "log --oneline";
};
extraConfig = {
core = {
pager = "";
};
pull = {
rebase = true;
};
@@ -25,5 +22,7 @@
defaultBranch = "main";
};
};
# Enable the delta diff pager.
delta.enable = true;
};
}

View File

@@ -2,6 +2,10 @@
{ pkgs, ... }:
{
imports = [
./uutils.nix
];
# These are all the sort of shell commands that we want available whereever
# there is shell. These include just a lot of useful utilities for managing
# a system or working with other shell commands. Packages more specific to
@@ -20,16 +24,22 @@
p7zip
file
tree
ranger
yazi # File manager
ueberzugpp # for image previews
w3m # terminal browser for image previews
dysk # better disk info
ripgrep # better grep
fd # Better find
bat # cat with wings
eza # Modern replacement for ls
dust # More intuitive du
dua # Interactive disk usage analyzer
# Networking
dnsutils
inetutils
socat
httpie
xh
# devices
usbutils
@@ -42,7 +52,14 @@
home.shellAliases = {
"p?" = "ps ax | grep";
# Dysk is basically just better.
"df" = "dysk";
"df" = "echo 'Don't you want `dysk`?'";
"grep" = "echo 'Don't you want `rg`?'";
"find" = "echo 'Don't you want `fd`?'";
"cat" = "bat";
"ls" = "eza";
"http" = "echo 'Don't you want `xh`?'";
"du" = "echo 'Don't you want `dust` or `dua`?'";
"ranger" = "echo 'Don't you want `yazi`?'";
};
programs.zsh = {
@@ -97,6 +114,12 @@
];
};
programs.zoxide = {
# TODO: Learn all the capabilities of zoxide and use them.
enable = true;
enableZshIntegration = true;
};
programs.starship = {
enable = true;
settings = {

View File

@@ -0,0 +1,7 @@
{ pkgs, lib, ... }:
{
home.packages = with pkgs; [
# Use uutils core-utils with no prefix so they override the GNU coreutils
(lib.hiPrio uutils-coreutils-noprefix)
];
}