File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change 6060
6161 permissions :
6262 id-token : write # required to push with trusted-pypi-token
63+
64+ env :
65+ BRANCH : ${{ github.event.release.target_commitish }}
6366
6467 steps :
6568 - name : Set up Python 3.12
@@ -87,10 +90,10 @@ jobs:
8790 contents : write # required to push with GITHUB_TOKEN
8891
8992 steps :
90- - name : Checkout main branch
93+ - name : Checkout release target branch
9194 uses : actions/checkout@v4
9295 with :
93- ref : main
96+ ref : $BRANCH
9497
9598 - name : Set up Python 3.12
9699 uses : actions/setup-python@v5
@@ -120,8 +123,8 @@ jobs:
120123 echo "No changes to commit"
121124 fi
122125
123- - name : Push commit to main
126+ - name : Push commit to branch
124127 # GITHUB_TOKEN is automatically provided
125128 run : |
126129 git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
127- git push origin main
130+ git push origin HEAD:$BRANCH
You can’t perform that action at this time.
0 commit comments