bin: more tiny helpers

This commit is contained in:
xeruf 2023-04-12 08:35:48 +02:00
parent 9cd3d2df9d
commit c416ee3695
4 changed files with 9 additions and 3 deletions

View File

@ -28,8 +28,9 @@ status() {
fi fi
} }
alias u="$sudo apt update && $sudo apt upgrade" __u="$sudo apt update && $sudo apt upgrade"
alias ur="u && $sudo reboot" alias u="$__u"
alias ur="tmux new-session -s upgrade '$__u && $sudo reboot'"
# Diff recursively # Diff recursively
difr() { diff --color=always --unified=1 --recursive "$@" | less --RAW-CONTROL-CHARS --quit-on-intr --quit-if-one-screen; } difr() { diff --color=always --unified=1 --recursive "$@" | less --RAW-CONTROL-CHARS --quit-on-intr --quit-if-one-screen; }

3
.local/bin/scripts/save Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh -e
sleep "$@"
systemctl suspend

2
.local/bin/scripts/vpn Executable file
View File

@ -0,0 +1,2 @@
#!/bin/sh -e
tmux new-session -s "$@" "sudo openvpn $@"

View File

@ -65,7 +65,7 @@ and configuration for ~less~ and ~fzf~.
* Package Setup (moving to [[https://git.jfischer.org/xeruf/instalee][Instalee]]) * Package Setup (moving to [[https://git.jfischer.org/xeruf/instalee][Instalee]])
By Size: By Size:
: LC_ALL=C pacman -Qi | awk '/^Name/{name=$3} /^Installed Size/{print $4$5, name}' | sort -h : LC_ALL=C pacman -Qi | awk '/^Name/{name=$3} /^Installed Size/{print $4$5, name}' | sort -h
Copy list: Copy list of in stalled packages:
: pacman -Qe | cut -d\ -f1 | xclip -selection clipboard : pacman -Qe | cut -d\ -f1 | xclip -selection clipboard
- dotfiles :: yadm - dotfiles :: yadm
: yadm clone --bootstrap git@git.jfischer.org:xeruf/dotfiles.git : yadm clone --bootstrap git@git.jfischer.org:xeruf/dotfiles.git