Skip to content

Conversation

@FidelusAleksander
Copy link
Contributor

@FidelusAleksander FidelusAleksander commented May 29, 2025

Description

Because reusable workflows in exercise-toolkit sometimes use other parts of the exercise-toolkit we had to update the git references (versions) to these parts every time they were updated.

This PR aims to automate that, so we don't need to manually do PR's like the following: (we would just approve/merge them)

Changes

This GitHub Actions workflow automatically updates version references in reusable workflow files whenever changes are pushed to the main branch, creating a pull request with the updated EXERCISE_TOOLKIT_REF environment variable set to the latest commit SHA.

Checklist

  • I have added or updated appropriate labels to this PR
  • I have tested my changes
  • I have updated the documentation if needed

Copilot AI review requested due to automatic review settings May 29, 2025 09:03
@github-actions github-actions bot added workflows Changes to reusable workflows maintenance Maintenance work on the repository labels May 29, 2025
@FidelusAleksander FidelusAleksander removed the workflows Changes to reusable workflows label May 29, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR automates the update of the EXERCISE_TOOLKIT_REF environment variable across reusable workflow files by replacing hard-coded version strings with a dynamic environment variable and introducing a new workflow to update those self-references automatically.

  • Replaces static version references with a dynamic environment variable in start-exercise.yml and finish-exercise.yml.
  • Adds a new workflow (_update-self-references.yml) to automate the update of self-references based on the latest commit SHA.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
.github/workflows/start-exercise.yml Replaces static version with a dynamic environment variable
.github/workflows/finish-exercise.yml Replaces static version with a dynamic environment variable
.github/workflows/_update-self-references.yml Introduces an automated workflow to update version references

@github-actions github-actions bot added the workflows Changes to reusable workflows label May 29, 2025
@FidelusAleksander FidelusAleksander removed the workflows Changes to reusable workflows label May 29, 2025
Copy link

@arilivigni arilivigni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AWESOME!

Copy link
Member

@chriswblake chriswblake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it! 🚀

@FidelusAleksander FidelusAleksander merged commit 839e85c into main May 30, 2025
6 checks passed
@FidelusAleksander FidelusAleksander deleted the update-self-references-workflow branch May 30, 2025 10:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Maintenance work on the repository

Development

Successfully merging this pull request may close these issues.

4 participants