Skip to content

composer(deps-dev): Bump ergebnis/composer-normalize from 2.19.0 to 2.30.2 #300

composer(deps-dev): Bump ergebnis/composer-normalize from 2.19.0 to 2.30.2

composer(deps-dev): Bump ergebnis/composer-normalize from 2.19.0 to 2.30.2 #300

Workflow file for this run

# https://docs.github.com/en/actions
name: "Triage"
on: # yamllint disable-line rule:truthy
pull_request_target:
types:
- "opened"
jobs:
label:
name: "Label"
runs-on: "ubuntu-latest"
steps:
- name: "Add labels based on branch name"
uses: "actions/github-script@v6"
with:
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}"
script: |
const branchPrefixLabels = {
feature: "enhancement",
fix: "bug",
}
const pullRequest = context.payload.pull_request
const repository = context.repo
const branchName = pullRequest.head.ref
const matches = branchName.match(new RegExp('^([^/]+)\/'));
if (matches instanceof Array && branchPrefixLabels.hasOwnProperty(matches[1])) {
const label = branchPrefixLabels[matches[1]]
github.rest.issues.addLabels({
issue_number: pullRequest.number,
labels: [
label
],
owner: repository.owner,
repo: repository.repo,
});
}