Skip to content

Commit 1d7d521

Browse files
committed
WIP customizing dotfilles
1 parent 306d24e commit 1d7d521

12 files changed

+66
-237
lines changed

.aliases

+20-22
Original file line numberDiff line numberDiff line change
@@ -63,12 +63,6 @@ alias ips="ifconfig -a | grep -o 'inet6\? \(addr:\)\?\s\?\(\(\([0-9]\+\.\)\{3\}[
6363
# Show active network interfaces
6464
alias ifactive="ifconfig | pcregrep -M -o '^[^\t:]+:([^\n]|\n\t)*status: active'"
6565

66-
# Flush Directory Service cache
67-
alias flush="dscacheutil -flushcache && killall -HUP mDNSResponder"
68-
69-
# Clean up LaunchServices to remove duplicates in the “Open With” menu
70-
alias lscleanup="/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user && killall Finder"
71-
7266
# Canonical hex dump; some systems have this symlinked
7367
command -v hd > /dev/null || alias hd="hexdump -C"
7468

@@ -83,9 +77,6 @@ jscbin="/System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources
8377
[ -e "${jscbin}" ] && alias jsc="${jscbin}";
8478
unset jscbin;
8579

86-
# Trim new lines and copy to clipboard
87-
alias c="tr -d '\n' | pbcopy"
88-
8980
# Recursively delete `.DS_Store` files
9081
alias cleanup="find . -type f -name '*.DS_Store' -ls -delete"
9182

@@ -109,11 +100,6 @@ alias urlencode='python -c "import sys, urllib as ul; print ul.quote_plus(sys.ar
109100
# Usage: `mergepdf input{1,2,3}.pdf`
110101
alias mergepdf='gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=_merged.pdf'
111102

112-
# Disable Spotlight
113-
alias spotoff="sudo mdutil -a -i off"
114-
# Enable Spotlight
115-
alias spoton="sudo mdutil -a -i on"
116-
117103
# PlistBuddy alias, because sometimes `defaults` just doesn’t cut it
118104
alias plistbuddy="/usr/libexec/PlistBuddy"
119105

@@ -130,14 +116,6 @@ for method in GET HEAD POST PUT DELETE TRACE OPTIONS; do
130116
alias "${method}"="lwp-request -m '${method}'"
131117
done
132118

133-
# Stuff I never really use but cannot delete either because of http://xkcd.com/530/
134-
alias stfu="osascript -e 'set volume output muted true'"
135-
alias pumpitup="osascript -e 'set volume output volume 100'"
136-
137-
# Kill all the tabs in Chrome to free up memory
138-
# [C] explained: http://www.commandlinefu.com/commands/view/402/exclude-grep-from-your-grepped-output-of-ps-alias-included-in-description
139-
alias chromekill="ps ux | grep '[C]hrome Helper --type=renderer' | grep -v extension-process | tr -s ' ' | cut -d ' ' -f2 | xargs kill"
140-
141119
# Lock the screen (when going AFK)
142120
alias afk="/System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession -suspend"
143121

@@ -146,3 +124,23 @@ alias reload="exec ${SHELL} -l"
146124

147125
# Print each PATH entry on a separate line
148126
alias path='echo -e ${PATH//:/\\n}'
127+
128+
# Firebase CLI aliases
129+
alias fbenv="firebase functions:config:get"
130+
alias fbl="firebase projects:list"
131+
alias fbs="firebase serve --only hosting,functions"
132+
alias fbsh="firebase serve --only hosting"
133+
alias fbsf="firebase serve --only functions"
134+
alias fbd="firebase deploy"
135+
alias fbdf="firebase deploy --only functions"
136+
alias fbdh="firebase deploy --only hosting"
137+
alias fbcenv="firebase functions:config:get > .runtimeconfig.json"
138+
139+
# iCloud Directory alias
140+
alias ic="cd ~/Library/Mobile\ Documents/com~apple~CloudDocs"
141+
142+
# GitTower alias
143+
alias gt="gittower ."
144+
145+
# Git aliases
146+
alias gloga="glog --all"

.exports

-3
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,3 @@ export MANPAGER='less -X';
3232
# Avoid issues with `gpg` as installed via Homebrew.
3333
# https://stackoverflow.com/a/42265848/96656
3434
export GPG_TTY=$(tty);
35-
36-
# Hide the “default interactive shell is now zsh” warning on macOS.
37-
export BASH_SILENCE_DEPRECATION_WARNING=1;

.gitconfig

+14-2
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,15 @@
33
# View abbreviated SHA, description, and history graph of the latest 20 commits.
44
l = log --pretty=oneline -n 20 --graph --abbrev-commit
55

6+
# View short log
7+
shorty = status --short --branch
8+
69
# View the current working tree status using the short format.
710
s = status -s
811

12+
# Show diff of staged files
13+
diffc = diff --cached
14+
915
# Show the diff between the latest commit and the current state.
1016
d = !"git diff-index --quiet HEAD -- || clear; git --no-pager diff --patch-with-stat"
1117

@@ -18,6 +24,12 @@
1824
# Clone a repository including all submodules.
1925
c = clone --recursive
2026

27+
# Commit
28+
ci = commit
29+
30+
# Branch
31+
br = branch
32+
2133
# Commit all changes.
2234
ca = !git add -A && git commit -av
2335

@@ -120,8 +132,8 @@
120132

121133
[color "status"]
122134

123-
added = yellow
124-
changed = green
135+
added = green
136+
changed = red
125137
untracked = cyan
126138

127139
[commit]

.hgignore

-17
This file was deleted.

.inputrc

-40
This file was deleted.

.path

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
export PATH="$PATH:$HOME/.fastlane/bin"
2+
PATH=$PATH:/usr/local/mysql/bin
3+
PATH=$PATH:/usr/local/bin:$PATH"
4+
PATH=$PATH:$ANDROID_HOME/emulator
5+
PATH=$PATH:$ANDROID_HOME/tools
6+
PATH=$PATH:$ANDROID_HOME/tools/bin
7+
PATH=$PATH:$ANDROID_HOME/platform-tools

.screenrc

-8
This file was deleted.

.tmux.conf

-11
This file was deleted.

.wgetrc

-38
This file was deleted.

.zshrc

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Path to your oh-my-zsh installation.
2+
export ZSH=/Users/mwahlig/.oh-my-zsh
3+
4+
# Set name of the theme to load. Optionally, if you set this to "random"
5+
# it'll load a random theme each time that oh-my-zsh is loaded.
6+
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
7+
ZSH_THEME="typewritten"
8+
9+
plugins=(git osx zsh-syntax-highlighting)
10+
11+
# Load oh-my-zsh
12+
source $ZSH/oh-my-zsh.sh
13+
14+
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
15+
16+
export NVM_DIR="$HOME/.nvm"
17+
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
18+
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
19+
20+
# The next line updates PATH for the Google Cloud SDK.
21+
if [ -f '/Users/mwahlig/google-cloud-sdk/path.zsh.inc' ]; then . '/Users/mwahlig/google-cloud-sdk/path.zsh.inc'; fi
22+
23+
# The next line enables shell command completion for gcloud.
24+
if [ -f '/Users/mwahlig/google-cloud-sdk/completion.zsh.inc' ]; then . '/Users/mwahlig/google-cloud-sdk/completion.zsh.inc'; fi

brew.sh

+1-55
Original file line numberDiff line numberDiff line change
@@ -11,85 +11,31 @@ brew upgrade
1111
# Save Homebrew’s installed location.
1212
BREW_PREFIX=$(brew --prefix)
1313

14-
# Install GNU core utilities (those that come with macOS are outdated).
15-
# Don’t forget to add `$(brew --prefix coreutils)/libexec/gnubin` to `$PATH`.
16-
brew install coreutils
17-
ln -s "${BREW_PREFIX}/bin/gsha256sum" "${BREW_PREFIX}/bin/sha256sum"
18-
19-
# Install some other useful utilities like `sponge`.
20-
brew install moreutils
21-
# Install GNU `find`, `locate`, `updatedb`, and `xargs`, `g`-prefixed.
22-
brew install findutils
23-
# Install GNU `sed`, overwriting the built-in `sed`.
24-
brew install gnu-sed --with-default-names
25-
# Install a modern version of Bash.
26-
brew install bash
27-
brew install bash-completion2
28-
29-
# Switch to using brew-installed bash as default shell
30-
if ! fgrep -q "${BREW_PREFIX}/bin/bash" /etc/shells; then
31-
echo "${BREW_PREFIX}/bin/bash" | sudo tee -a /etc/shells;
32-
chsh -s "${BREW_PREFIX}/bin/bash";
33-
fi;
34-
3514
# Install `wget` with IRI support.
3615
brew install wget --with-iri
3716

3817
# Install GnuPG to enable PGP-signing commits.
39-
brew install gnupg
18+
# brew install gnupg
4019

4120
# Install more recent versions of some macOS tools.
4221
brew install vim --with-override-system-vi
4322
brew install grep
4423
brew install openssh
45-
brew install screen
4624
brew install php
47-
brew install gmp
4825

4926
# Install font tools.
5027
brew tap bramstein/webfonttools
5128
brew install sfnt2woff
5229
brew install sfnt2woff-zopfli
5330
brew install woff2
5431

55-
# Install some CTF tools; see https://github.com/ctfs/write-ups.
56-
brew install aircrack-ng
57-
brew install bfg
58-
brew install binutils
59-
brew install binwalk
60-
brew install cifer
61-
brew install dex2jar
62-
brew install dns2tcp
63-
brew install fcrackzip
64-
brew install foremost
65-
brew install hashpump
66-
brew install hydra
67-
brew install john
68-
brew install knock
69-
brew install netpbm
70-
brew install nmap
71-
brew install pngcheck
72-
brew install socat
73-
brew install sqlmap
74-
brew install tcpflow
75-
brew install tcpreplay
76-
brew install tcptrace
77-
brew install ucspi-tcp # `tcpserver` etc.
78-
brew install xpdf
79-
brew install xz
80-
8132
# Install other useful binaries.
8233
brew install ack
8334
#brew install exiv2
8435
brew install git
8536
brew install git-lfs
8637
brew install gs
8738
brew install imagemagick --with-webp
88-
brew install lua
89-
brew install lynx
90-
brew install p7zip
91-
brew install pigz
92-
brew install pv
9339
brew install rename
9440
brew install rlwrap
9541
brew install ssh-copy-id

0 commit comments

Comments
 (0)