Skip to content

Commit

Permalink
automate firely and sushi version update
Browse files Browse the repository at this point in the history
  • Loading branch information
leslieber committed Oct 15, 2024
1 parent 96dfb2b commit 7d39c54
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions .github/workflows/ToolUpdate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,27 @@ jobs:
run: sudo apt-get install jq

- name: Fetch latest version of firely terminal dependency
id: fetch_version
id: fetch_version_firely
run: |
# Fetch the latest version from the FirelyTeam/firely-terminal-pipeline GitHub repository
LATEST_VERSION=$(curl -s https://api.github.com/repos/FirelyTeam/firely-terminal-pipeline/releases/latest | jq -r .tag_name)
echo "LATEST_VERSION=$LATEST_VERSION" >> $GITHUB_ENV
echo "LATEST_VERSION=$LATEST_VERSION_FIRELY" >> $GITHUB_ENV
- name: Fetch latest version of Sushi dependency
id: fetch_version_sushi
run: |
# Fetch the latest version from the fhir/sushi GitHub repository
LATEST_VERSION=$(curl -s https://api.github.com/repos/FHIR/sushi/releases/latest | jq -r .tag_name)
echo "LATEST_VERSION=$LATEST_VERSION_SUSHI" >> $GITHUB_ENV
# TODO add an if statement to prevent the workflow from running if the version is the same as the one in the main.yml file

- name: Update main.yml
- name: Update main.yml for Firely and Sushi
run: |
# Update the main.yml file with the new version
# Update the main.yml file with the new versions of Firely and Sushi
sed -i "s|uses: FirelyTeam/firely-terminal-pipeline@.*|uses: FirelyTeam/firely-terminal-pipeline@$LATEST_VERSION|" .github/workflows/main.yml
sed -i "s|uses: FHIR/sushi
- name: Commit changes
env:
Expand Down

0 comments on commit 7d39c54

Please sign in to comment.