Skip to content

Commit

Permalink
fix: Updated with dynamic branch
Browse files Browse the repository at this point in the history
  • Loading branch information
lakshmiravalir authored Aug 25, 2021
1 parent 7e8882b commit 954a02d
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ jobs:
- run: npm test
updateAPIDefinitions:
runs-on: ubuntu-latest
needs: [build]
outputs:
changeLog: ${{ steps.updateFolder.outputs.changeLog }}
steps:
- run: mkdir -p ~/oai_definitions/json
- run: cd ~/oai_definitions
Expand All @@ -44,13 +47,14 @@ jobs:
id: updateFolder
run: |
cp -R ~/oai_definitions/CHANGES.md OAI_CHANGES.md
bash scripts/updateApiDefinitions.sh
source scripts/updateApiDefinitions.sh
echo "::set-output name=changeLog::$changeLog"
release:
runs-on: ubuntu-latest
needs: [updateAPIDefinitions]
steps:
- uses: actions/checkout@v2
- run: git pull origin test_branch_actions
- run: git pull
- run: git branch
- run: git log -3
- run: npm install
Expand All @@ -69,17 +73,15 @@ jobs:
strategy:
matrix:
node-version: [10.x]
needs: [release]
needs: [updateAPIDefinitions, release]
steps:
- uses: actions/checkout@v2
- run: git fetch --tags
- name: Getting tag
id: test
run: |
echo "::set-output name=TAG_NAME::$(git describe --tags $(git rev-list --tags --max-count=1))"
echo "::set-output name=CHANGE_LOG::$(node scripts/update-api-definitions.js)"
- run: echo "${{steps.test.outputs.TAG_NAME}}"
- run: echo "${{steps.test.outputs.CHANGE_LOG}}"
- name: update release
id: update_release
uses: tubone24/[email protected]
Expand All @@ -88,4 +90,4 @@ jobs:
TAG_NAME: ${{steps.test.outputs.TAG_NAME}}
with:
is_append_body: true
body: ${{env.CHANGE_LOG}} # new body text
body: ${{needs.updateAPIDefinitions.outputs.changeLog}}

0 comments on commit 954a02d

Please sign in to comment.