Skip to content

Does not add tag for matching base branch. #34

@SpacyRicochet

Description

@SpacyRicochet

I'm trying to make have a release label for any PRs that are to be merged in a release branch (e.g. release/1.0.1). However, this doesn't appear to be working, as the release label is never added. Other labels are added however, such as the chore label, which is done because the head is names chore/some-branch-name.

This is the configuration. After running the action, only the chore label is added to the PR.

Only chore is added.

HEAD: chore/pr-labeler
BASE: release/3.15

Configuration file (.github/pr-branch-labeler.yml);

# Apply label "release" is base matches "release/*"
release:
  base: ["release/**"]

# Apply label "feature" if head matches "feature/*"
feature:
  head: ["feature/*"]

# Apply label "bugfix" if head matches one of "bugfix/*" or "hotfix/*"
bugfix:
  head: ["bugfix/*", "hotfix/*"]

# Apply label "chore" if head matches one of "chore/*" or "maintenance/*"
chore:
  head: ["chore/*", "maintenance/*"]

The version in the README.md (base: "release/*") has also been tried.

Workflow action;

name: PR Preflight

on:
  pull_request:

jobs:
  label_prs:
    runs-on: macOS-11
    steps:
    - name: Label PRs
      uses: ffittschen/pr-branch-labeler@v1
      with:
        repo-token: ${{ github.token }}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions