Skip to content
Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Latest commit

Β 

History

1,431 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

All Contributors Auto Action

Fills in missing allcontributors entries for a repository. πŸ‘ͺ

πŸ‘ͺ All Contributors: 5 🀝 Code of Conduct: Kept πŸ§ͺ Coverage πŸ“ License: MIT πŸ’ͺ TypeScript: Strict

Usage

This action will:

  1. Ask all-contributors-for-repository to collect the current repository's contributors
  2. Post @all-contributors add bot comments in the newest issues and PRs for each contributor

Warning This tool only sees contributions that can be detected from the last 500 events in GitHub's API. Don't forget to manually add in other forms of contributions!

For example, the following job will run on every push to main:

# .github/workflows/contributors.yml
name: Contributors

on:
  push:
    branches:
      - main

permissions:
  contents: read
  issues: write
  pull-requests: write

jobs:
  contributors:
    runs-on: ubuntu-latest
    steps:
      - uses: JoshuaKGoldberg/all-contributors-auto-action@v0.7.0
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

...and will post comments like the following automatically:

@all-contributors please add JoshuaKGoldberg for code.

πŸ€– Beep boop! This comment was added automatically by all-contributors-auto-action.

Not all contributions can be detected from Git & GitHub alone. Please comment any missing contribution types this bot missed.

...and of course, thank you for contributing! πŸ’™

Token and Permissions

The action reads its GitHub token from the GH_TOKEN or GITHUB_TOKEN environment variable. See get-github-auth-token for more details. It uses that token to:

  • Read the repository's issues, pull requests, commits, and events to detect contributions
  • Read the repository's .all-contributorsrc file to see which contributors are already recorded
  • Post @all-contributors comments on issues and pull requests

The workflow's built-in secrets.GITHUB_TOKEN works as long as the job is granted these permissions:

permissions:
  contents: read
  issues: write
  pull-requests: write

Alternately, you can use a fine-grained personal access token stored as a repository secret. Grant it these repository permissions:

  • Contents: Read-only
  • Issues: Read and write
  • Pull requests: Read and write
  • Metadata: Read-only (selected automatically)

A classic personal access token needs the public_repo scope for public repositories, or the repo scope for private repositories.

Then pass it to the action instead of secrets.GITHUB_TOKEN:

- uses: JoshuaKGoldberg/all-contributors-auto-action@v0.7.0
  env:
    GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}

Inputs

ignored-logins

RegExp patterns to use for omitting sets of logins (e.g. dependabot). The action will not attempt to add these users as contributors. Powered by all-contributors-for-repository, which comes with its own set of reasonable defaults (e.g. \[bot\]$). All patterns will be used to create RegExp with case-insensitive matching.

# .github/workflows/contributors.yml
name: Contributors

on:
  push:
    branches:
      - main

permissions:
  contents: read
  issues: write
  pull-requests: write

jobs:
  contributors:
    runs-on: ubuntu-latest
    steps:
      - uses: JoshuaKGoldberg/all-contributors-auto-action@v0.7.0
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          ignored-logins: |
            -admin$
            -it$

since

How far back to look for contributions. Defaults to auto.

  • auto: Look back to when the workflow's previous successful run started, so repeated runs don't re-request contributions they've already seen. This requires the job to have the actions: read permission. If there is no previous successful run, or it can't be determined, all available history is used.
  • all: Look at all available history.
  • An ISO 8601 date, such as 2026-01-01, or a duration such as 12h, 7d, or 2w.

Only the contributions made since that time are requested from GitHub. This makes each run faster and cheaper in API requests, especially on busy repositories.

A contributor's older contributions won't be seen by a windowed run, though. To also catch anything a windowed run missed, consider running a full scan on a schedule alongside the windowed runs:

# .github/workflows/contributors.yml
name: Contributors

on:
  push:
    branches:
      - main
  schedule:
    - cron: "0 0 * * 0"

permissions:
  actions: read
  contents: read
  issues: write
  pull-requests: write

jobs:
  contributors:
    runs-on: ubuntu-latest
    steps:
      - uses: JoshuaKGoldberg/all-contributors-auto-action@v0.7.0
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          since: ${{ github.event_name == 'schedule' && 'all' || 'auto' }}

Development

See .github/CONTRIBUTING.md, then .github/DEVELOPMENT.md. Thanks! πŸ‘ͺ

Contributors

Fabian De La PeΓ±a Montero
Fabian De La PeΓ±a Montero

πŸ“–
John Reilly
John Reilly

πŸ€”
Josh Goldberg
Josh Goldberg

πŸ”§ πŸ’» πŸ–‹ πŸ“– πŸ€” πŸš‡ 🚧 πŸ“† ⚠️
doudou0720
doudou0720

πŸ›
michael faith
michael faith

πŸ› πŸ€”

πŸ’ This package was templated with create-typescript-app using the Bingo engine.

About

Fills in missing allcontributors entries for a repository. πŸ‘ͺ

Resources

Code of conduct

Contributing

Security policy

Stars

16 stars

Watchers

0 watching

Forks

Releases

Sponsor this project

Used by

Contributors

Languages