Enhance scm-dev.sh to allow specific branch requests.

This commit is contained in:
Hyperling 2021-07-19 17:56:04 -05:00
parent e2e5c23322
commit cde640a16e

View File

@ -43,8 +43,21 @@
path: "{{ user_root.home }}/bin/scm-dev.sh" path: "{{ user_root.home }}/bin/scm-dev.sh"
block: | block: |
# 20210713 - Make life easier for development! # 20210713 - Make life easier for development!
## Variables ##
# Use a specific branch if it was asked for.
branch="dev"
if [[ $1 != "" ]]; then
branch="$1"
fi
## Main ##
push.sh push.sh
{{ ansible_pull_exec.stdout }} -U https://github.com/Hyperling/ansible.git --checkout dev time {{ ansible_pull_exec.stdout }} -U https://github.com/Hyperling/ansible.git --checkout $branch
marker: '{mark}' marker: '{mark}'
marker_begin: "#!{{ bash_exec.stdout }}" marker_begin: "#!{{ bash_exec.stdout }}"
marker_end: "exit 0" marker_end: "exit 0"