Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: add changeset automation #1653

Merged
merged 13 commits into from
Apr 9, 2025

Conversation

Shurtu-gal
Copy link
Collaborator

@Shurtu-gal Shurtu-gal commented Feb 8, 2025

Description

This pull request introduces an automated workflow for generating changesets for pull requests. The most important changes include the addition of a new GitHub Actions workflow and utility functions to handle changeset generation and commenting on pull requests.

Changeset Automation Workflow:

  • .github/workflows/auto-changeset.yml: Added a new workflow to automate changeset generation for pull requests with specific titles. This workflow runs on various pull request events and includes steps for checking out the repository, installing dependencies, generating changeset contents, creating and committing the changeset file, pushing the changeset file, and commenting on the pull request.

Utility Functions for Changeset Generation:

  • .github/workflows/changeset-utils/index.js: Added utility functions to:
    • Filter and format commits from a pull request.
    • Identify released packages by analyzing modified files.
    • Generate release notes from commit messages.
    • Create changeset contents based on the pull request title and release notes.
    • Comment on the pull request with the generated changeset, updating the comment if it already exists.

Workflows and proof: Shurtu-gal/action-test-bed#8

Related issue(s)
Fixes #1652

Signed-off-by: Ashish Padhy <100484401+Shurtu-gal@users.noreply.github.com>
Signed-off-by: Ashish Padhy <100484401+Shurtu-gal@users.noreply.github.com>
@Shurtu-gal Shurtu-gal added the area/ci-cd Specify what technical area given issue relates to. Its goal is to ease filtering good first issues. label Feb 8, 2025
@Shurtu-gal Shurtu-gal self-assigned this Feb 8, 2025
Copy link

changeset-bot bot commented Feb 8, 2025

⚠️ No Changeset found

Latest commit: da7826d

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@Shurtu-gal
Copy link
Collaborator Author

Pinging @derberg as this is related to CI/CD as well.

@Shurtu-gal Shurtu-gal marked this pull request as draft April 6, 2025 13:00
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
@Shurtu-gal Shurtu-gal marked this pull request as ready for review April 6, 2025 17:00
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
@Shurtu-gal
Copy link
Collaborator Author

I have made the workflow more modular with pretty good release notes. Also, if anybody wants, they can add skip-changeset to skip the workflow.

Test bench: Shurtu-gal/action-test-bed#5

Will create another test-bench with studio repo clone.

cc: @derberg @aeworxet

@Shurtu-gal Shurtu-gal requested a review from derberg April 6, 2025 17:04
@Shurtu-gal Shurtu-gal moved this from To Triage to In progress in CLI - Kanban Apr 6, 2025
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
@Shurtu-gal
Copy link
Collaborator Author

Okay, made a proper test bench with multiple packages (bonafide mono-repo).

Shurtu-gal/action-test-bed#8
cc: @derberg

Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
Signed-off-by: Ashish Padhy <ashishpadhy1729@gmail.com>
Copy link

sonarqubecloud bot commented Apr 7, 2025

@Shurtu-gal Shurtu-gal requested a review from derberg April 7, 2025 10:10
@derberg
Copy link
Member

derberg commented Apr 7, 2025

nice work, let's see how is it going to work in action

@github-project-automation github-project-automation bot moved this from In progress to Backlog in CLI - Kanban Apr 9, 2025
@Amzani
Copy link
Collaborator

Amzani commented Apr 9, 2025

/rtm

@asyncapi-bot asyncapi-bot merged commit 6902e04 into asyncapi:master Apr 9, 2025
23 checks passed
@github-project-automation github-project-automation bot moved this from Backlog to Done in CLI - Kanban Apr 9, 2025
@asyncapi-bot asyncapi-bot added the bounty AsyncAPI Bounty program related label label Apr 9, 2025
@aeworxet
Copy link
Contributor

aeworxet commented Apr 9, 2025

@asyncapi/bounty_team

@aeworxet aeworxet moved this to Completed in Bounty Program Apr 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ci-cd Specify what technical area given issue relates to. Its goal is to ease filtering good first issues. bounty AsyncAPI Bounty program related label ready-to-merge
Projects
Status: Completed
Status: Done
Development

Successfully merging this pull request may close these issues.

Improve automation w.r.t. changeset addition
6 participants