gentoo-dots/.config/zsh/aliases.zsh

63 lines
2.8 KiB
Bash
Raw Normal View History

2023-04-30 17:36:12 +02:00
#!/bin/sh
# Check ssd state
alias ssd-check="sudo smartctl -a /dev/nvme0n1 | grep -E -- 'Data Units Read:|Data Units Written:|Percentage Used:'"
# Adding colours to some of the regulas shit
alias grep='grep --color=auto'
2023-09-14 14:02:16 +02:00
alias ls='/usr/bin/eza -lab --icons --group-directories-first --git --no-time'
2023-04-30 17:36:12 +02:00
alias cp='cp -iv'
alias rm='rm -iv'
alias mkd='mkdir -pv'
alias tree='tree -C'
alias less='less -R'
[ "$TERM" = "xterm-kitty" ] && alias ssh="kitty +kitten ssh"
# Easier to type
alias vi='nvim'
2023-11-07 18:45:21 +01:00
alias nnn='LC_COLLATE="C" nnn -xeaG'
2023-04-30 17:36:12 +02:00
2024-01-08 16:15:55 +01:00
# Installing packages
alias i='sudo emerge -av $(EIX_LIMIT=0 eix --only-names | fzf --multi | tr "\n" " ")'
2023-04-30 17:36:12 +02:00
# Humna readable + better output
alias df='df -h -x devtmpfs -x tmpfs -x usbfs -x loop'
alias free='free -m -h'
# Just cause I can't remember the command at all
2023-08-23 19:51:32 +02:00
alias update-grub='sudo grub-mkconfig -o /boot/grub/grub.cfg'
2023-04-30 17:36:12 +02:00
# Quickly see the hogger in the directory
alias dust='du -hd1 | sort -hr | sed "s/.\///g" | sed "/\.$/d"'
# Who want to remember this long ass commands
2023-11-23 15:06:25 +01:00
alias ytao='yt-dlp -f "bestaudio/best" -ciw -o "%(title)s.%(ext)s" -v --extract-audio --embed-metadata'
alias ytaop='yt-dlp -f "bestaudio/best" -ciw -o "%(playlist_title)s/%(title)s.%(ext)s" -v --extract-audio --embed-metadata'
alias ytam='yt-dlp -f "bestaudio/best" -ciw -o "%(title)s.%(ext)s" -v --extract-audio --audio-quality 0 --audio-format mp3 --embed-metadata'
2023-04-30 17:36:12 +02:00
alias ytvb='yt-dlp --merge-output-format mp4 -f "bestvideo+bestaudio[ext=m4a]/best" --embed-thumbnail --external-downloader aria2c --external-downloader-args "-j 16 -s 16 -x 16 -k 5M" --add-metadata -o "%(title)s.%(ext)s"'
alias ytvf='yt-dlp --merge-output-format mp4 --format best --embed-thumbnail --external-downloader aria2c --external-downloader-args "-j 16 -s 16 -x 16 -k 5M" --add-metadata -o "%(title)s.%(ext)s"'
# Nice
alias dl='aria2c -j 16 -s 16 -x 16 -k 5M --file-allocation=none'
alias b='buku --suggest'
2023-09-04 20:25:14 +02:00
# ntfy aliases
alias ntfy='curl -u ":$(cat .config/ntfy/access_token)"'
alias update_done='curl -u ":$(cat .config/ntfy/access_token)" -H "t: System update" -d "System update is finished" ntfy.cronyakatsuki.xyz/portage'
alias update_failed='curl -u ":$(cat .config/ntfy/access_token)" -H "t: System update" -H "p:4" -d "System update failed" ntfy.cronyakatsuki.xyz/portage'
alias sync_done='curl -u ":$(cat .config/ntfy/access_token)" -H "t: System sync" -d "System sync is finished" ntfy.cronyakatsuki.xyz/portage'
2023-04-30 17:36:12 +02:00
# cryptography
alias rot13="tr 'A-Za-z' 'N-ZA-Mn-za-m'"
2023-10-22 11:35:02 +02:00
# for tmux
alias td="tmux new -s $(basename $(pwd))"
alias tu="tmux -f ~/.config/tmux/update.conf attach"
2023-11-07 18:45:21 +01:00
alias irssi="tmux attach -t irssi || tmux new -s irssi irssi"
alias xboxdrv='tmux attach -t xboxdrv ||\
tmux new -s xboxdrv xboxdrv --config $HOME/.config/xboxdrv/hyperx-clutch.conf\
--type xbox --detach-kernel-driver --silent'
2024-01-08 16:16:21 +01:00
# config cleanup
alias mbsync='mbsync -c "$XDG_CONFIG_HOME"/isync/mbsyncrc'