alias df='/usr/bin/df -h --output=target,fstype,used,avail,pcent,source | sort -n'
alias du='du -h'
alias fastfetch='fastfetch -c "$HOME/.config/fastfetch/default.jsonc"'
-alias grep='command grep -si --color=auto'
+alias ff='fastfetch'
+alias grep='command grep -sil --color=auto'
alias gdi='git diff '
alias gg='cd "$(git rev-parse --show-toplevel)"'
alias gco='git checkout'
# No double entries in the shell history.
export HISTCONTROL="$HISTCONTROL erasedups:ignoreboth"
-# Wrap the following commands for interactive use to avoid accidental file overwrites.
-rm() { command rm -i "${@}"; }
-cp() { command cp -i "${@}"; }
-mv() { command mv -i "${@}"; }
-
-# enable moving between directories without cd
-shopt -s autocd
-# enable spelling correction
-shopt -s dirspell
-# enable case-insensitivity
-shopt -s nocaseglob
-# expand filename patterns without match to a null string
-shopt -s nullglob
-
# Change working dir in shell to last dir in lf on exit (adapted from ranger).
lfcd () {
# `command` is needed in case `lfcd` is aliased to `lf`
}
# Put your fun stuff here.
-#
-# just set a minimal prompt in bash and use starship instead
-PS1='\u@\h \w \$ '
-command -v starship > /dev/null 2>&1 && eval "$(starship init bash)"
+if [ -t 0 ]; then
+ # Wrap the following commands for interactive use to avoid accidental file overwrites.
+ rm() { command rm -i "${@}"; }
+ cp() { command cp -i "${@}"; }
+ mv() { command mv -i "${@}"; }
-# apply base16 theme in X/Wayland session only, or flavours' plasma-hook hangs:
-case $(tty) in
- /dev/tty[0-9]*)
- command -v ttyscheme > /dev/null 2>&1 && ttyscheme onedark
- clear
- test -e /usr/bin/fastfetch && command fastfetch -c "$HOME/.config/fastfetch/default.jsonc" || true
- ;;
- /dev/pts/[0-9]*)
- command -v base16-flavours > /dev/null 2>&1 && ~/.local/bin/base16-flavours || true
- clear
- test -e /usr/bin/fastfetch && command fastfetch -c "$HOME/.config/fastfetch/default.jsonc" || true
- ;;
-esac
+ # enable moving between directories without cd
+ shopt -s autocd
+ # enable spelling correction
+ shopt -s dirspell
+ # enable case-insensitivity
+ shopt -s nocaseglob
+ # expand filename patterns without match to a null string
+ shopt -s nullglob
+
+ # just set a minimal prompt in bash and use starship instead
+ PS1='\u@\h \w \$ '
+ command -v starship > /dev/null 2>&1 && eval "$(starship init bash)"
+
+ # apply base16 theme in X/Wayland session only, or flavours' plasma-hook hangs:
+ case $(tty) in
+ /dev/tty[0-9]*)
+ command -v ttyscheme > /dev/null 2>&1 && ttyscheme c64
+ test -e /usr/bin/fastfetch && command fastfetch -c "$HOME/.config/fastfetch/default.jsonc" || true
+ ;;
+ /dev/pts/[0-9]*)
+ # command -v base16-flavours > /dev/null 2>&1 && ~/.local/bin/base16-flavours || true
+ test -e /usr/bin/fastfetch && command fastfetch -c "$HOME/.config/fastfetch/default.jsonc" || true
+ ;;
+ esac
+fi