aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.bash_profile10
-rwxr-xr-x.bashrc54
-rw-r--r--.gitconfig49
-rw-r--r--.iterm/com.googlecode.iterm2.plist12
-rwxr-xr-x.macos4
-rw-r--r--.path31
-rw-r--r--.zshrc41
-rwxr-xr-xbrew.sh5
8 files changed, 155 insertions, 51 deletions
diff --git a/.bash_profile b/.bash_profile
index 3659ef5..00c32ad 100644
--- a/.bash_profile
+++ b/.bash_profile
@@ -1,6 +1,12 @@
# branches and stuff in my SH
PS1='\w\[\033[0;32m\]$( git branch 2> /dev/null | cut -f2 -d\* -s | sed "s/^ / [/" | sed "s/$/]/" )\[\033[0m\] \$ '
+# Load .bashrc, which loads: ~/.{bash_prompt,aliases,functions,path,dockerfunc,extra,exports}
+if [[ -r "${HOME}/.bashrc" ]]; then
+ # shellcheck source=/dev/null
+ source "${HOME}/.bashrc"
+fi
+
# Tell grep to highlight matches
export GREP_OPTIONS='--color=auto'
@@ -8,10 +14,6 @@ export GREP_OPTIONS='--color=auto'
export CLICOLOR=1
export LSCOLORS=Exfxcxdxbxegedabagacad
-alias l='ls -l'
-# Add VSCode to PATH
-export PATH="$PATH:/Applications/Visual Studio Code.app/Contents/Resources/app/bin"
-
# Volta
export VOLTA_HOME="$HOME/.volta"
export PATH="$VOLTA_HOME/bin:$PATH"
diff --git a/.bashrc b/.bashrc
new file mode 100755
index 0000000..94cc74d
--- /dev/null
+++ b/.bashrc
@@ -0,0 +1,54 @@
+#!/bin/bash
+# ~/.bashrc: executed by bash(1) for non-login shells.
+# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
+# for examples
+
+# If not running interactively, don't do anything
+case $- in
+ *i*) ;;
+ *) return;;
+esac
+
+# Start the gpg-agent if not already running
+if ! pgrep -x -u "${USER}" gpg-agent >/dev/null 2>&1; then
+ gpg-connect-agent /bye >/dev/null 2>&1
+fi
+gpg-connect-agent updatestartuptty /bye >/dev/null
+
+# use a tty for gpg
+# solves error: "gpg: signing failed: Inappropriate ioctl for device"
+GPG_TTY=$(tty)
+export GPG_TTY
+
+# Set SSH to use gpg-agent
+unset SSH_AGENT_PID
+if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
+ if [[ -z "$SSH_AUTH_SOCK" ]] || [[ "$SSH_AUTH_SOCK" == *"apple.launchd"* ]]; then
+ SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
+ export SSH_AUTH_SOCK
+ fi
+fi
+
+# Shell
+if [ -z "$SSH_AUTH_SOCK" ] ; then
+ eval `ssh-agent -s`
+ /usr/bin/ssh-add -K
+fi
+
+# TODO: Fix /dev/fd/13:type:12979: bad option: -t issue
+# source kubectl bash completion
+# if hash kubectl 2>/dev/null; then
+# # shellcheck source=/dev/null
+# source <(kubectl completion bash)
+# fi
+
+# Set Emacs as VISUAL
+export VISUAL="emacs"
+
+for file in ~/.{aliases,path,extras}; do
+ if [[ -r "$file" ]] && [[ -f "$file" ]]; then
+ # shellcheck source=/dev/null
+ source "$file"
+ fi
+done
+unset file \ No newline at end of file
diff --git a/.gitconfig b/.gitconfig
new file mode 100644
index 0000000..f777d19
--- /dev/null
+++ b/.gitconfig
@@ -0,0 +1,49 @@
+[apply]
+ # Detect whitespace errors when applying a patch
+ whitespace = fix
+[core]
+ # Make `git rebase` safer on OS X
+ # More info: <http://www.git-tower.com/blog/make-git-rebase-safe-on-osx/>
+ trustctime = false
+ editor = emacs
+[color]
+ # Use colors in Git commands that are capable of colored output when
+ # outputting to the terminal. (This is the default setting in Git ≥ 1.8.4.)
+ ui = auto
+
+[color "branch"]
+ current = yellow reverse
+ local = yellow
+ remote = green
+
+[color "diff"]
+ meta = yellow bold
+ frag = magenta bold # line info
+ old = red # deletions
+ new = green # additions
+
+[color "status"]
+ added = yellow
+ changed = green
+ untracked = cyan
+
+[diff]
+ # Detect copies as well as renames
+ renames = copies
+[help]
+ # Automatically correct and execute mistyped commands
+ autocorrect = 1
+[merge]
+ # Include summaries of merged commits in newly created merge commit messages
+ log = true
+[commit]
+ gpgsign = true
+[pull]
+ rebase = true
+[gpg]
+ program = gpg
+[user]
+ name = Simen A. W. Olsen
+ email = so@bjerk.io
+[github]
+ user = cobraz
diff --git a/.iterm/com.googlecode.iterm2.plist b/.iterm/com.googlecode.iterm2.plist
index a7c340b..e1af3e3 100644
--- a/.iterm/com.googlecode.iterm2.plist
+++ b/.iterm/com.googlecode.iterm2.plist
@@ -4,16 +4,6 @@
<dict>
<key>AlternateMouseScroll</key>
<true/>
- <key>AppleAntiAliasingThreshold</key>
- <integer>1</integer>
- <key>ApplePressAndHoldEnabled</key>
- <false/>
- <key>AppleScrollAnimationEnabled</key>
- <integer>0</integer>
- <key>AppleSmoothFixedFontsSizeThreshold</key>
- <integer>1</integer>
- <key>AppleWindowTabbingMode</key>
- <string>manual</string>
<key>Custom Color Presets</key>
<dict>
<key>Clovis-iTerm2-Color-Scheme</key>
@@ -1177,7 +1167,7 @@
<key>Non-ASCII Anti Aliased</key>
<true/>
<key>Normal Font</key>
- <string>MesloLGMForPowerline-Regular 14</string>
+ <string>Menlo-Regular 15</string>
<key>Only The Default BG Color Uses Transparency</key>
<false/>
<key>Open Toolbelt</key>
diff --git a/.macos b/.macos
index ab3c05b..77b3d29 100755
--- a/.macos
+++ b/.macos
@@ -148,7 +148,7 @@ defaults write com.apple.BluetoothAudioAgent "Apple Bitpool Min (editable)" -int
#sudo systemsetup -settimezone "Europe/Brussels" > /dev/null
# Stop iTunes from responding to the keyboard media keys
-launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist 2> /dev/null
+#launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist 2> /dev/null
###############################################################################
# Energy saving #
@@ -167,7 +167,7 @@ sudo systemsetup -setrestartfreeze on
sudo pmset -a displaysleep 15
# Disable machine sleep while charging
-#sudo pmset -c sleep 0
+sudo pmset -c sleep 0
# Set machine sleep to 5 minutes on battery
sudo pmset -b sleep 5
diff --git a/.path b/.path
new file mode 100644
index 0000000..846c98e
--- /dev/null
+++ b/.path
@@ -0,0 +1,31 @@
+#!/bin/bash
+
+export PATH="/usr/local/sbin:$PATH"
+export GOPATH=~/go
+
+# Golang
+export PATH="$PATH:$GOPATH/bin"
+
+# Volta
+export VOLTA_HOME="$HOME/.volta"
+export PATH="$VOLTA_HOME/bin:$PATH"
+
+# Add yarn packages to PATH
+export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
+
+# The next line updates PATH for the Google Cloud SDK.
+export CLOUDSDK_PYTHON="/usr/local/opt/python@3.8/libexec/bin/python"
+
+if [ -f "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/path.zsh.inc" ]; then
+ source "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/path.zsh.inc"
+fi
+
+if [ -f "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/completion.bash.inc" ]; then
+ source "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/completion.bash.inc"
+fi
+
+# The next line updates PATH for Netlify's Git Credential Helper.
+if [ -f "$HOME/.netlify/helper/path.zsh.inc" ]; then source "$HOME/.netlify/helper/path.zsh.inc"; fi
+
+# Add VSCode to PATH
+export PATH="$PATH:/Applications/Visual Studio Code.app/Contents/Resources/app/bin" \ No newline at end of file
diff --git a/.zshrc b/.zshrc
index f75b9df..db5e0f4 100644
--- a/.zshrc
+++ b/.zshrc
@@ -12,14 +12,8 @@ ZSH_THEME="avit"
plugins=(
git
- yarn
- web-search
- jsontools
- macports
- node
- osx
+ osx
sudo
- thor
docker
)
@@ -83,31 +77,14 @@ POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
# Colorise the top Tabs of Iterm2 with the same color as background
# Just change the 18/26/33 wich are the rgb values
-echo -e "\033]6;1;bg;red;brightness;18\a"
-echo -e "\033]6;1;bg;green;brightness;26\a"
-echo -e "\033]6;1;bg;blue;brightness;33\a"
-
-# Add VSCode to PATH
-export PATH="$PATH:/Applications/Visual Studio Code.app/Contents/Resources/app/bin"
-
-# Golang
-export PATH="$PATH:$GOPATH/bin"
-
-# The next line updates PATH for Netlify's Git Credential Helper.
-if [ -f '/Users/cobraz/.netlify/helper/path.zsh.inc' ]; then source '/Users/cobraz/.netlify/helper/path.zsh.inc'; fi
+# echo -e "\033]6;1;bg;red;brightness;18\a"
+# echo -e "\033]6;1;bg;green;brightness;26\a"
+# echo -e "\033]6;1;bg;blue;brightness;33\a"
autoload -U add-zsh-hook
-export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
-export PATH="/usr/local/sbin:$PATH"
-
-# The next line updates PATH for the Google Cloud SDK.
-if [ -f '/Users/cobraz/google-cloud-sdk/path.zsh.inc' ]; then . '/Users/cobraz/google-cloud-sdk/path.zsh.inc'; fi
-
-# The next line enables shell command completion for gcloud.
-if [ -f '/Users/cobraz/google-cloud-sdk/completion.zsh.inc' ]; then . '/Users/cobraz/google-cloud-sdk/completion.zsh.inc'; fi
-export VISUAL="emacs"
-export GOPATH=~/go
-export PATH=$PATH:$GOPATH/bin
-export VOLTA_HOME="$HOME/.volta"
-export PATH="$VOLTA_HOME/bin:$PATH"
+# Load .bashrc,
+if [[ -r "${HOME}/.bashrc" ]]; then
+ # shellcheck source=/dev/null
+ source "${HOME}/.bashrc"
+fi \ No newline at end of file
diff --git a/brew.sh b/brew.sh
index 08be1a4..5eaeeb1 100755
--- a/brew.sh
+++ b/brew.sh
@@ -72,12 +72,15 @@ brew install tree
brew install vbindiff
brew install zopfli
brew install ghq
+brew install kubectl
+brew install emacs
# Tooling
brew cask install google-chrome
brew cask install google-drive-file-stream
brew cask install adobe-creative-cloud
brew cask install visual-studio-code
+brew cask install google-cloud-sdk
brew cask install iterm2
brew cask install spotify
brew cask install memory
@@ -90,8 +93,6 @@ brew install gh
# My tools
brew install cobraz/tools/trippl-timely
-brew install emacs
-
# Quick Look Plugins (https://github.com/sindresorhus/quick-look-plugins)
brew cask install qlcolorcode qlstephen qlmarkdown quicklook-json qlprettypatch quicklook-csv betterzipql qlimagesize webpquicklook qlvideo