Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Format sbt files, add command alias for pre-PR linting #5498

Merged
merged 4 commits into from Oct 27, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Expand Up @@ -68,7 +68,7 @@ jobs:

- name: Check formatting
if: matrix.scala != '3.0.2'
run: sbt ++${{ matrix.scala }} scalafmtCheckAll
run: sbt ++${{ matrix.scala }} scalafmtCheckAll scalafmtSbtCheck

- name: Check headers
run: 'sbt ++${{ matrix.scala }} headerCheck test:headerCheck'
Expand Down
13 changes: 13 additions & 0 deletions .scalafix.conf
@@ -0,0 +1,13 @@
rules = [
RemoveUnused
]

RemoveUnused = {
imports = true

// These may indicate a bug rather than dead code, so shouldn't be automatically removed.
privates = false
locals = false
patternvars = false
params = false
}
259 changes: 157 additions & 102 deletions build.sbt

Large diffs are not rendered by default.

71 changes: 46 additions & 25 deletions project/CentralRequirements.scala
Expand Up @@ -14,29 +14,50 @@ object CentralRequirementsPlugin extends AutoPlugin {
sonatypeProfileName := "org.http4s",
developers ++= List(
// n.b. alphabetical by GitHub username
Developer("aeons" , "Bjørn Madsen" , "bm@aeons.dk" , url("https://github.com/aeons")),
Developer("before" , "André Rouel" , "" , url("https://github.com/before")),
Developer("bfritz" , "Brad Fritz" , "" , url("https://github.com/bfritz")),
Developer("bryce-anderson" , "Bryce L. Anderson" , "bryce.anderson22@gmail.com" , url("https://github.com/bryce-anderson")),
Developer("casualjim" , "Ivan Porto Carrero" , "ivan@flanders.co.nz" , url("https://github.com/casualjim")),
Developer("cencarnacion" , "Carlos Encarnacion" , "" , url("https://github.com/cencarnacion")),
Developer("ChristopherDavenport" , "Christopher Davenport" , "chris@christopherdavenport.tech" , url("https://github.com/ChristopherDavenport")),
Developer("cquiroz" , "Carlos Quiroz" , "" , url("https://github.com/cquiroz")),
Developer("hvesalai" , "Heikki Vesalainen" , "" , url("https://github.com/hvesalai")),
Developer("jcranky" , "Paulo Siqueira" , "" , url("https://github.com/jcranky")),
Developer("jedesah" , "Jean-Rémi Desjardins" , "" , url("https://github.com/jedesah")),
Developer("jmcardon" , "Jose Cardona" , "" , url("https://github.com/jmcardon")),
Developer("julien-truffaut" , "Julien Truffaut" , "" , url("https://github.com/julien-truffaut")),
Developer("kryptt" , "Rodolfo Hansen" , "" , url("https://github.com/kryptt")),
Developer("reactormonk" , "Simon Hafner" , "" , url("https://github.com/reactormonk")),
Developer("refried" , "Arya Irani" , "" , url("https://github.com/refried")),
Developer("rossabaker" , "Ross A. Baker" , "ross@rossabaker.com" , url("https://github.com/rossabaker")),
Developer("shengc" , "Sheng Chen" , "" , url("https://github.com/shengc")),
Developer("SystemFw" , "Fabio Labella" , "" , url("https://github.com/SystemFw")),
Developer("aeons", "Bjørn Madsen", "bm@aeons.dk", url("https://github.com/aeons")),
Developer("before", "André Rouel", "", url("https://github.com/before")),
Developer("bfritz", "Brad Fritz", "", url("https://github.com/bfritz")),
Developer(
"bryce-anderson",
"Bryce L. Anderson",
"bryce.anderson22@gmail.com",
url("https://github.com/bryce-anderson")),
Developer(
"casualjim",
"Ivan Porto Carrero",
"ivan@flanders.co.nz",
url("https://github.com/casualjim")),
Developer("cencarnacion", "Carlos Encarnacion", "", url("https://github.com/cencarnacion")),
Developer(
"ChristopherDavenport",
"Christopher Davenport",
"chris@christopherdavenport.tech",
url("https://github.com/ChristopherDavenport")),
Developer("cquiroz", "Carlos Quiroz", "", url("https://github.com/cquiroz")),
Developer("hvesalai", "Heikki Vesalainen", "", url("https://github.com/hvesalai")),
Developer("jcranky", "Paulo Siqueira", "", url("https://github.com/jcranky")),
Developer("jedesah", "Jean-Rémi Desjardins", "", url("https://github.com/jedesah")),
Developer("jmcardon", "Jose Cardona", "", url("https://github.com/jmcardon")),
Developer(
"julien-truffaut",
"Julien Truffaut",
"",
url("https://github.com/julien-truffaut")),
Developer("kryptt", "Rodolfo Hansen", "", url("https://github.com/kryptt")),
Developer("reactormonk", "Simon Hafner", "", url("https://github.com/reactormonk")),
Developer("refried", "Arya Irani", "", url("https://github.com/refried")),
Developer(
"rossabaker",
"Ross A. Baker",
"ross@rossabaker.com",
url("https://github.com/rossabaker")),
Developer("shengc", "Sheng Chen", "", url("https://github.com/shengc")),
Developer("SystemFw", "Fabio Labella", "", url("https://github.com/SystemFw"))
),
licenses := Seq("Apache-2.0" -> url("https://www.apache.org/licenses/LICENSE-2.0.html")),
homepage := Some(url("https://http4s.org/")),
scmInfo := Some(ScmInfo(url("https://github.com/http4s/http4s"), "git@github.com:http4s/http4s.git")),
scmInfo := Some(
ScmInfo(url("https://github.com/http4s/http4s"), "git@github.com:http4s/http4s.git")),
Compile / packageBin / publishArtifact := true,
Compile / packageSrc / publishArtifact := true,
Test / publishArtifact := false,
Expand All @@ -45,10 +66,10 @@ object CentralRequirementsPlugin extends AutoPlugin {
username <- sys.env.get("SONATYPE_USERNAME")
password <- sys.env.get("SONATYPE_PASSWORD")
} yield Credentials(
"Sonatype Nexus Repository Manager",
"oss.sonatype.org",
username, password
)
).toSeq
"Sonatype Nexus Repository Manager",
"oss.sonatype.org",
username,
password
)).toSeq
)
}