{"id":16821252,"url":"https://github.com/bytrangle/most-reacted-comments","last_synced_at":"2025-06-18T21:41:34.119Z","repository":{"id":65159177,"uuid":"428213672","full_name":"bytrangle/most-reacted-comments","owner":"bytrangle","description":"Collection of Github workflows to make the lives of open-source maintainer easier","archived":false,"fork":false,"pushed_at":"2021-12-06T10:37:19.000Z","size":373,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-12T13:19:13.240Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bytrangle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-11-15T10:13:32.000Z","updated_at":"2021-12-06T10:37:22.000Z","dependencies_parsed_at":"2023-01-04T12:36:39.049Z","dependency_job_id":null,"html_url":"https://github.com/bytrangle/most-reacted-comments","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/bytrangle/most-reacted-comments","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytrangle%2Fmost-reacted-comments","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytrangle%2Fmost-reacted-comments/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytrangle%2Fmost-reacted-comments/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytrangle%2Fmost-reacted-comments/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bytrangle","download_url":"https://codeload.github.com/bytrangle/most-reacted-comments/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytrangle%2Fmost-reacted-comments/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260639553,"owners_count":23040457,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-13T10:59:34.908Z","updated_at":"2025-06-18T21:41:29.103Z","avatar_url":"https://github.com/bytrangle.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Get mosted reacted comments\nA simple workflow to make long-winded issues more useful. It checks for the most reacted comments and add them to the issue's original body\n\n## Screenshot\n![screenshot](https://raw.githubusercontent.com/bytrangle/most-reacted-comments/main/action-get-most-reacted-comments.gif)\n\n## What does this action do\n\n- It is triggered on comment creation or deletion\n- Get the issue number that contains the comment in which the action is run\n- Get a list of comments for the given issue\n- If the number of comments for the issue is greater than a certain value, create a list that contains all comments that receive at least one reaction\n- If list length is greater than 0, rank the comments by the number of reactions they receive, in descending order.\n- Only take the X most reacted comments. This X value is defined by the action user.\n- Insert these comments into the issue's body.\n\n## Usage\nAn example workflow to use this action may look like this:\n\n```yml\nname: Display most reacted comments for long issue\n\non:\n  issue_comment:\n    types: [created, deleted]\n\njobs:\n  update-issue:\n    name: Get most reacted comments and add it to the issue's original post\n    runs-on: ubuntu-latest\n    steps:\n      - name: checkout repo content\n        uses: actions/checkout@v2\n      - name: add most reacted comments to issue\n        uses: bytrangle/welcome-to-open-source@v1.0\n        id: add_most_reacted_issue\n        with:\n          repo_token: ${{ secrets.GITHUB_TOKEN}} # required\n          # this can be a unique token provided by Github at the start of each workflow\n          # or a personal access token generated in Settings\n          min_total_comments: 10\n          # optional\n          # default is 20\n          max_reacted_comment_count: 3\n          # optional\n          # default is 5\n```\n\n## Why use this workflow?\nIssues with more than 20 comments are tricky. They are hard to keep up with for maintainers and long-time participants. They are also a nightmare to read for newcomers.\n\nYet it is not so easy as closing the issue, because highly-commented ones tend impact a lot of users.\n\nThis workflow will get the most reacted comments in an issue and add it to the issue's original body so that anyone can get a glimpse of the issue in the least time possible.\n\n## Caveats\nIdeally, this workflow should be run on comment reaction. However, at the moment, there is no such event hook in Github Action.\n\nWe can make do by getting the action to run on comment creation or deletion until Github actually implements the comment reaction hook.\n\n## Acknowledgement\nMany thanks to [python container action](https://github.com/jacobtomlinson/python-container-action) for sharing how to write a Docker file run Python.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbytrangle%2Fmost-reacted-comments","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbytrangle%2Fmost-reacted-comments","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbytrangle%2Fmost-reacted-comments/lists"}