bin: update application utilities

This commit is contained in:
xeruf 2021-09-20 21:34:00 +02:00
parent 39fab808f7
commit 1bbcd1efc9
4 changed files with 18 additions and 3 deletions

View File

@ -130,6 +130,10 @@ alias jcj='jcl -o json-pretty -u'
# Applications {{{1
# Remote
alias delta="sc restart openvpn-client@deltaPeak.service"
alias sshl="lemonade server -allow 127.0.0.1 & ssh -R 2489:127.0.0.1:2489"
alias calc='rlwrap -a bc -l'
alias logoff="loginctl terminate-user $USER"
blues() { bluedevil-sendfile $(echo "$@" | xargs -n 1 realpath | xargs -n 1 echo -n " --files") }
@ -175,7 +179,6 @@ hex() { hexyl "$@" | "${PAGER:-less}" }
alias dict="rdictcc -d $XDG_DATA_HOME/dictcc"
alias dictu="dict -i $XDG_DATA_HOME/dictcc/dict.txt"
alias startMinecraftServer='curl https://ipinfo.io/ip | xclip -sel clip && cd ~/daten/games/sharedgames/minecraft/server && java -jar forge-1.12.2-14.23.5.2768-universal.jar -mx 8G'
alias delta="sc start openvpn-client@deltaPeak.service"
alias u='topgrade'

View File

@ -20,6 +20,7 @@ case "$sel" in
/etc/sudoers) sudo visudo;;
/etc/fstab) sudoedit "$sel" && sudo findmnt --verify;;
/etc/default/grub) sudoedit "$sel" && sudo grub-mkconfig -o /boot/grub/grub.cfg;;
/etc/locale.gen) sudoedit "$sel" && sudo locale-gen;;
*) edit "$sel";;
esac
echo "$sel" | cat - "$conf_cache" | head -20 >"$conf_tmp" && mv "$conf_tmp" "$conf_cache"

6
.local/bin/scripts/ffmeta Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
# Extract song metadata with ffprobe
while read f; do
highlight "$f"
ffprobe "$f" 2>&1 | grep -A90 'Metadata:'
done | less

View File

@ -1,10 +1,15 @@
#!/bin/sh -e
aurdir="$DATA/2-standards/dev/aur"
test $# -eq 0 && cd "$aurdir" && exec $SHELL
command=$1
shift
url="ssh://aur@aur.archlinux.org/${1:-$(basename $PWD)}.git"
case $command in
(origin)
test "$(git rev-parse --git-dir)" = ".git" && git remote set-url origin "$url";;
(clone)
cd "$DATA/2-standards/dev/aur"
git -c init.defaultBranch=master clone ssh://aur@aur.archlinux.org/$1.git
cd "$aurdir"
git -c init.defaultBranch=master clone "$url"
cd "$1"
test -f PKGBUILD || sed "s/PKG/${1%%-git}/" ../PKGBUILD > PKGBUILD
test -f .gitignore || echo '*' > .gitignore