Files
aliases-and-functions/.shell_aliases
chawley [chawley] 619cd9212d Fixed alias for ls
Somehow I had it alised twice
2024-02-20 09:25:56 -05:00

54 lines
1.4 KiB
Plaintext

# Turn on interactive mode for dangerous commands
alias cp='cp -iv'
alias mv='mv -iv'
alias rm='rm -iv'
# File sizes should always be human-readable
alias df='df -h'
alias du='du -h'
# Greps
alias egrep='egrep --color=auto' # show differences in colour
alias fgrep='fgrep --color=auto' # show differences in colour
# File Listing
# Must have lsd installed (https://github.com/lsd-rs/lsd)
alias ls='lsd '
#alias l='ls -CF' # list with Columns
#alias la='ls -CFA' # l with . and ..
#alias ll='ls -l' # long list
#alias lla='ls -al' # ll with . and ..
#alias lls='ls -lh --sort=size --reverse'
#alias llt='ls -l -t -r'
# Extras
alias ping='ping -c 5' # Stop pinging after 5 pings
alias vi='vim' # use vim instead of vi
alias less='less -r' # repaint screen
# Get Ext IP
alias extip='curl -s -4 icanhazip.com'
# Memory Pigs (top 10)
alias mempigs='ps aux | awk '\''{print $6/1024 " MB\t\t" $11 " " $12}'\'' | sort -n | tail -10'
# Edit files with vim/fzf
alias vfz='vim "`fzf`"'
alias vimf='vim "`fzf`"'
# CD with the help of fzf
alias cdf='cd ~ && cd "$(find . -type d -print0 | fzf --read0 --print0)"'
# Do lots of things with FZF
# VIM
alias vimf='vim "`fzf`"'
# LESS
alias lessf='less "`fzf`"'
# CAT
alias catf='cat "`fzf`"'
# GLOW
alias glowf='glow "`fzf`"'