-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
bartlomiej.zylinski
committed
May 6, 2024
1 parent
78af4b7
commit 533e2e8
Showing
4 changed files
with
55 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
version: 1 | ||
labels: | ||
- label: "automerge" | ||
authors: ["softwaremill-ci"] | ||
files: | ||
- "build.sbt" | ||
- "project/plugins.sbt" | ||
- "project/build.properties" | ||
- label: "dependency" | ||
authors: ["softwaremill-ci"] | ||
files: | ||
- "build.sbt" | ||
- "project/plugins.sbt" | ||
- "project/build.properties" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -135,3 +135,41 @@ jobs: | |
find $HOME/.ivy2/cache -name "*-LM-SNAPSHOT*" -delete || true | ||
find $HOME/.cache/coursier/v1 -name "ivydata-*.properties" -delete || true | ||
find $HOME/.sbt -name "*.lock" -delete || true | ||
# `automerge` label is attached iff there is exactly one file changed by steward and this file belongs to a | ||
# whitelist specified by `labeler.yml` | ||
label: | ||
name: Attach automerge label | ||
# only for PRs by softwaremill-ci | ||
if: github.event.pull_request.user.login == 'softwaremill-ci' | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 2 | ||
# count number of files changed | ||
- name: Count number of files changed | ||
id: count-changed-files | ||
run: | | ||
N=$(git diff --name-only -r HEAD^1 HEAD | wc -w) | ||
echo "changed_files_num=$N" >> $GITHUB_OUTPUT | ||
- name: Launch labeler | ||
# skip if more than one file changed | ||
if: steps.count-changed-files.outputs.changed_files_num == 1 | ||
uses: srvaroa/labeler@master | ||
env: | ||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | ||
|
||
auto-merge: | ||
name: Auto merge | ||
# only for PRs by softwaremill-ci | ||
if: github.event.pull_request.user.login == 'softwaremill-ci' | ||
needs: [ ci, mima, label ] | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- id: automerge | ||
name: automerge | ||
uses: "pascalgn/[email protected]" | ||
env: | ||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | ||
MERGE_METHOD: "squash" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters