chore(hand7s): package cleaning
Signed-off-by: s0me1newithhand7s <git+me@hand7s.org>
This commit is contained in:
parent
1ab90785eb
commit
2ff7098d78
1 changed files with 72 additions and 6 deletions
|
|
@ -1,33 +1,99 @@
|
||||||
{pkgs, ...}: {
|
{pkgs, ...}: {
|
||||||
home = {
|
home = {
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
fd
|
|
||||||
gh
|
gh
|
||||||
sd
|
sd
|
||||||
xh
|
xh
|
||||||
|
viu
|
||||||
|
tdf
|
||||||
|
epr
|
||||||
dua
|
dua
|
||||||
nvd
|
nvd
|
||||||
tlrc
|
|
||||||
dust
|
dust
|
||||||
|
ouch
|
||||||
sops
|
sops
|
||||||
|
grex
|
||||||
rsync
|
rsync
|
||||||
|
hexyl
|
||||||
procs
|
procs
|
||||||
sshfs
|
sshfs
|
||||||
sbctl
|
sbctl
|
||||||
gping
|
gping
|
||||||
comma
|
comma
|
||||||
trippy
|
|
||||||
bottom
|
|
||||||
ripgrep
|
|
||||||
kubectl
|
kubectl
|
||||||
gitoxide
|
gitoxide
|
||||||
|
step-cli
|
||||||
|
hyperfine
|
||||||
deploy-rs
|
deploy-rs
|
||||||
btop-rocm
|
btop-rocm
|
||||||
bubblewrap
|
bubblewrap
|
||||||
ripgrep-all
|
microfetch
|
||||||
nixos-anywhere
|
nixos-anywhere
|
||||||
wireguard-tools
|
wireguard-tools
|
||||||
nix-output-monitor
|
nix-output-monitor
|
||||||
|
|
||||||
|
(
|
||||||
|
pkgs.writeShellApplication {
|
||||||
|
name = "safe-open";
|
||||||
|
runtimeInputs = with pkgs; [
|
||||||
|
cryptsetup
|
||||||
|
btrfs-progs
|
||||||
|
uutils-coreutils-noprefix
|
||||||
|
];
|
||||||
|
|
||||||
|
text = ''
|
||||||
|
if [ "$(id -u)" -ne 0 ]; then
|
||||||
|
printf "use sudo;" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -b /dev/sda ]; then
|
||||||
|
echo "no safe;" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
cryptsetup luksOpen /dev/sda test_safe
|
||||||
|
mkdir -p /tmp/pico_safe
|
||||||
|
mount -o compress=zstd:3,noatime,ssd /dev/mapper/test_safe /tmp/pico_safe
|
||||||
|
chown -R :wheel /tmp/pico_safe
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
pkgs.writeShellApplication {
|
||||||
|
name = "safe-close";
|
||||||
|
runtimeInputs = with pkgs; [
|
||||||
|
cryptsetup
|
||||||
|
btrfs-progs
|
||||||
|
uutils-coreutils-noprefix
|
||||||
|
uutils-util-linux
|
||||||
|
];
|
||||||
|
|
||||||
|
text = ''
|
||||||
|
if [ "$(id -u)" -ne 0 ]; then
|
||||||
|
printf "use sudo;" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if mountpoint -q /tmp/pico_safe; then
|
||||||
|
umount /tmp/pico_safe
|
||||||
|
printf "umounted"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -b /dev/mapper/test_safe ]; then
|
||||||
|
cryptsetup luksClose test_safe
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
echo "no safe!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
)
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue