Skip to content

Commit

Permalink
workflow: the bot should use the latest published release
Browse files Browse the repository at this point in the history
Currently the bot always used the latest commit on main. This should
make pushing to main less impactful, make releases have some use, and
force me to publish more releases.
  • Loading branch information
amadejpapez committed Jun 26, 2023
1 parent 99511ec commit 4a52262
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,16 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Checkout main
- name: Get latest release tag
id: get_latest_tag
run: |
echo "latest_tag=$(curl -s https://api.github.com/repos/amadejpapez/ApplSec/releases/latest | jq '.tag_name' | sed 's/\"//g')" >> $GITHUB_OUTPUT
- name: Checkout main, latest release
uses: actions/checkout@v3
with:
path: main
ref: ${{ steps.get_latest_tag.outputs.latest_tag }}

- name: Checkout posted_data_json
uses: actions/checkout@v3
Expand Down

0 comments on commit 4a52262

Please sign in to comment.