Skip to content

Commit

Permalink
Add homebrew path early
Browse files Browse the repository at this point in the history
  • Loading branch information
statico committed Dec 28, 2024
1 parent e50ee60 commit d8c6436
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions .zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ _force_prepend_to_path /usr/local/bin
_force_prepend_to_path ~/bin
_append_to_path /usr/sbin

# Add Homebrew early
if [ -x /opt/homebrew/bin/brew ]; then
eval "$(/opt/homebrew/bin/brew shellenv)"
fi

# ALIASES {{{1

alias Ac='sudo apt autoclean'
Expand Down Expand Up @@ -126,6 +131,7 @@ alias dcrs='dc pull ; dc down ; dc up -d'
alias dls='dpkg -L'
alias dpwd='docker run --rm -v "$(pwd):$(pwd)" -w "$(pwd)" -u "$(id -u):$(id -g)" -it'
alias dsl='dpkg -l | grep -i'
alias exifclear='exiftool -overwrite_original -all='
alias f1="awk '{print \$1}'"
alias f2="awk '{print \$2}'"
alias f2k9='f2k -9'
Expand Down Expand Up @@ -316,21 +322,19 @@ elif _try df -h ~; then
alias df='df -h'
fi

# We should definitely have Gnu coreutils, right?
if _try ls --color; then
alias ls='ls --color'
fi

# strace-like equivalent on macOS
if _has dtruss && ! _has strace; then
alias strace='sudo dtruss -f sudo -u $USER'
fi

# eza is a fancy replacement for ls
if _has eza ; then
# eza is a fancy replacement for ls
alias ls=eza
alias l='ls -lg'
alias ltr='eza -lgr -sold'
elif _try ls --color; then
# We should definitely have Gnu coreutils, right?
alias ls='ls --color'
fi

# Try to get some version of tac
Expand Down

0 comments on commit d8c6436

Please sign in to comment.