mirror of
https://github.com/esphome/esphome.git
synced 2024-11-10 09:17:46 +01:00
9f84b6390d
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
24 lines
666 B
YAML
24 lines
666 B
YAML
name: Needs Docs
|
|
|
|
on:
|
|
pull_request:
|
|
types: [labeled, unlabeled]
|
|
|
|
jobs:
|
|
check:
|
|
name: Check
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Check for needs-docs label
|
|
uses: actions/github-script@v7.0.1
|
|
with:
|
|
script: |
|
|
const { data: labels } = await github.rest.issues.listLabelsOnIssue({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
issue_number: context.issue.number
|
|
});
|
|
const needsDocs = labels.find(label => label.name === 'needs-docs');
|
|
if (needsDocs) {
|
|
core.setFailed('Pull request needs docs');
|
|
}
|