From ffb2f432b8ab56ecbd1bf1661822dd955c6ba8a3 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sat, 28 Mar 2015 23:22:02 -0300 Subject: [PATCH 01/31] docker and fixes --- Dockerfile | 8 ++++++++ atom.symlink/install.sh | 14 ++++++++++---- docker/install.sh | 0 3 files changed, 18 insertions(+), 4 deletions(-) create mode 100644 Dockerfile mode change 100644 => 100755 docker/install.sh diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 000000000..f29a4a2b9 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM ubuntu:14.10 +MAINTAINER Carlos Alexandro Becker +RUN apt-get install -y wget zsh git curl vim +ADD . /root/.dotfiles +RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD +# ENV BRANCH master +# RUN bash -c "$(wget -O - https://raw.githubusercontent.com/caarlos0/dotfiles/$BRANCH/script/install)" +# RUN cd ~/.dotfiles && ./bin/dot diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index 4b1721a70..334284684 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -1,9 +1,15 @@ #!/bin/zsh if [ "$(uname -s)" = "Darwin" ]; then brew cask install atom +elif test "$(which apt-get)"; then + sudo add-apt-repository -y ppa:webupd8team/atom + sudo apt-get update + sudo apt-get install -y "$@" fi -# base -apm install editorconfig autocomplete-plus language-docker -# linters -apm install linter linter-shellcheck linter-javac linter-jshint linter-ruby +if test "$(which apm)"; then + # base + apm install editorconfig autocomplete-plus language-docker + # linters + apm install linter linter-shellcheck linter-javac linter-jshint linter-ruby +fi diff --git a/docker/install.sh b/docker/install.sh old mode 100644 new mode 100755 From 12c56fc400befc91aca820865e5f42ceb95daf25 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sat, 28 Mar 2015 23:28:15 -0300 Subject: [PATCH 02/31] fixes on dockerfile AND atom --- Dockerfile | 4 ++-- atom.symlink/install.sh | 34 +++++++++++++++++++++------------- 2 files changed, 23 insertions(+), 15 deletions(-) diff --git a/Dockerfile b/Dockerfile index f29a4a2b9..70836f8ad 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ -FROM ubuntu:14.10 +FROM ubuntu MAINTAINER Carlos Alexandro Becker -RUN apt-get install -y wget zsh git curl vim +RUN apt-get install -y software-properties-common wget zsh git curl vim ADD . /root/.dotfiles RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD # ENV BRANCH master diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index 334284684..744e2be8e 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -1,15 +1,23 @@ #!/bin/zsh -if [ "$(uname -s)" = "Darwin" ]; then - brew cask install atom -elif test "$(which apt-get)"; then - sudo add-apt-repository -y ppa:webupd8team/atom - sudo apt-get update - sudo apt-get install -y "$@" -fi -if test "$(which apm)"; then - # base - apm install editorconfig autocomplete-plus language-docker - # linters - apm install linter linter-shellcheck linter-javac linter-jshint linter-ruby -fi +instal() { + if [ "$(uname -s)" = "Darwin" ]; then + brew cask install atom + elif test "$(which apt-get)"; then + sudo add-apt-repository -y ppa:webupd8team/atom + sudo apt-get update + sudo apt-get install -y atom + fi +} + +install_plugins() { + if test "$(which apm)"; then + # base + apm install editorconfig autocomplete-plus language-docker + # linters + apm install linter linter-shellcheck linter-javac linter-jshint linter-ruby + fi +} + +install || true +install_plugins || true From 34166428c8b4b84cea5c9fab7748f382e858a5cd Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sat, 28 Mar 2015 23:36:40 -0300 Subject: [PATCH 03/31] simplify stuff --- Dockerfile | 10 +++++++--- atom.symlink/install.sh | 27 +++++++-------------------- homebrew/install.sh | 3 +-- 3 files changed, 15 insertions(+), 25 deletions(-) diff --git a/Dockerfile b/Dockerfile index 70836f8ad..4594bb43b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,12 @@ +# caarlos0/dotfiles test container FROM ubuntu MAINTAINER Carlos Alexandro Becker + RUN apt-get install -y software-properties-common wget zsh git curl vim +RUN add-apt-repository -y ppa:webupd8team/atom +RUN apt-get update +RUN apt-get install atom + ADD . /root/.dotfiles + RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD -# ENV BRANCH master -# RUN bash -c "$(wget -O - https://raw.githubusercontent.com/caarlos0/dotfiles/$BRANCH/script/install)" -# RUN cd ~/.dotfiles && ./bin/dot diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index 744e2be8e..a046c0f3f 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -1,23 +1,10 @@ #!/bin/zsh -instal() { - if [ "$(uname -s)" = "Darwin" ]; then - brew cask install atom - elif test "$(which apt-get)"; then - sudo add-apt-repository -y ppa:webupd8team/atom - sudo apt-get update - sudo apt-get install -y atom - fi -} +if [ "$(uname -s)" = "Darwin" ]; then + brew cask install atom +fi -install_plugins() { - if test "$(which apm)"; then - # base - apm install editorconfig autocomplete-plus language-docker - # linters - apm install linter linter-shellcheck linter-javac linter-jshint linter-ruby - fi -} - -install || true -install_plugins || true +apm install \ + editorconfig autocomplete-plus language-docker \ + linter linter-shellcheck linter-javac linter-jshint linter-ruby \ + || true diff --git a/homebrew/install.sh b/homebrew/install.sh index 99fdc92f3..46e3d720b 100755 --- a/homebrew/install.sh +++ b/homebrew/install.sh @@ -29,8 +29,7 @@ brew cask install iterm2 the-unarchiver disk-inventory-x appcleaner diffmerge \ brew cask install virtualbox vagrant # chat, books, notes, documents, mail, etc -brew cask install kindle calibre dropbox skype slack messenger-for-telegram \ - mailbox +brew cask install kindle calibre dropbox skype slack messenger-for-telegram # browser brew cask install google-chrome From 03f5521fa74d55e4c3ce9655dc5e1a987870be36 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sat, 28 Mar 2015 23:53:57 -0300 Subject: [PATCH 04/31] fixes --- Dockerfile | 2 +- vim/install.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 4594bb43b..a5128f12a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,7 +5,7 @@ MAINTAINER Carlos Alexandro Becker RUN apt-get install -y software-properties-common wget zsh git curl vim RUN add-apt-repository -y ppa:webupd8team/atom RUN apt-get update -RUN apt-get install atom +RUN apt-get -y install atom ADD . /root/.dotfiles diff --git a/vim/install.sh b/vim/install.sh index ed40ca522..788617dfc 100755 --- a/vim/install.sh +++ b/vim/install.sh @@ -5,5 +5,5 @@ setup_command_t() { make } [ "$(uname -s)" = "Darwin" ] && brew install vim -vim +PluginInstall +qall +vim +PluginInstall +qall &> /tmp/vim-plugins.log setup_command_t &> /tmp/cmd-t.log From 34da174f30bf933b7bde24f95cb5422af1be0bf9 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sat, 28 Mar 2015 23:57:46 -0300 Subject: [PATCH 05/31] antigen apply just in case --- Dockerfile | 2 +- bin/dot | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index a5128f12a..91df4fe68 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,4 +9,4 @@ RUN apt-get -y install atom ADD . /root/.dotfiles -RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD +RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD && git remote rm origin diff --git a/bin/dot b/bin/dot index 7d0cab3ac..cba39ee88 100755 --- a/bin/dot +++ b/bin/dot @@ -12,6 +12,7 @@ main() { echo "Updating antigen plugins..." git submodule update source ./antigen/antigen/antigen.zsh + antigen apply antigen update echo "Setting OSX/Gnome defaults..." From d71e76ab172d343f9111e1ebef930deb035db5aa Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 00:46:24 -0300 Subject: [PATCH 06/31] fixing install files --- atom.symlink/install.sh | 3 +-- vim/install.sh | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index a046c0f3f..9264e77c8 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -6,5 +6,4 @@ fi apm install \ editorconfig autocomplete-plus language-docker \ - linter linter-shellcheck linter-javac linter-jshint linter-ruby \ - || true + linter linter-shellcheck linter-javac linter-jshint linter-ruby diff --git a/vim/install.sh b/vim/install.sh index 788617dfc..24a9d120b 100755 --- a/vim/install.sh +++ b/vim/install.sh @@ -5,5 +5,5 @@ setup_command_t() { make } [ "$(uname -s)" = "Darwin" ] && brew install vim -vim +PluginInstall +qall &> /tmp/vim-plugins.log -setup_command_t &> /tmp/cmd-t.log +vim +PluginInstall +qall >/tmp/vim-plugins.log 2>&1 +setup_command_t >/tmp/cmd-t.log 2>&1 From 6042bbcad2adc549fac33895d1ca1315440896ee Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 00:50:49 -0300 Subject: [PATCH 07/31] More logging... --- bin/dot | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/dot b/bin/dot index cba39ee88..00d968a53 100755 --- a/bin/dot +++ b/bin/dot @@ -25,6 +25,7 @@ main() { # find the installers and run them iteratively find . -name install.sh | grep -v homebrew | grep -v build | while read installer; do + echo "Executing ${installer}..." sh -c "$installer" done } From 415b3b32d257cfe684c7c745e3d4bb18e0962e22 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 00:55:41 -0300 Subject: [PATCH 08/31] vim install still not working right --- vim/install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vim/install.sh b/vim/install.sh index 24a9d120b..38acad64c 100755 --- a/vim/install.sh +++ b/vim/install.sh @@ -5,5 +5,5 @@ setup_command_t() { make } [ "$(uname -s)" = "Darwin" ] && brew install vim -vim +PluginInstall +qall >/tmp/vim-plugins.log 2>&1 -setup_command_t >/tmp/cmd-t.log 2>&1 +vim +PluginInstall +qall >/tmp/vim-plugins.log 2>&1 || true +setup_command_t >/tmp/cmd-t.log 2>&1 || true From 5761bd87a89feb638d689cd19c2a4531d03731be Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 00:55:49 -0300 Subject: [PATCH 09/31] docker entrypoint --- Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Dockerfile b/Dockerfile index 91df4fe68..41cf8b853 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,3 +10,5 @@ RUN apt-get -y install atom ADD . /root/.dotfiles RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD && git remote rm origin + +ENTRYPOINT cd ~/.dotfiles && echo "Execute ./script/bootstrap to begin!" && bash From b227a732dc4e2e826f7701d3061f4ca419c6ccfb Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:01:47 -0300 Subject: [PATCH 10/31] dont break if no apm --- atom.symlink/install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index 9264e77c8..e364fa141 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -6,4 +6,4 @@ fi apm install \ editorconfig autocomplete-plus language-docker \ - linter linter-shellcheck linter-javac linter-jshint linter-ruby + linter linter-shellcheck linter-javac linter-jshint linter-ruby || true From e042450195eaec7224ab3217b873781a1723a780 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:10:05 -0300 Subject: [PATCH 11/31] improved dot --- bin/dot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/dot b/bin/dot index 00d968a53..8fe485f74 100755 --- a/bin/dot +++ b/bin/dot @@ -24,7 +24,7 @@ main() { ./homebrew/install.sh # find the installers and run them iteratively - find . -name install.sh | grep -v homebrew | grep -v build | while read installer; do + find . -name install.sh | egrep -v "homebrew|build" | while read installer; do echo "Executing ${installer}..." sh -c "$installer" done From 8cdfbece5e98ceb0544758ebf62dfc77d4bfee91 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:10:17 -0300 Subject: [PATCH 12/31] minimal dockerfile --- Dockerfile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 41cf8b853..c3d607bdd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,13 +2,14 @@ FROM ubuntu MAINTAINER Carlos Alexandro Becker -RUN apt-get install -y software-properties-common wget zsh git curl vim -RUN add-apt-repository -y ppa:webupd8team/atom -RUN apt-get update -RUN apt-get -y install atom +RUN apt-get install -y software-properties-common wget zsh git curl ADD . /root/.dotfiles -RUN cd /root/.dotfiles && git clean -df && git reset --hard HEAD && git remote rm origin +RUN cd /root/.dotfiles && \ + git clean -df && \ + git reset --hard HEAD && \ + rm -f ./git/gitconfig.symlink && \ + git remote rm origin ENTRYPOINT cd ~/.dotfiles && echo "Execute ./script/bootstrap to begin!" && bash From ab92b3ab9739e69ff059b80a44d12dc8f60ae3b5 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:14:21 -0300 Subject: [PATCH 13/31] more debug --- bin/dot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/dot b/bin/dot index 8fe485f74..eb7debeef 100755 --- a/bin/dot +++ b/bin/dot @@ -26,7 +26,7 @@ main() { # find the installers and run them iteratively find . -name install.sh | egrep -v "homebrew|build" | while read installer; do echo "Executing ${installer}..." - sh -c "$installer" + sh -xc "$installer" done } From 75fb2aac4e65c5d2e43f9d6d6063c678cd8d478f Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:25:46 -0300 Subject: [PATCH 14/31] hopefully fixed some install scripts --- atom.symlink/install.sh | 6 +----- git/install.sh | 2 +- golang/install.sh | 6 ++---- homebrew/install.sh | 2 +- java/install.sh | 2 +- media/install.sh | 2 +- mysql/install.sh | 2 +- postgres/install.sh | 2 +- redis/install.sh | 5 ++--- ruby/install.sh | 8 +++----- slate/install.sh | 5 ++--- sublime-text-3/install.sh | 2 +- terminator/install.sh | 2 +- 13 files changed, 18 insertions(+), 28 deletions(-) diff --git a/atom.symlink/install.sh b/atom.symlink/install.sh index e364fa141..5ef11da4f 100755 --- a/atom.symlink/install.sh +++ b/atom.symlink/install.sh @@ -1,9 +1,5 @@ #!/bin/zsh - -if [ "$(uname -s)" = "Darwin" ]; then - brew cask install atom -fi - +[ "$(uname -s)" = "Darwin" ] && brew cask install atom apm install \ editorconfig autocomplete-plus language-docker \ linter linter-shellcheck linter-javac linter-jshint linter-ruby || true diff --git a/git/install.sh b/git/install.sh index 0fccc0f9a..0dd96714e 100755 --- a/git/install.sh +++ b/git/install.sh @@ -1,2 +1,2 @@ -#!/bin/bash +#!/bin/zsh [ "$(uname -s)" = "Darwin" ] && brew install git diff --git a/golang/install.sh b/golang/install.sh index e558ba4e8..772a99eef 100755 --- a/golang/install.sh +++ b/golang/install.sh @@ -1,4 +1,2 @@ -#!/bin/bash -[[ "$(uname -s)" != "Darwin" ]] && exit 0 - -brew install go +#!/bin/zsh +[ "$(uname -s)" = "Darwin" ] && brew install go diff --git a/homebrew/install.sh b/homebrew/install.sh index 46e3d720b..d9ebbed05 100755 --- a/homebrew/install.sh +++ b/homebrew/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh # # Homebrew # diff --git a/java/install.sh b/java/install.sh index ea70e9d6c..29c3e83c4 100755 --- a/java/install.sh +++ b/java/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" != "Darwin" ]] && exit 0 # install some java stuff diff --git a/media/install.sh b/media/install.sh index cdb083e2a..ac314d342 100755 --- a/media/install.sh +++ b/media/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" != "Darwin" ]] && exit 0 # watch and download stuff diff --git a/mysql/install.sh b/mysql/install.sh index f7214993e..033b4f616 100755 --- a/mysql/install.sh +++ b/mysql/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" != "Darwin" ]] && exit 0 brew install mariadb diff --git a/postgres/install.sh b/postgres/install.sh index e757cc2a6..b9acb02ce 100755 --- a/postgres/install.sh +++ b/postgres/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" != "Darwin" ]] && exit 0 brew cask install postgres pg-commander diff --git a/redis/install.sh b/redis/install.sh index 50d8550aa..37d6666c0 100755 --- a/redis/install.sh +++ b/redis/install.sh @@ -1,3 +1,2 @@ -#!/bin/bash -[[ "$(uname -s)" != "Darwin" ]] && exit 0 -brew install redis +#!/bin/zsh +[ "$(uname -s)" = "Darwin" ] && brew install redis diff --git a/ruby/install.sh b/ruby/install.sh index dda6ac53d..898100b42 100755 --- a/ruby/install.sh +++ b/ruby/install.sh @@ -1,14 +1,12 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" != "Darwin" ]] && exit 0 -if test ! "$(which rbenv)" -then +if test ! "$(which rbenv)"; then echo " Installing rbenv for you." brew install rbenv > /tmp/rbenv-install.log fi -if test ! "$(which ruby-build)" -then +if test ! "$(which ruby-build)"; then echo " Installing ruby-build for you." brew install ruby-build > /tmp/ruby-build-install.log fi diff --git a/slate/install.sh b/slate/install.sh index f28d40618..db8870585 100755 --- a/slate/install.sh +++ b/slate/install.sh @@ -1,3 +1,2 @@ -#!/bin/bash -[[ "$(uname -s)" != "Darwin" ]] && exit 0 -brew cask install slate +#!/bin/zsh +[ "$(uname -s)" = "Darwin" ] && brew cask install slate diff --git a/sublime-text-3/install.sh b/sublime-text-3/install.sh index a189063ba..88c140508 100755 --- a/sublime-text-3/install.sh +++ b/sublime-text-3/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh if [ "$(uname -s)" = "Darwin" ]; then brew cask install sublime-text3 diff --git a/terminator/install.sh b/terminator/install.sh index 42f1b0a58..9435bf88b 100755 --- a/terminator/install.sh +++ b/terminator/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/zsh [[ "$(uname -s)" = "Darwin" ]] && exit 0 mkdir -p ~/.config/terminator/ ln -sf "$ZSH"/terminator/base16-ocean-dark.config ~/.config/terminator/config From e77afae4cddf00e9673959a0f334a266def56cbf Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:34:30 -0300 Subject: [PATCH 15/31] dot fixes --- bin/dot | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/dot b/bin/dot index eb7debeef..6412b65b7 100755 --- a/bin/dot +++ b/bin/dot @@ -6,6 +6,7 @@ # to make sure you're on the latest and greatest. main() { cd ~/.dotfiles + export ZSH="$(pwd)" echo "Updating dotfiles..." git pull origin master @@ -26,7 +27,7 @@ main() { # find the installers and run them iteratively find . -name install.sh | egrep -v "homebrew|build" | while read installer; do echo "Executing ${installer}..." - sh -xc "$installer" + sh -x "$installer" >> /tmp/dotfiles-dot done } From 8ea93dca8a4376f0dd9a7ddd9618515e76b1d48f Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:38:13 -0300 Subject: [PATCH 16/31] fixing some shell errors --- homebrew/install.sh | 2 +- java/install.sh | 2 +- media/install.sh | 2 +- mysql/install.sh | 2 +- node/install.sh | 2 +- postgres/install.sh | 2 +- quicklook/install.sh | 2 +- ruby/install.sh | 2 +- sublime-text-3/install.sh | 2 +- terminator/install.sh | 2 +- zsh/zshrc.symlink | 3 +-- 11 files changed, 11 insertions(+), 12 deletions(-) diff --git a/homebrew/install.sh b/homebrew/install.sh index d9ebbed05..d5fa25aaa 100755 --- a/homebrew/install.sh +++ b/homebrew/install.sh @@ -4,7 +4,7 @@ # # This installs some of the common dependencies needed (or at least desired) # using Homebrew. -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 # Check for Homebrew if test ! "$(which brew)"; then diff --git a/java/install.sh b/java/install.sh index 29c3e83c4..103309337 100755 --- a/java/install.sh +++ b/java/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 # install some java stuff brew install maven diff --git a/media/install.sh b/media/install.sh index ac314d342..08ebc49bb 100755 --- a/media/install.sh +++ b/media/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 # watch and download stuff brew install youtube-dl diff --git a/mysql/install.sh b/mysql/install.sh index 033b4f616..0c5406420 100755 --- a/mysql/install.sh +++ b/mysql/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 brew install mariadb brew cask install sequel-pro diff --git a/node/install.sh b/node/install.sh index 4c3656e84..30fcb2463 100755 --- a/node/install.sh +++ b/node/install.sh @@ -1,4 +1,4 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 brew install node diff --git a/postgres/install.sh b/postgres/install.sh index b9acb02ce..c4427458d 100755 --- a/postgres/install.sh +++ b/postgres/install.sh @@ -1,4 +1,4 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 brew cask install postgres pg-commander diff --git a/quicklook/install.sh b/quicklook/install.sh index 914f51419..6b31dbb39 100755 --- a/quicklook/install.sh +++ b/quicklook/install.sh @@ -1,5 +1,5 @@ #!/bin/bash -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 # quick look plugins - https://github.com/sindresorhus/quick-look-plugins brew cask install qlcolorcode qlstephen qlmarkdown quicklook-json \ qlprettypatch quicklook-csv betterzipql qlimagesize webpquicklook \ diff --git a/ruby/install.sh b/ruby/install.sh index 898100b42..72e83552c 100755 --- a/ruby/install.sh +++ b/ruby/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[[ "$(uname -s)" != "Darwin" ]] && exit 0 +[ "$(uname -s)" != "Darwin" ] && exit 0 if test ! "$(which rbenv)"; then echo " Installing rbenv for you." diff --git a/sublime-text-3/install.sh b/sublime-text-3/install.sh index 88c140508..ff3585490 100755 --- a/sublime-text-3/install.sh +++ b/sublime-text-3/install.sh @@ -13,7 +13,7 @@ mkdir -p "$ST3_LOCAL/Packages/User/" # Install Package Control PKG_CTRL_FILE="$ST3_LOCAL/Installed Packages/Package Control.sublime-package" -[[ ! -f "$PKG_CTRL_FILE" ]] && curl -o "$PKG_CTRL_FILE" \ +[ ! -f "$PKG_CTRL_FILE" ] && curl -o "$PKG_CTRL_FILE" \ "https://sublime.wbond.net/Package Control.sublime-package" # Link keymaps diff --git a/terminator/install.sh b/terminator/install.sh index 9435bf88b..645cdd817 100755 --- a/terminator/install.sh +++ b/terminator/install.sh @@ -1,4 +1,4 @@ #!/bin/zsh -[[ "$(uname -s)" = "Darwin" ]] && exit 0 +[ "$(uname -s)" = "Darwin" ] && exit 0 mkdir -p ~/.config/terminator/ ln -sf "$ZSH"/terminator/base16-ocean-dark.config ~/.config/terminator/config diff --git a/zsh/zshrc.symlink b/zsh/zshrc.symlink index 790255ee0..5d636d61b 100644 --- a/zsh/zshrc.symlink +++ b/zsh/zshrc.symlink @@ -35,5 +35,4 @@ unset config_files # use .localrc for SUPER SECRET CRAP that you don't # want in your public, versioned repo. -[[ -a ~/.localrc ]] && source ~/.localrc - +[ -a ~/.localrc ] && source ~/.localrc From b7757e6d3caed4868fb23173f7c13c3680bc505a Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:42:09 -0300 Subject: [PATCH 17/31] hopefully fixed some install scripts --- homebrew/install.sh | 2 +- java/install.sh | 2 +- media/install.sh | 2 +- mysql/install.sh | 2 +- node/install.sh | 4 +--- postgres/install.sh | 4 +--- quicklook/install.sh | 7 +++---- ruby/install.sh | 2 +- terminator/install.sh | 2 +- 9 files changed, 11 insertions(+), 16 deletions(-) diff --git a/homebrew/install.sh b/homebrew/install.sh index d5fa25aaa..eeca65f47 100755 --- a/homebrew/install.sh +++ b/homebrew/install.sh @@ -4,7 +4,7 @@ # # This installs some of the common dependencies needed (or at least desired) # using Homebrew. -[ "$(uname -s)" != "Darwin" ] && exit 0 +[ "$(uname -s)" != "Darwin" ] && return 0 # Check for Homebrew if test ! "$(which brew)"; then diff --git a/java/install.sh b/java/install.sh index 103309337..3ef89323f 100755 --- a/java/install.sh +++ b/java/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 +[ "$(uname -s)" != "Darwin" ] && return 0 # install some java stuff brew install maven diff --git a/media/install.sh b/media/install.sh index 08ebc49bb..6bcf5550b 100755 --- a/media/install.sh +++ b/media/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 +[ "$(uname -s)" != "Darwin" ] && return 0 # watch and download stuff brew install youtube-dl diff --git a/mysql/install.sh b/mysql/install.sh index 0c5406420..303aa18c4 100755 --- a/mysql/install.sh +++ b/mysql/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 +[ "$(uname -s)" != "Darwin" ] && return 0 brew install mariadb brew cask install sequel-pro diff --git a/node/install.sh b/node/install.sh index 30fcb2463..6888ad024 100755 --- a/node/install.sh +++ b/node/install.sh @@ -1,4 +1,2 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 - -brew install node +[ "$(uname -s)" = "Darwin" ] && brew install node diff --git a/postgres/install.sh b/postgres/install.sh index c4427458d..2e9b7a0a9 100755 --- a/postgres/install.sh +++ b/postgres/install.sh @@ -1,4 +1,2 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 - -brew cask install postgres pg-commander +[ "$(uname -s)" = "Darwin" ] && brew cask install postgres pg-commander diff --git a/quicklook/install.sh b/quicklook/install.sh index 6b31dbb39..3e1031a8a 100755 --- a/quicklook/install.sh +++ b/quicklook/install.sh @@ -1,6 +1,5 @@ #!/bin/bash -[ "$(uname -s)" != "Darwin" ] && exit 0 # quick look plugins - https://github.com/sindresorhus/quick-look-plugins -brew cask install qlcolorcode qlstephen qlmarkdown quicklook-json \ - qlprettypatch quicklook-csv betterzipql qlimagesize webpquicklook \ - suspicious-package +[ "$(uname -s)" = "Darwin" ] && brew cask install qlcolorcode qlstephen \ + qlmarkdown quicklook-json qlprettypatch quicklook-csv betterzipql \ + qlimagesize webpquicklook suspicious-package diff --git a/ruby/install.sh b/ruby/install.sh index 72e83552c..ab262ec08 100755 --- a/ruby/install.sh +++ b/ruby/install.sh @@ -1,5 +1,5 @@ #!/bin/zsh -[ "$(uname -s)" != "Darwin" ] && exit 0 +[ "$(uname -s)" != "Darwin" ] && return 0 if test ! "$(which rbenv)"; then echo " Installing rbenv for you." diff --git a/terminator/install.sh b/terminator/install.sh index 645cdd817..6e0485a37 100755 --- a/terminator/install.sh +++ b/terminator/install.sh @@ -1,4 +1,4 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && exit 0 +[ "$(uname -s)" = "Darwin" ] && return 0 mkdir -p ~/.config/terminator/ ln -sf "$ZSH"/terminator/base16-ocean-dark.config ~/.config/terminator/config From 7db30e2231c650e0e4559b7df63214314419d446 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:51:25 -0300 Subject: [PATCH 18/31] hopefully fixed some install scripts --- golang/install.sh | 3 ++- node/install.sh | 3 ++- quicklook/install.sh | 9 +++++---- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/golang/install.sh b/golang/install.sh index 772a99eef..88437808a 100755 --- a/golang/install.sh +++ b/golang/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew install go +[ "$(uname -s)" != "Darwin" ] && return 0 +brew install go diff --git a/node/install.sh b/node/install.sh index 6888ad024..61de0f75b 100755 --- a/node/install.sh +++ b/node/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew install node +[ "$(uname -s)" != "Darwin" ] && return 0 +brew install node diff --git a/quicklook/install.sh b/quicklook/install.sh index 3e1031a8a..fd8f99380 100755 --- a/quicklook/install.sh +++ b/quicklook/install.sh @@ -1,5 +1,6 @@ -#!/bin/bash +#!/bin/zsh +[ "$(uname -s)" != "Darwin" ] && return 0 # quick look plugins - https://github.com/sindresorhus/quick-look-plugins -[ "$(uname -s)" = "Darwin" ] && brew cask install qlcolorcode qlstephen \ - qlmarkdown quicklook-json qlprettypatch quicklook-csv betterzipql \ - qlimagesize webpquicklook suspicious-package +brew cask install qlcolorcode qlstephen qlmarkdown quicklook-json \ + qlprettypatch quicklook-csv betterzipql qlimagesize webpquicklook \ + suspicious-package From 5fdaceb98cffacfeee85dd83b307653868736d44 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:52:10 -0300 Subject: [PATCH 19/31] dot --- bin/dot | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/dot b/bin/dot index 6412b65b7..dba7ebf40 100755 --- a/bin/dot +++ b/bin/dot @@ -26,8 +26,8 @@ main() { # find the installers and run them iteratively find . -name install.sh | egrep -v "homebrew|build" | while read installer; do - echo "Executing ${installer}..." - sh -x "$installer" >> /tmp/dotfiles-dot + echo "$ ${installer}..." + sh -c "$installer" >> /tmp/dotfiles-dot done } From 954fea4b33a05cc922b9a7887595113bfdd965e6 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 01:55:06 -0300 Subject: [PATCH 20/31] hopefully fixed some install scripts --- git/install.sh | 3 ++- postgres/install.sh | 3 ++- redis/install.sh | 3 ++- slate/install.sh | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/git/install.sh b/git/install.sh index 0dd96714e..6cb9f4d8d 100755 --- a/git/install.sh +++ b/git/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew install git +[ "$(uname -s)" != "Darwin" ] && return 0 +brew install git diff --git a/postgres/install.sh b/postgres/install.sh index 2e9b7a0a9..d8c2c1789 100755 --- a/postgres/install.sh +++ b/postgres/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew cask install postgres pg-commander +[ "$(uname -s)" != "Darwin" ] && return 0 +brew cask install postgres pg-commander diff --git a/redis/install.sh b/redis/install.sh index 37d6666c0..f32b46846 100755 --- a/redis/install.sh +++ b/redis/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew install redis +[ "$(uname -s)" != "Darwin" ] && return 0 +brew install redis diff --git a/slate/install.sh b/slate/install.sh index db8870585..1d4e52da7 100755 --- a/slate/install.sh +++ b/slate/install.sh @@ -1,2 +1,3 @@ #!/bin/zsh -[ "$(uname -s)" = "Darwin" ] && brew cask install slate +[ "$(uname -s)" != "Darwin" ] && return 0 +brew cask install slate From f89bf2a03b742c6a27221937ff79bcd7f3223f56 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:06:54 -0300 Subject: [PATCH 21/31] added docker to readme --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 45180b9c9..211ad2768 100644 --- a/README.md +++ b/README.md @@ -107,6 +107,18 @@ All those are managed by [antigen][antigen]. I try to keep it working in both Linux (no specific distro) and OS X, mostly because I use OS X at home and Linux at work. +## test it within Docker + +Yes you can! Pull the repo and run: + +```sh +$ docker build -t caarlos0/dotfiles . +$ docker run -it caarlos0/dotfiles +``` + +It will start a fresh container with my dotfiles inside. +Run `./script/bootstrap` to setup them. + ## bugs I want this to work for everyone; that means when you clone it down it should From 52e91f2615a9757ab22f523782f87a5ca59b916b Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:13:06 -0300 Subject: [PATCH 22/31] improved Dockerfile --- Dockerfile | 2 -- 1 file changed, 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c3d607bdd..c6cf1ace2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,8 +7,6 @@ RUN apt-get install -y software-properties-common wget zsh git curl ADD . /root/.dotfiles RUN cd /root/.dotfiles && \ - git clean -df && \ - git reset --hard HEAD && \ rm -f ./git/gitconfig.symlink && \ git remote rm origin From 90c92c95772a3a75057d0e858800631371b1539a Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:16:17 -0300 Subject: [PATCH 23/31] zshrc --- zsh/zshrc.symlink | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zsh/zshrc.symlink b/zsh/zshrc.symlink index 5d636d61b..832c7f1fb 100644 --- a/zsh/zshrc.symlink +++ b/zsh/zshrc.symlink @@ -35,4 +35,4 @@ unset config_files # use .localrc for SUPER SECRET CRAP that you don't # want in your public, versioned repo. -[ -a ~/.localrc ] && source ~/.localrc +[[ -a ~/.localrc ]] && source ~/.localrc From 7cdf00a7067f91c9c41fca24302b25b53dd7a0a7 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:16:22 -0300 Subject: [PATCH 24/31] z --- antigen/install.sh | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 antigen/install.sh diff --git a/antigen/install.sh b/antigen/install.sh new file mode 100644 index 000000000..733fd0068 --- /dev/null +++ b/antigen/install.sh @@ -0,0 +1,2 @@ +#!/bin/zsh +mkdir ~/.z From 3ee310c0cc0b328c6639381272929c26604122d3 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:19:22 -0300 Subject: [PATCH 25/31] chmod --- antigen/install.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 antigen/install.sh diff --git a/antigen/install.sh b/antigen/install.sh old mode 100644 new mode 100755 From d8293e59f59c25e62e57db4018360eded042794b Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 02:24:07 -0300 Subject: [PATCH 26/31] Improved dockerfile and help --- Dockerfile | 4 +++- README.md | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index c6cf1ace2..da9032b18 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,4 +10,6 @@ RUN cd /root/.dotfiles && \ rm -f ./git/gitconfig.symlink && \ git remote rm origin -ENTRYPOINT cd ~/.dotfiles && echo "Execute ./script/bootstrap to begin!" && bash +ENTRYPOINT cd ~/.dotfiles && \ + echo "Execute ./script/bootstrap to begin! When done, source ~/.zshrc to load the new configs!" && \ + zsh diff --git a/README.md b/README.md index 211ad2768..1efa56681 100644 --- a/README.md +++ b/README.md @@ -118,6 +118,7 @@ $ docker run -it caarlos0/dotfiles It will start a fresh container with my dotfiles inside. Run `./script/bootstrap` to setup them. +When done, `source ~/.zshrc` to load the new configs! ## bugs From 8922d322db6444400c1d4fc30510f2870ffb70fb Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 13:20:00 -0300 Subject: [PATCH 27/31] .z is a file actually --- antigen/install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/antigen/install.sh b/antigen/install.sh index 733fd0068..a572890ff 100755 --- a/antigen/install.sh +++ b/antigen/install.sh @@ -1,2 +1,2 @@ #!/bin/zsh -mkdir ~/.z +touch ~/.z From 69747a8a0dcb0df8ec24942b11f55f4c2f1c6f37 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 13:20:15 -0300 Subject: [PATCH 28/31] Fixed git-credential-helper --- git/gitconfig.symlink.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git/gitconfig.symlink.example b/git/gitconfig.symlink.example index 7f27b456d..28700e438 100644 --- a/git/gitconfig.symlink.example +++ b/git/gitconfig.symlink.example @@ -4,7 +4,7 @@ [user] name = AUTHORNAME email = AUTHOREMAIL - helper = osxkeychain + helper = GIT_CREDENTIAL_HELPER [alias] co = checkout promote = !$ZSH/bin/git-promote From f816b81c6117a9893459363cf6ed2a1e2da91ddc Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 14:37:47 -0300 Subject: [PATCH 29/31] added docker path --- docker/path.zsh | 5 +++++ 1 file changed, 5 insertions(+) create mode 100755 docker/path.zsh diff --git a/docker/path.zsh b/docker/path.zsh new file mode 100755 index 000000000..d35848b33 --- /dev/null +++ b/docker/path.zsh @@ -0,0 +1,5 @@ +#!/bin/zsh +if test "$(which docker-machine)"; then + # shellcheck disable=SC2091 + $(docker-machine env dev) +fi From f5bb8be42de54bd9d200b63e655bb2806b8614bf Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 15:10:02 -0300 Subject: [PATCH 30/31] improved docker image --- Dockerfile | 15 ++++++++++----- README.md | 5 ++--- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index da9032b18..8e0128290 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,12 +4,17 @@ MAINTAINER Carlos Alexandro Becker RUN apt-get install -y software-properties-common wget zsh git curl -ADD . /root/.dotfiles +COPY . /root/.dotfiles RUN cd /root/.dotfiles && \ rm -f ./git/gitconfig.symlink && \ - git remote rm origin + sed \ + -e "s/AUTHORNAME/dotfiles-demo/g" \ + -e "s/AUTHOREMAIL/dotfiles-demo/g" \ + -e "s/GIT_CREDENTIAL_HELPER/cache/g" \ + ./git/gitconfig.symlink.example > ./git/gitconfig.symlink && \ + git remote rm origin && \ + ./script/bootstrap && \ + zsh -c "source ~/.zshrc" -ENTRYPOINT cd ~/.dotfiles && \ - echo "Execute ./script/bootstrap to begin! When done, source ~/.zshrc to load the new configs!" && \ - zsh +ENTRYPOINT zsh diff --git a/README.md b/README.md index 1efa56681..eb870794f 100644 --- a/README.md +++ b/README.md @@ -116,9 +116,8 @@ $ docker build -t caarlos0/dotfiles . $ docker run -it caarlos0/dotfiles ``` -It will start a fresh container with my dotfiles inside. -Run `./script/bootstrap` to setup them. -When done, `source ~/.zshrc` to load the new configs! +It will start a fresh container with my dotfiles inside and dumb git +credentials. ## bugs From d413257731e360e33b6ba9527a0549c2f9e37fd7 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Sun, 29 Mar 2015 21:07:05 -0300 Subject: [PATCH 31/31] final touch --- Dockerfile | 4 ++-- README.md | 4 ++-- docker/path.zsh | 5 +++-- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8e0128290..173a64dd8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ FROM ubuntu MAINTAINER Carlos Alexandro Becker -RUN apt-get install -y software-properties-common wget zsh git curl +RUN apt-get install -y software-properties-common wget zsh git curl python COPY . /root/.dotfiles @@ -15,6 +15,6 @@ RUN cd /root/.dotfiles && \ ./git/gitconfig.symlink.example > ./git/gitconfig.symlink && \ git remote rm origin && \ ./script/bootstrap && \ - zsh -c "source ~/.zshrc" + zsh -c "source ~/.zshrc" || true ENTRYPOINT zsh diff --git a/README.md b/README.md index eb870794f..b99559641 100644 --- a/README.md +++ b/README.md @@ -112,8 +112,8 @@ mostly because I use OS X at home and Linux at work. Yes you can! Pull the repo and run: ```sh -$ docker build -t caarlos0/dotfiles . -$ docker run -it caarlos0/dotfiles +$ docker build -t dotfiles . +$ docker run -it dotfiles ``` It will start a fresh container with my dotfiles inside and dumb git diff --git a/docker/path.zsh b/docker/path.zsh index d35848b33..5d80948ce 100755 --- a/docker/path.zsh +++ b/docker/path.zsh @@ -1,5 +1,6 @@ #!/bin/zsh -if test "$(which docker-machine)"; then +reload-docker() { # shellcheck disable=SC2091 $(docker-machine env dev) -fi +} +reload-docker >/dev/null 2>&1