exists from fabric.api import * from fabric.state import env @task def vagrantbox(): env.hosts = ['127.0.0.1:2222'] env.user = 'vagrant' env.password = 'vagrant' @task def install(): execute(install_zsh) execute(install_ohmyzsh) execute(clone_dotfiles_repository) execute(run_dotbot) @task def install_zsh(): sudo('yum -y install zsh') @task def install_ohmyzsh(): run('wget --no-check-certificate http://install.ohmyz.sh -O - | sh') @task def clone_dotfiles_repository(): run('git clone --recursive https://github.com/mateusrevoredo/dotfiles.git ~/.dotfiles') @task def run_dotbot(): with cd('~/.dotfiles'): run('sh install')