#!/bin/bash cd /etc/puppetlabs/code git fetch origin branch="master" if [ -n "$1" ]; then branch="$1" shift fi git reset --hard origin/$branch git submodule update --init puppet_apply "$@" --test manifests/site.pp