1
0
mirror of synced 2025-12-19 18:10:59 -05:00

Move docs engineering reviewer to Action workflow (#36882)

Co-authored-by: Peter Bengtsson <peterbe@github.com>
This commit is contained in:
Kevin Heis
2023-05-10 11:49:59 -07:00
committed by GitHub
parent 236b36ed8f
commit a02ae16a7c
5 changed files with 50 additions and 55 deletions

18
.github/CODEOWNERS vendored
View File

@@ -3,26 +3,8 @@
# https://docs.github.com/articles/about-codeowners
# https://git-scm.com/docs/gitignore
# Engineering
*.js @github/docs-engineering
*.ts @github/docs-engineering
*.tsx @github/docs-engineering
/.github/ @github/docs-engineering
/script/ @github/docs-engineering
/includes/ @github/docs-engineering
Dockerfile @github/docs-engineering
package-lock.json @github/docs-engineering
package.json @github/docs-engineering
# Site Policy
/content/site-policy/ @github/site-policy-admins
# Content strategy
/contributing/content-markup-reference.md @github/docs-content-strategy
/contributing/content-style-guide.md @github/docs-content-strategy
/contributing/content-model.md @github/docs-content-strategy
/contributing/content-style-guide.md @github/docs-content-strategy
/contributing/content-templates.md @github/docs-content-strategy
# Requires review of #actions-oidc-integration, docs-engineering/issues/1506
content/actions/deployment/security-hardening-your-deployments/** @github/oidc

15
.github/labeler.yml vendored
View File

@@ -1,15 +0,0 @@
engineering:
- lib/*
- lib/**/*
- middleware/*
- middleware/**/*
- tests/*
- tests/**/*
- stylesheets/*
- stylesheets/**/*
- script/*
- script/**/*
- components/*
- components/**/*
- pages/*
- pages/**/*

View File

@@ -1,22 +0,0 @@
name: Auto label Pull Requests
# **What it does**: Automatically adds the engineering label when specific files change.
# **Why we have it**: Other automation applies specifically to engineering label issues and pull requests.
# **Who does it impact**: Automation that relies on the engineering label.
on:
pull_request:
permissions:
contents: read
pull-requests: write
jobs:
triage:
if: github.repository == 'github/docs-internal'
runs-on: ubuntu-latest
steps:
# See labeling configuration in the `.github/labeler.yml` file
- uses: actions/labeler@e54e5b338fbd6e6cdb5d60f51c22335fc57c401e
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'

View File

@@ -0,0 +1,21 @@
name: Codeowners - Content Strategy
# **What it does**: Automatically add reviewers based on paths, but only for the docs-internal repo.
# **Why we have it**: So we can have reviewers automatically without getting open source notifications.
# **Who does it impact**: Docs team.
on:
pull_request:
paths:
- '/contributing/content-*.md'
jobs:
codeowners-content-strategy:
if: ${{ github.repository == 'github/docs-internal' }}
runs-on: ubuntu-latest
steps:
- name: Add Content Strategy as a reviewer
env:
GH_TOKEN: ${{ secrets.DOCS_BOT_FR }}
PR: ${{ github.event.pull_request.html_url }}
run: gh pr edit $PR --add-reviewer github/docs-content-strategy

View File

@@ -0,0 +1,29 @@
name: Codeowners - Docs Engineering
# **What it does**: Automatically add reviewers based on paths, but only for the docs-internal repo.
# And sets the 'engineering' label on the PR.
# **Why we have it**: So we can have reviewers automatically without getting open source notifications.
# **Who does it impact**: Docs team.
on:
pull_request:
paths:
- '**.js'
- '**.ts'
- '**.tsx'
- '**.scss'
- 'src/**'
- '.github/**'
- '**Dockerfile'
- 'package*.json'
jobs:
codeowners-docs-engineering:
if: ${{ github.repository == 'github/docs-internal' }}
runs-on: ubuntu-latest
steps:
- name: Add Docs Engineering as a reviewer
env:
GH_TOKEN: ${{ secrets.DOCS_BOT_FR }}
PR: ${{ github.event.pull_request.html_url }}
run: gh pr edit $PR --add-reviewer github/docs-engineering --add-label engineering