ExonomyOrg / exosystems_nuxt

0 stars 0 forks source link

GitHub Action for Managing Parent-Child Issue Relationships #17

Open exonomyapp opened 2 weeks ago

exonomyapp commented 2 weeks ago

Gist: GitHub Action for Managing Parent-Child Issue Relationships

In the gist is described an example GitHub Action that is automatically triggered every time any comment is added to any issue. This GitHub Action will automatically update the description of every issue that is defined as a "Parent" issue in the description of any other issue that considers itself a "child" of that "parent" issue. We must regulate this ourselves by making sure to mention in every issue if it has any parent issues by adding this information, as follows:

"Parents: #12, #81, #9"

If the GitHub Action finds a "Parents:" declaration in the description of any issue that has a comment added to it, all the parents identified in that child will have their descriptions automatically updated with information about their child issues

This Action will make sure that every Issue that is labeled as a parent also automatically receives a report about its children somewhere in its own description. You can think about it as a reverse adoption service. Instead of the parent identifying its next child, the child identifies its next parent. The essential elements of the task are to create a GitHub action and provide it with a YAML file that contains the Unix commands for the GitHub CLI (gh) to execute against our Issues and their descriptions.

The education provided by accomplishing this task is:

And these skills will be added to your certificate of completion when your internship is over.

CompileWithG commented 2 weeks ago

Progress Update on GitHub Action for Managing Parent-Child Issue Relationships

I have implemented a GitHub Action that updates the description of parent issues whenever a comment is added to any child issue. Here’s a summary of the steps taken:

  1. GitHub Action Setup:

    • Created a YAML file for the GitHub Action, which is triggered on issue comments.
    • Installed necessary tools including GitHub CLI.
    • Authenticated with GitHub CLI using the provided token.
  2. Processing Logic:

    • The action retrieves the issue title and body.
    • It cleans up the body to remove any previous "Parents:" references.
    • Extracts the parent issue numbers and updates their descriptions with information about the child issue.
  3. Technical Details:

  4. Testing:

    • The YAML file has been tested on my own repositories and works perfectly. All functionalities have been verified to ensure correct operation.

The action should now properly update parent issues with details about their child issues. Please review the provided Google Doc for a detailed explanation of the setup and configuration.

exonomyapp commented 2 weeks ago

I pushed the changes for this issue. Let's add this comment and see if it works.