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

Feature - Add GitHub Action to add contributors to README #3824

Merged

Conversation

christianwwwwwwww
Copy link
Contributor

When a user submits a new issue, the bot first checks to see whether it is a request to be added as a contributor. If not, it quickly exits. The user will need to format the name of their request properly "Add XXXXX to contributors" in order for the action to run.

The GitHub Action ensures that:

  • the person opening the issue requests that their own name be added to the README.
  • there is a link to a GitHub repo in the issue body
  • the user has starred the Leo repo
  • the user is the author of the linked repo
  • the linked repo contains a valid Leo application (by checking for presence of a main.leo file)

Then, the GitHub action:

  • creates a properly formatted PR to insert the user along with the requested badge and emoji into the README
  • increments the Contributor Count section of the README.
  • tags the techops team to review that PR
  • comments on the issue and tags the user if there are errors with their request

Note: - For the GitHub action to be able to create PRs, we must ensure that the “Allow Github actions to create and approve pull requests” box is checked in the Leo repo under Settings -> Actions.

(cc @aharshbe )

@christianwwwwwwww christianwwwwwwww changed the title Feature - Add GitHub Action to add contributors to READM Feature - Add GitHub Action to add contributors to README Nov 6, 2023
@christianwwwwwwww christianwwwwwwww requested a review from a user November 6, 2023 20:06
Copy link

codecov bot commented Nov 6, 2023

Codecov Report

Merging #3824 (ba03b39) into testnet3 (4c0dda4) will increase coverage by 0.04%.
Report is 3 commits behind head on testnet3.
The diff coverage is n/a.

❗ Current head ba03b39 differs from pull request most recent head 472ddbd. Consider uploading reports for the commit 472ddbd to get more accurate results

@@             Coverage Diff              @@
##           testnet3    #3824      +/-   ##
============================================
+ Coverage     79.24%   79.28%   +0.04%     
============================================
  Files           172      172              
  Lines          5791     5798       +7     
  Branches       5791     5798       +7     
============================================
+ Hits           4589     4597       +8     
+ Misses         1202     1201       -1     

see 4 files with indirect coverage changes

📣 Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today!

@christianwwwwwwww christianwwwwwwww marked this pull request as ready for review November 6, 2023 21:58
@ghost
Copy link

ghost commented Nov 7, 2023

This looks good. We worked on this next to each other in the office (fodder for others). Everything works as planned. There is a slight thing where the validate_and_add_contributor action is run despite the issue created but the first check remediates that. This is a limitation of GitHub and does not currently negatively impact anything other than a few seconds of time to check per issue.

@ghost
Copy link

ghost commented Nov 7, 2023

@collinc97, when you have a moment, we need to check if the GitHub Actions interface/bot(s) have the ability to approve pull requests which can be determined by whether the “Allow Github actions to create and approve pull requests” box is checked as @christianwooddell indicated which you can locate via Settings -> Actions. Please let me know if you have any further questions or concerns.

If the box is checked, the bot should be ready and will work as expected. If not, please check that box.

Should you like to test out @christianwooddell's bot, you can do so via his instance of it here. @christianwooddell has added you to his repo; you should see an invite via email shortly.

@christianwwwwwwww christianwwwwwwww merged commit 3f6a265 into ProvableHQ:testnet3 Nov 8, 2023
6 checks passed
@christianwwwwwwww christianwwwwwwww deleted the readme-github-action branch November 8, 2023 19:04
@MarkStepa
Copy link

MarkStepa commented Nov 21, 2023

@christianwwwwwwww @aharshbe pls check my message #4679 (comment)
I think you are missing little thing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants