Skip to content

Commit 4f81e0d

Browse files
authored
Merge pull request #394 from softwaremill/mergify-removal
Removed mergify
2 parents 78af4b7 + 533e2e8 commit 4f81e0d

File tree

4 files changed

+55
-64
lines changed

4 files changed

+55
-64
lines changed

.github/labeler.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
version: 1
2+
labels:
3+
- label: "automerge"
4+
authors: ["softwaremill-ci"]
5+
files:
6+
- "build.sbt"
7+
- "project/plugins.sbt"
8+
- "project/build.properties"
9+
- label: "dependency"
10+
authors: ["softwaremill-ci"]
11+
files:
12+
- "build.sbt"
13+
- "project/plugins.sbt"
14+
- "project/build.properties"

.github/workflows/ci.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,3 +135,41 @@ jobs:
135135
find $HOME/.ivy2/cache -name "*-LM-SNAPSHOT*" -delete || true
136136
find $HOME/.cache/coursier/v1 -name "ivydata-*.properties" -delete || true
137137
find $HOME/.sbt -name "*.lock" -delete || true
138+
139+
# `automerge` label is attached iff there is exactly one file changed by steward and this file belongs to a
140+
# whitelist specified by `labeler.yml`
141+
label:
142+
name: Attach automerge label
143+
# only for PRs by softwaremill-ci
144+
if: github.event.pull_request.user.login == 'softwaremill-ci'
145+
runs-on: ubuntu-22.04
146+
steps:
147+
- uses: actions/checkout@v4
148+
with:
149+
fetch-depth: 2
150+
# count number of files changed
151+
- name: Count number of files changed
152+
id: count-changed-files
153+
run: |
154+
N=$(git diff --name-only -r HEAD^1 HEAD | wc -w)
155+
echo "changed_files_num=$N" >> $GITHUB_OUTPUT
156+
- name: Launch labeler
157+
# skip if more than one file changed
158+
if: steps.count-changed-files.outputs.changed_files_num == 1
159+
uses: srvaroa/labeler@master
160+
env:
161+
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
162+
163+
auto-merge:
164+
name: Auto merge
165+
# only for PRs by softwaremill-ci
166+
if: github.event.pull_request.user.login == 'softwaremill-ci'
167+
needs: [ ci, mima, label ]
168+
runs-on: ubuntu-22.04
169+
steps:
170+
- id: automerge
171+
name: automerge
172+
uses: "pascalgn/[email protected]"
173+
env:
174+
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
175+
MERGE_METHOD: "squash"

.mergify.yml

Lines changed: 0 additions & 54 deletions
This file was deleted.

build.sbt

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,7 @@ val sttpModelVersion = "1.7.10"
1515
val scalaTestVersion = "3.2.18"
1616
val zio1Version = "1.0.18"
1717
val zio2Version = "2.0.22"
18-
val fs2_2_version: Option[(Long, Long)] => String = {
19-
case Some((2, 11)) => "2.1.0"
20-
case _ => "2.5.9"
21-
}
18+
val fs2_2_version = "2.5.9"
2219
val fs2_3_version = "3.10.0"
2320
val armeriaVersion = "1.28.4"
2421

@@ -170,16 +167,12 @@ lazy val armeria = (projectMatrix in file("armeria"))
170167
lazy val fs2ce2 = (projectMatrix in file("fs2-ce2"))
171168
.settings(
172169
name := "fs2-ce2",
173-
libraryDependencies ++= dependenciesFor(scalaVersion.value)(
174-
"co.fs2" %%% "fs2-core" % fs2_2_version(_)
175-
)
170+
libraryDependencies += "co.fs2" %%% "fs2-core" % fs2_2_version
176171
)
177172
.jvmPlatform(
178173
scalaVersions = scala2 ++ scala3,
179174
settings = commonJvmSettings ++ Seq(
180-
libraryDependencies ++= dependenciesFor(scalaVersion.value)(
181-
"co.fs2" %% "fs2-io" % fs2_2_version(_)
182-
)
175+
libraryDependencies +="co.fs2" %% "fs2-io" % fs2_2_version
183176
)
184177
)
185178
.jsPlatform(

0 commit comments

Comments
 (0)