This commit is contained in:
Matthias Kretschmann 2017-09-10 14:46:58 +02:00
parent 1faaa176b7
commit 1e2427bfd1
Signed by: m
GPG Key ID: 606EEEF3C479A91F
6 changed files with 13 additions and 5 deletions

View File

@ -11,8 +11,8 @@ addons:
- shellcheck
script:
- bash -c 'shopt -s globstar; shellcheck **/bash_*'
- bash -c 'shopt -s globstar; shellcheck **/*.{sh,bash}'
- bash -c 'shopt -s globstar; shellcheck **/bash*'
- bash -c 'shopt -s globstar; shellcheck **/*.sh'
matrix:
fast_finish: true

View File

@ -23,10 +23,10 @@ alias ip="dig +short myip.opendns.com @resolver1.opendns.com"
alias localip="ipconfig getifaddr en1"
# Copy SSH public key to pasteboard
alias pubkey="more ~/.ssh/id_rsa.pub | pbcopy | printf '$(tput setaf 64)✓ Public SSH key copied to pasteboard.$(tput sgr0)\n'"
alias pubkey="more ~/.ssh/id_rsa.pub | pbcopy | printf '\$(tput setaf 64)✓ Public SSH key copied to pasteboard.\$(tput sgr0)\n'"
# Copy GPG public key to pasteboard
alias gpgpubkey="gpg --export --armor 0xDD7831FC | pbcopy | printf '$(tput setaf 64)✓ Public GPG key copied to pasteboard.$(tput sgr0)\n'"
alias gpgpubkey="gpg --export --armor 0xDD7831FC | pbcopy | printf '\$(tput setaf 64)✓ Public GPG key copied to pasteboard.\$(tput sgr0)\n'"
# Recursively delete `.DS_Store` files
alias cleanup="find . -type f -name '*.DS_Store' -ls -delete"

View File

@ -62,6 +62,7 @@ PROMPT_DIRTRIM=4
# Add tab completion for many Bash commands
if which brew &> /dev/null && [ -f "$(brew --prefix)/share/bash-completion/bash_completion" ]; then
# shellcheck source=/dev/null
source "$(brew --prefix)/share/bash-completion/bash_completion";
elif [ -f /etc/bash_completion ]; then
# shellcheck disable=SC1091
@ -95,6 +96,7 @@ complete -C aws_completer aws
# ----------------------------------------------------------------------
# Load RVM into a shell session *as a function*
# shellcheck source=/dev/null
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"

View File

@ -26,11 +26,13 @@ prompt_git() {
git update-index --really-refresh -q &>/dev/null;
# Check for uncommitted changes in the index.
# shellcheck disable=SC2091
if ! $(git diff --quiet --ignore-submodules --cached); then
s+='+';
fi;
# Check for unstaged changes.
# shellcheck disable=SC2091
if ! $(git diff-files --quiet --ignore-submodules --); then
s+='!';
fi;
@ -41,6 +43,7 @@ prompt_git() {
fi;
# Check for stashed files.
# shellcheck disable=SC2091
if $(git rev-parse --verify refs/stash &>/dev/null); then
s+='$';
fi;
@ -62,6 +65,7 @@ prompt_git() {
fi;
}
# shellcheck disable=SC2034
if tput setaf 1 &> /dev/null; then
tput sgr0; # reset colors
bold=$(tput bold);

View File

@ -54,7 +54,7 @@ echo "$(tput setaf 240)Updating git repos in directory: $directory_to_update $(t
count=0
for dir in $(find "$directory_to_update" -maxdepth 4 -type d -name .git | xargs -n 1 dirname); do
for dir in $(find "$directory_to_update" -maxdepth 4 -type d -name .git -print0 | xargs -n -0 1 dirname); do
updateRepo "$dir" "$directory_to_update"
((count+=1))
done

View File

@ -2,6 +2,8 @@
> 👩‍🎤 personal dotfiles, scrambled together from the interwebz. Highly macOS oriented.
[![Build Status](https://travis-ci.org/kremalicious/dotfiles.svg?branch=master)](https://travis-ci.org/kremalicious/dotfiles)
![hackerman](https://cloud.githubusercontent.com/assets/90316/26279873/9240a9d8-3dc0-11e7-9353-783b36ae6aff.jpg)
## Installation