From 4a1a7df5ba681e603935fddb3e60fab9bd73cbd6 Mon Sep 17 00:00:00 2001 From: cyrus Date: Tue, 7 Nov 2023 13:06:52 +0900 Subject: [PATCH] =?UTF-8?q?update:=20Dependabot=E3=80=81Github=20Actions?= =?UTF-8?q?=E7=94=A8=E8=A8=AD=E5=AE=9A=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/dependabot.yml | 3 --- .github/workflows/maven.yml | 16 +++++++++++++++- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 53559f3..ac6a5cb 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -7,6 +7,3 @@ updates: time: "00:00" timezone: Asia/Tokyo open-pull-requests-limit: 10 - labels: - - "dependencies" - - "automerge" diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index c97209a..5a07c52 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -12,6 +12,9 @@ on: jobs: build: runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write steps: - uses: actions/checkout@v3 - name: Set up JDK 8 @@ -21,4 +24,15 @@ jobs: java-version: 8 cache: maven - name: Build with Maven - run: mvn -B package --file pom.xml \ No newline at end of file + run: mvn -B package --file pom.xml + - name: Add label + uses: actions/github-script@v6 + if: ${{ github.event_name == 'pull_request' }} + with: + script: | + github.rest.issues.addLabels({ + issue_number: context.issue.number, + owner: context.repo.owner, + repo: context.repo.repo, + labels: ["automerge"] + }) \ No newline at end of file