File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11#! /bin/bash
22set -eo pipefail
33
4- git config --global pull.rebase false
5- git remote add template https://github.com/blooop/python_template.git
4+ TEMPLATE_URL=" ${TEMPLATE_URL:- https:// github.com/ blooop/ python_template.git} "
5+ BRANCH=" ${BRANCH:- feature/ update_from_template} "
6+
7+ git config pull.rebase false
8+ git remote remove template 2> /dev/null || true
9+ git remote add template " $TEMPLATE_URL "
610git fetch --all
711git checkout main && git pull origin main
8- git checkout -B feature/update_from_template ; git pull
12+ git checkout -B " $BRANCH "
913git merge template/main --allow-unrelated-histories -m ' feat: pull changes from remote template'
10- git checkout --ours pixi.lock
14+ git checkout --ours pixi.lock 2> /dev/null || true
1115
1216# regenerate lockfile to match merged pyproject.toml
1317pixi update
1418git add pixi.lock
1519git diff --cached --quiet || git commit -m ' chore: update pixi.lock after template merge'
1620
1721git remote remove template
18- git push --set-upstream origin feature/update_from_template
22+ git push --set-upstream origin " $BRANCH "
1923git checkout main
You can’t perform that action at this time.
0 commit comments