# ░█▀█░█░░░▀█▀░█▀█░█▀▀░█▀▀░█▀▀ # ░█▀█░█░░░░█░░█▀█░▀▀█░█▀▀░▀▀█ # ░▀░▀░▀▀▀░▀▀▀░▀░▀░▀▀▀░▀▀▀░▀▀▀ alias gs='git status' alias kaicd='cd "$VAULT_PATH/08. Notes/Children/02. Kai"' ## II. File checksum verification ## alias verify1='openssl sha1' alias verify256='openssl dgst -sha256' ## III. Easier navigation: .., ..., ...., and ..... alias ..="cd .." alias ...="cd ../.." alias ....="cd ../../.." alias .....="cd ../../../.." ## IV. Shortcuts alias dl="cd ~/Downloads" alias dt="cd ~/Desktop" alias docs="cd ~/Documents" # use eza alias ls='eza --color=auto --group-directories-first --icons' alias ll='eza -lgh --git' alias la='eza -la --git' alias lt='eza --tree' # use coreutils ls # alias ls='gls --color=auto' # List all files in long format # alias l="gls -lF --color=auto" # List all files in long format, excluding . and .. # alias la="gls -lAF --color=auto" # List only directories # alias lsd="gls -lF | grep --color=never '^d'" # alias ll='gls -lah --color=aut' # view man pages with bat (replaced by enhanced man function in functions.zsh) # alias batman='man -P "bat -l man -p"' # Batman now uses the enhanced man function (opens in new window) alias batman='man' # Get macOS Software Updates, and update installed Ruby gems, Homebrew, npm, and their installed packages alias update="read -q 'REPLY?Run full system update? (y/n) ' && echo && sysupdate || echo 'Aborted.'" # Maintenance scripts alias mrclean='sudo periodic daily weekly monthly' # Download using cURL alias dl="curl -O" # yt-dlp at best quility and in .mp4 format alias yt="yt-dlp -S res,ext:mp4:m4a --recode mp4" # Internet speed test with Cloudfare CLI alias speed="npx speed-cloudflare-cli" # IP addresses alias ip="dig +short myip.opendns.com @resolver1.opendns.com" alias localip="ipconfig getifaddr en0" alias ips="ifconfig -a | grep -o 'inet6\? \(addr:\)\?\s\?\(\(\([0-9]\+\.\)\{3\}[0-9]\+\)\|[a-fA-F0-9:]\+\)' | awk '{ sub(/inet6? (addr:)? ?/, \"\"); print }'" # Clean up LaunchServices to remove duplicates in the “Open With” menu alias lscleanup="/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user && killall Finder" # Recursively delete `.DS_Store` files alias cleanup="find . -type f -name '*.DS_Store' -ls -delete" # Empty the Trash on all mounted volumes and the main HDD. # Also, clear Apple’s System Logs to improve shell startup speed. # Finally, clear download history from quarantine. https://mths.be/bum alias emptytrash="sudo rm -rfv /Volumes/*/.Trashes; sudo rm -rfv ~/.Trash; sudo rm -rfv /private/var/log/asl/*.asl; sqlite3 ~/Library/Preferences/com.apple.LaunchServices.QuarantineEventsV* 'delete from LSQuarantineEvent'" # Show/hide hidden files in Finder alias show="defaults write com.apple.finder AppleShowAllFiles -bool true && killall Finder" alias hide="defaults write com.apple.finder AppleShowAllFiles -bool false && killall Finder" # Disable Spotlight alias spotoff="sudo mdutil -a -i off" # Enable Spotlight alias spoton="sudo mdutil -a -i on" # Lock the screen (when going AFK) alias afk="/System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession -suspend" # Access quicklook from terminal alias ql="qlmanage -p " ## CapableMind alias cm="cd ~/_Dev/CapableMind-AI" alias bmf="cd ~/_Dev/BetterMemories.io" alias bmf-health="curl -s http://localhost:3011/health | python3 -m json.tool" alias bmf-status="curl -s http://localhost:3011/health | python3 -c \"import sys,json;d=json.load(sys.stdin);cursors={k:v['cursor_position'] for k,v in d['modules'].items()};errors={k:v['error_count'] for k,v in d['modules'].items() if v['error_count']>0};print(f'Vector: {cursors[\\\"vector\\\"]} errors={d[\\\"modules\\\"][\\\"vector\\\"][\\\"error_count\\\"]}');print(f'Max cursor: {max(cursors.values())}');errors and print(f'Errors: {errors}')\"" alias bmf-logs="tail -50 ~/.capablemind/logs/bmf.stderr.log" alias bmf-errors="grep -i 'error\|deferred\|circuit\|canary\|phase' ~/.capablemind/logs/bmf.stderr.log | tail -20" ## Animal Rationis Capax alias arc="cd ~/_Dev/animal-davidglidden-eu" ## Tetris alias tetris='/opt/homebrew/opt/vitetris/bin/tetris' ## Pass license management shortcuts alias licenses='pass ls licenses/' alias license='pass show licenses/' ## Obsidian Vault push to Gitea alias gitvault='~/bin/obsidian_vault_sync.sh'