62 lines
2.0 KiB
Plaintext
62 lines
2.0 KiB
Plaintext
# Bash initialization for interactive non-login shells and
|
|
# for remote shells (info "(bash) Bash Startup Files").
|
|
|
|
# Export 'SHELL' to child processes. Programs such as 'screen'
|
|
# honor it and otherwise use /bin/sh.
|
|
export SHELL
|
|
|
|
if [[ $- != *i* ]]
|
|
then
|
|
# We are being invoked from a non-interactive shell. If this
|
|
# is an SSH session (as in "ssh host command"), source
|
|
# /etc/profile so we get PATH and other essential variables.
|
|
[[ -n "$SSH_CLIENT" ]] && source /etc/profile
|
|
|
|
# Don't do anything else.
|
|
return
|
|
fi
|
|
# settings for interactive shells
|
|
[[ $- = *i* ]] && bind '"\t":menu-complete'
|
|
|
|
# Source the system-wide file.
|
|
source /etc/bash.bashrc
|
|
|
|
# Aliases
|
|
# ALL THE COLORS
|
|
alias \
|
|
ls='ls -p --color=auto --group-directories-first' \
|
|
grep='grep --color=auto'
|
|
|
|
# Short alias modifications that we always want
|
|
alias \
|
|
ll='ls -lha' \
|
|
cp='cp -iv' \
|
|
mv='mv -iv' \
|
|
rm='rm -vI' \
|
|
..='cd ..' \
|
|
du='du -hs * | sort -h' \
|
|
df='df -ahiT --total' \
|
|
lsl='ls -lhFA' \
|
|
ps='ps auxf' \
|
|
free='free -mt' \
|
|
z='zathura'
|
|
|
|
# Shortcuts for common directories
|
|
alias \
|
|
cf='cd ${XDG_CONFIG_HOME:-$HOME/.config} && ls -a --color=auto' \
|
|
sc='cd ~/.local/spells/ && ls -a --color=auto' \
|
|
cz='cd ~/.local/share/chezmoi/ && ls -lha'
|
|
|
|
# Aliases for Self Monitoring
|
|
alias \
|
|
jr='emacsclient ~/wrt/diary/$(date +%F).md' \
|
|
stm='responseGatherer -i ~/wrt/journal/selfMonitoringPrompts/stoicThoughtMonitoring -o ~/wrt/diary/$(date +%F).md' \
|
|
sj='responseGatherer -i ~/wrt/journal/selfMonitoringPrompts/sleepJournal -o ~/wrt/diary/$(date +%F).md' \
|
|
as='responseGatherer -i ~/wrt/journal/selfMonitoringPrompts/actionSteps -o ~/wrt/diary/$(date +%F).md' \
|
|
hbps='responseGatherer -i ~/wrt/journal/selfMonitoringPrompts/healthyBoundaryPositiveStatement -o ~/wrt/diary/$(date +%F).md'
|
|
|
|
# Play a random video file from the cd
|
|
alias rnmv="mpv $(ls -p | grep -v / | shuf | head -1)"
|
|
# Download the video link in the clipboard
|
|
alias dlclp='youtube-dl --config-location .config/youtube-dl/altconfig "$(xsel -b)"'
|