Skip to content

Commit

Permalink
Added check for existence of branches repository
Browse files Browse the repository at this point in the history
  • Loading branch information
fulminazzo committed Apr 2, 2024
1 parent 10de76a commit af1e40b
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,18 +49,15 @@ jobs:
- name: Setup Gradle
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5

- name: Checkout to badges branch
run: 'git checkout -b badges'
shell: bash

- name: Merge from current branch
- name: Checkout to badges Branch and Merge from Current
if: ${{ github.ref_name != 'badges' }}
env:
BRANCH: ${{ github.ref_name }}
run: |-
git merge $BRANCH
run: |-
export BRANCHES=$(git branch -r)
test $(echo $BRANCHES | grep badges) && git pull origin badges
git checkout -b badges
git merge $BRANCH
if [[ $(echo $BRANCHES | grep badges) ]]; then git pull origin badges; fi
shell: bash

- name: Test with Gradle Wrapper
Expand Down

0 comments on commit af1e40b

Please sign in to comment.