Skip to content
Closed
80 changes: 80 additions & 0 deletions .mergify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
# This file was automatically generated by sbt-typelevel-mergify using the
# mergifyGenerate task. You should add and commit this file to
# your git repository. It goes without saying that you shouldn't edit
# this file by hand! Instead, if you wish to make changes, you should
# change your sbt build configuration to revise the mergify configuration
# to meet your needs, then regenerate this file.

pull_request_rules:
- name: merge scala-steward's PRs
conditions:
- author=scala-steward
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I forgot that we need some additional configuration to override this PR author setting. Could you please add these sbt settings to this project's build.sbt. Once this is done, you can confirm that the generated YAML config looks similar to this.

- body~=labels:.*early-semver-patch
- status-success=Test (ubuntu-22.04, 2.12, temurin@8)
- status-success=Test (ubuntu-22.04, 2.13, temurin@8)
actions:
merge: {}
- name: Label benchmark PRs
conditions:
- files~=^benchmark/
actions:
label:
add:
- benchmark
remove: []
- name: Label effect3 PRs
conditions:
- files~=^effect3/
actions:
label:
add:
- effect3
remove: []
- name: Label finagle PRs
conditions:
- files~=^finagle/
actions:
label:
add:
- finagle
remove: []
- name: Label input PRs
conditions:
- files~=^scalafix/input/
actions:
label:
add:
- input
remove: []
- name: Label output PRs
conditions:
- files~=^scalafix/output/
actions:
label:
add:
- output
remove: []
- name: Label rules PRs
conditions:
- files~=^scalafix/rules/
actions:
label:
add:
- rules
remove: []
- name: Label tests PRs
conditions:
- files~=^scalafix/tests/
actions:
label:
add:
- tests
remove: []
- name: Label util PRs
conditions:
- files~=^util/
actions:
label:
add:
- util
remove: []
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ lazy val allSettings = baseSettings

lazy val root = project
.in(file("."))
.enablePlugins(GhpagesPlugin, ScalaUnidocPlugin, NoPublishPlugin)
.enablePlugins(GhpagesPlugin, ScalaUnidocPlugin, NoPublishPlugin, MergifyPlugin)
.settings(allSettings)
.settings(
ScalaUnidoc / unidoc / unidocProjectFilter := inAnyProject -- inProjects(
Expand Down
2 changes: 1 addition & 1 deletion project/build.properties
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this downgrades the sbt version; is that necessary?

Original file line number Diff line number Diff line change
@@ -1 +1 @@
sbt.version=1.10.10
sbt.version=1.9.8
2 changes: 2 additions & 0 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ addSbtPlugin("org.scalastyle" %% "scalastyle-sbt-plugin" % "1.0.0")
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "2.3.1")
addSbtPlugin("pl.project13.scala" % "sbt-jmh" % "0.4.3")
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.14.2")
addSbtPlugin("org.typelevel" % "sbt-typelevel-mergify" % "0.7.7")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a nitpick, but if you need to modify this file anyway to remove sbt-scala-native, could you please move this line up so it's immediately under the sbt-typelevel reference above? In other words, make this line the new line 3. That will keep the sbt-typelevel* dependencies together, which hopefully will be easier to read and help reduce future merge conflicts.

addSbtPlugin("org.scala-native" % "sbt-scala-native" % "0.4.16")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm surprised to see sbt-scala-native added in this PR. Is it necessary?


ThisBuild / libraryDependencySchemes ++= Seq(
"org.scala-lang.modules" %% "scala-xml" % VersionScheme.Always
Expand Down
Loading