Git Product home page Git Product logo

team-labeler-action's Introduction

Team Labeler Action 👥

build test GitHub issues GitHub forks GitHub stars GitHub license Watch on GitHub Tweet

This repository provides a GitHub action to automatically team label on a pull request based author team. This is useful if multiple team are working on the same project.

example

Configuration

Create .github/teams.yml

You need to provide a yml file that contains members of your teams:

LightSide:
  - '@Yoda'
  - '@Luke'

DarkSide:
  - '@DarkVador'
  - '@Palpatine'

Usage

Create .github/workflows/team-labeler.yml

Create a workflow (eg: .github/workflows/team-labeler.yml see Creating a Workflow file) to utilize the labeler action. This action only needs the GITHUB_TOKEN secret as it interacts with the GitHub API to modify labels. It's working for pull request and issues. The action can be used as such:

on:
  pull_request:
  issues:
name: team-label
permissions:
  contents: read
  pull-requests: write
jobs:
  team-labeler:
    runs-on: ubuntu-latest
    steps:
    - uses: JulienKode/[email protected]
      with:
        repo-token: "${{ secrets.GITHUB_TOKEN }}"

team-labeler-action's People

Contributors

7ph avatar codepunkt avatar dependabot[bot] avatar eiriksm avatar julienkode avatar mariaines avatar renovate[bot] avatar talboren avatar toadjaune avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

team-labeler-action's Issues

Github Action does not Label PRs

Hi, just wondering if this project is still supported as I'm struggling to get it to work

As you can see, I'd expect my PR to be tagged with the Improvement label.

Do you have any advice?

What `GITHUB_TOKEN` permission are needed?

If you could list the permissions needed on the GITHUB_TOKEN, it might save some time for others who run into the same issue that I did. Our GITHUB_TOKEN permissions are set org-wide to read-only, so we have to override in each workflow file. This is what I used:

permissions:
  content: read
  pull_requests: write

However it looks like if the label doesn't exist, it might need more write permissions to create it (See: #88). Unfortunately the GitHub docs aren't that detailed about what permissions allow you to do what, as far as I can tell.

Add support for issues

This action only works with Pull Requests. It is not able to label issues based on author. It just fails silently without adding label.

image

Compare usernames without case-senstitivity

It seems like the username matching is case-sensitive. It would be convenient to not have that, since it just silently "fails".

I'd be happy to help out, I just don't have time right now.

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update actions/checkout action to v4
  • chore(deps): update dependency eslint to v9
  • chore(deps): update dependency eslint-plugin-jest to v28
  • 🔐 Create all rate-limited PRs at once 🔐

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

github-actions
.github/workflows/build.yml
  • actions/checkout v3
.github/workflows/test.yml
  • actions/checkout v3
npm
package.json
  • @actions/core 1.10.1
  • @actions/github 5.1.1
  • js-yaml 4.1.0
  • @types/jest 29.5.11
  • @types/js-yaml 4.0.9
  • @types/node 18.19.4
  • @typescript-eslint/parser 5.62.0
  • @vercel/ncc 0.38.1
  • eslint 8.56.0
  • eslint-plugin-github 4.7.0
  • eslint-plugin-jest 27.4.2
  • eslint-plugin-prettier 4.2.1
  • jest 29.7.0
  • jest-circus 29.7.0
  • js-yaml 4.1.0
  • prettier 2.8.8
  • ts-jest 29.1.1
  • typescript 5.0.4

  • Check this box to trigger a request for Renovate to run again on this repository

Action Required: Fix Renovate Configuration

There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.

Error type: undefined. Note: this is a nested preset so please contact the preset author if you are unable to fix it yourself.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.