Skip to content

Commit fed7d23

Browse files
committed
CI: Label development dependencies as "dev-dependencies"
1 parent 189132d commit fed7d23

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Dependabot Pull Request
2+
on: pull_request_target
3+
jobs:
4+
build:
5+
runs-on: ubuntu-latest
6+
if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' }}
7+
steps:
8+
- name: Fetch Dependabot metadata
9+
id: dependabot-metadata
10+
uses: dependabot/fetch-metadata@v1
11+
with:
12+
github-token: "${{ secrets.GITHUB_TOKEN }}"
13+
- name: Add dev-dependencies label
14+
uses: actions-ecosystem/action-add-labels@v1
15+
if: ${{ steps.dependabot-metadata.outputs.dependency-type == 'direct:development' }}
16+
with:
17+
labels: dev-dependencies
18+
- name: Remove dependencies label
19+
uses: actions-ecosystem/action-remove-labels@v1
20+
if: ${{ steps.dependabot-metadata.outputs.dependency-type == 'direct:development' }}
21+
with:
22+
labels: dependencies

0 commit comments

Comments
 (0)