diff --git a/.gitea/workflows/build->develop.yml b/.gitea/workflows/build->develop.yml index 7613fa5..f91ae9a 100644 --- a/.gitea/workflows/build->develop.yml +++ b/.gitea/workflows/build->develop.yml @@ -50,7 +50,13 @@ jobs: run: | if [[ $(git branch -r | grep origin/${{ env.DEVELOPMENT_BRANCH }} | wc -c) -eq 0 ]]; then git push origin HEAD:origin/${{ env.DEVELOPMENT_BRANCH }}; - echo 'pushed new branch'; + curl https://dl.gitea.com/tea/0.9.2/tea-0.9.2-linux-386 --output tea; + chmod +x ./tea; + ./tea login add -n=this --url=${{ github.server_url}} -t=${{ secrets.BOT_TOKEN }}; + if [[ $(./tea pr ls -f=base,head | grep "| master | ${{ env.DEVELOPMENT_BRANCH }} |" | head -c1 | wc -c) -eq 0 ]]; then + ./tea pr c --base=master --head=${{ env.DEVELOPMENT_BRANCH }} --description="development pull request" -t="WIP: ${{ github.event.head_commit.message }}" + fi + echo 'pushed new branch and created pr'; else if [[ $(git diff HEAD origin/${{ env.DEVELOPMENT_BRANCH }} | wc -c) -ne 0 ]]; then git push origin HEAD:origin/${{ env.DEVELOPMENT_BRANCH }};