GitHub Action - Repository Roster | ๐Ÿ“ข Shout-out Supporters In Your README.md

GitHub Action - Repository Roster | ๐Ÿ“ข Shout-out Supporters In Your README.md

ยท

2 min read

As developers, we put a lot of work into our GitHub repos to make them as useful as possible for others, but great projects sometimes go under-appreciated, and under-starred. Asking for stars is tacky, but publicly thanking your supporters by name in your README file is a sign of appreciation that happens to incentivize more users to join the crowd.

๐Ÿ’ก Inspiration

One fine day I got an email DEV Digest in which I got attracted by the title 1 Step to Incentivize Stars and Forks on GitHub and decided to read the full article. it was new & interesting to me. Thanks to @ nastyox1 creating such an awesome tool. so I wanted to use it but I wanted it to be a markdown-table output which was not an option with that cloud-hosted service. so I decided to create this as an action that can provide various outputs.

check out the examples output


๐Ÿš€ Usage

  1. Update Your README.md with the below code
  2. Setup Action Workflow File

Repository Stargazers

## โ†ณ Stargazers
<!-- REPOSITORY_STARS:START --> <!-- REPOSITORY_STARS:END -->

Repository Forks

## โ†ณ Forkers
<!-- REPOSITORY_FORKS:START --><!-- REPOSITORY_FORKS:END -->

โ„น๏ธ Currently there are ways to auto-trigger the workflow when a user stars / forks the repository.

โ„น๏ธ Using this action with the workflow trigger fork & watch is the best optmized way.

if you want to remove users that have un-stared / deleted the fork then you might have to use cron to handle it

Workflow File

name: "๐Ÿ™ Repository Roster"

on:
  workflow_dispatch:
  fork:
  watch:
    types:
      - started

jobs:
  update_latest_roster:
    name: "๐Ÿ”  Update Latest Roster"
    runs-on: ubuntu-latest
    steps:
      - name: "๐Ÿ“ฅ  Fetching Repository Contents"
        uses: actions/checkout@main

      - name: "๐Ÿ”  Markdown - Repository Roster"
        uses: "varunsridharan/action-repository-roster@main"
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Example Output

https://s2.do-spaces.com/2020/Nov/06/1604642798-178.jpg

For more details about the available config options. please check our GitHub repository