1
0

move mnt to oneliners

This commit is contained in:
Deven Blake 2021-06-28 09:52:00 -04:00
parent fef21ea398
commit 2a35af964d
2 changed files with 11 additions and 13 deletions

View File

@ -11,13 +11,6 @@ alias e="$EDITOR"
alias ipconfig="ifconfig"
#alias ls="9 ls"
alias ls="ls -1A"
# other volumes
mnt() {
test -d /mnt/$1 || sudo mkdir /mnt/$1
sudo mount /dev/$1 /mnt/$1 && cd /mnt/$1
}
alias mv="mv -iv"
alias p="ping 1.1.1.1"

View File

@ -29,17 +29,22 @@ printf $SHEBANG'xrandr --output VGA-1 --auto --right-of LVDS-1\n
printf $SHEBANG"xrandr --output HDMI-1 --off\n" >hdmioff
printf $SHEBANG"xrandr --output VGA-1 --off\n" >vgaoff
# mounting volumes
printf $SHEBANG"[ -z \"\$1\" ] && printf 'Usage: %%b [device]\\\\n' \"\$0\" && exit 1 || true
[ -d \"/mnt/\$1\" ] || $SUDO mkdir \"/mnt/\$1\"
$SUDO mount \"/dev/\$1\" \"/mnt/\$1\" && cd \"/mnt/\$1\"\n" >mnt
# wireguard vpn stuff
printf $BASH_SHEBANG$SUDO' wg-quick up "$@"\n' >vpn-connect
printf $BASH_SHEBANG$SUDO' wg-quick down "$@"\n' >vpn-disconnect
printf $SHEBANG$SUDO' wg-quick up "$@"\n' >vpn-connect
printf $SHEBANG$SUDO' wg-quick down "$@"\n' >vpn-disconnect
printf $SHEBANG$SUDO' ls /etc/wireguard/ | grep "conf$" | awk -F ".conf" "{print $1}"\n' >vpn-list
printf $SHEBANG'xterm -e "vpn-connect $(vpn-list | dmenu); read -s -n 1"\n' >vpn-quick # not to be confused with wg-quick
# youtube-dl stuff
printf $BASH_SHEBANG"youtube-dl --add-metadata -i -o \"$HOME/%%(upload_date)s %%(title)s.%%(ext)s\" \"\$@\"\n" >youtube-dlo
printf $BASH_SHEBANG"youtube-dlo -f \"bestvideo[vcodec=vp9]+bestaudio[acodec=opus]\" \"\$@\"\n" >youtube-dlp
printf $BASH_SHEBANG"youtube-dlp -f \$(youtube-dl -F \$1 | tail +4 | dmenu -p \"Choose a format.\" -l $DMENU_LINES | awk '{ print \$1 }') \"\$@\"\n" >youtube-dl-interactive
printf $BASH_SHEBANG"youtube-dl-interactive \"\$@\" -o - | mpv -\n" >youtube-dl-mpv
printf $SHEBANG"youtube-dl --add-metadata -i -o \"$HOME/%%(upload_date)s %%(title)s.%%(ext)s\" \"\$@\"\n" >youtube-dlo
printf $SHEBANG"youtube-dlo -f \"bestvideo[vcodec=vp9]+bestaudio[acodec=opus]\" \"\$@\"\n" >youtube-dlp
printf $SHEBANG"youtube-dlp -f \$(youtube-dl -F \$1 | tail +4 | dmenu -p \"Choose a format.\" -l $DMENU_LINES | awk '{ print \$1 }') \"\$@\"\n" >youtube-dl-interactive
printf $SHEBANG"youtube-dl-interactive \"\$@\" -o - | mpv -\n" >youtube-dl-mpv
# sxhkd
printf $SHEBANG"cd '$HOME/.config/sxhkd/'