Description¶
Pulls the remote branch and pushes the current branch, retrying up to five times (waiting 5, 10, ... seconds in between) if the push is rejected because someone pushed in the meantime. It does not push tags.
This is needed because the m-parse-manuscript pipeline runs alongside the ingest and pushes manuscript_parsed/ to the same branch. The ingest calls it for its final push, which pulls that commit in; the two sets of files do not overlap.
Usage¶
./automations/32_pull_push.sh [merge|rebase]merge(default) - Merge the remote branch. The existing commits, and with them theupdate<N>tags, stay as they are. Used by the ingest pipelines, which then rungit push --tags.rebase- Rebase onto the remote branch. Used by31_parse_manuscript.sh, whose commit carries no tag.
Environment Variables¶
BITBUCKET_BRANCH- Branch to push to (default: the current branch).