Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ci): Separate workflows by workflow trigger, rename config files #31745

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
23 changes: 2 additions & 21 deletions .github/workflows/pr-labeler.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Pull request labeler
name: Label PRs by path

on:
- pull_request_target
Expand All @@ -16,24 +16,5 @@ jobs:
steps:
- uses: actions/labeler@v4
with:
configuration-path: ".github/pr-labels-by-path.yml" # Path to pr-path-labeler config
repo-token: "${{ secrets.GITHUB_TOKEN }}"

# Docs: https://github.com/cbrgm/pr-size-labeler-action
label-by-size:
# do not run on forks
if: github.repository == 'mdn/content'
needs: label-by-path
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false

- name: Label PR based on size
uses: cbrgm/pr-size-labeler-action@main
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
github_repository: ${{ github.repository }} # Repository name
github_pr_number: ${{ github.event.number }} # Pull request number
config_file_path: ".github/pull-request-size.yml" # Path to pr-size-labeler config
26 changes: 26 additions & 0 deletions .github/workflows/pr-size-labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Label PRs by size

on:
pull_request:
branches:
- "main"

jobs:
# Docs: https://github.com/cbrgm/pr-size-labeler-action
label-by-size:
# do not run on forks
if: github.repository == 'mdn/content'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false

- name: Label PR based on size
uses: cbrgm/pr-size-labeler-action@main
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
github_repository: ${{ github.repository }} # Repository name
github_pr_number: ${{ github.event.number }} # Pull request number
config_file_path: ".github/pr-labels-by-size.yml" # Path to pr-size-labeler config
Loading