From ae75a4f6a8425671bba0d279ed7f8a3ea5b38e41 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Tue, 14 Jan 2025 18:30:44 +0000 Subject: [PATCH 1/3] Update scalafmt-core to 3.8.4 --- .scalafmt.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.scalafmt.conf b/.scalafmt.conf index 8f5b0f6..5c80229 100644 --- a/.scalafmt.conf +++ b/.scalafmt.conf @@ -1,4 +1,4 @@ -version = 3.8.3 +version = 3.8.4 runner.dialect = scala213source3 project.git = true maxColumn = 120 From dab03f7425954a2a7dca1fc14cf1939c9f58a5fb Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Tue, 14 Jan 2025 18:30:55 +0000 Subject: [PATCH 2/3] Reformat with scalafmt 3.8.4 Executed command: scalafmt --non-interactive --- mill-git/test/resources/custom/build.mill | 66 +++++++------------ .../git/DockerProjectIntegrationTests.scala | 30 ++++----- 2 files changed, 37 insertions(+), 59 deletions(-) diff --git a/mill-git/test/resources/custom/build.mill b/mill-git/test/resources/custom/build.mill index c07a8c0..6be0148 100644 --- a/mill-git/test/resources/custom/build.mill +++ b/mill-git/test/resources/custom/build.mill @@ -9,47 +9,25 @@ object project extends JavaModule { } /** Usage - -> git init -... - -// Uncommitted changes -> ./mill show project.jobVersion -"..." - -// Commit without tag -> git add --all -> git commit -m "Some commit" - -> ./mill show project.jobVersion -"..." - -// Uncommitted changes after commit without tag -> echo "Some change!" > some-file -> ./mill show project.jobVersion -"..." - -// Head tagged -> git add --all -> git commit -m "Some commit 2" -> git tag -a v1.0.0 -m "v1.0.0" -> ./mill show project.jobVersion -"1.0.0" - -// Uncommitted changes after tag -> echo "Some change 2!" > some-file -> ./mill show project.jobVersion -"1.0.0-..." - -// Commit after tag -> git add --all -> git commit -m "Some commit 3" -> ./mill show project.jobVersion -"1.0.0-1-..." - -// Uncommitted changes after tag and after commit -> echo "Some change 3!" > some-file -> ./mill show project.jobVersion -"1.0.0-2-..." - -*/ + * + * > git init ... + * + * // Uncommitted changes > ./mill show project.jobVersion "..." + * + * // Commit without tag > git add --all > git commit -m "Some commit" + * + * > ./mill show project.jobVersion "..." + * + * // Uncommitted changes after commit without tag > echo "Some change!" > some-file > ./mill show project.jobVersion + * "..." + * + * // Head tagged > git add --all > git commit -m "Some commit 2" > git tag -a v1.0.0 -m "v1.0.0" > ./mill show + * project.jobVersion "1.0.0" + * + * // Uncommitted changes after tag > echo "Some change 2!" > some-file > ./mill show project.jobVersion "1.0.0-..." + * + * // Commit after tag > git add --all > git commit -m "Some commit 3" > ./mill show project.jobVersion "1.0.0-1-..." + * + * // Uncommitted changes after tag and after commit > echo "Some change 3!" > some-file > ./mill show + * project.jobVersion "1.0.0-2-..." + */ diff --git a/mill-git/test/src/com/goyeau/mill/git/DockerProjectIntegrationTests.scala b/mill-git/test/src/com/goyeau/mill/git/DockerProjectIntegrationTests.scala index bb375d2..590026e 100644 --- a/mill-git/test/src/com/goyeau/mill/git/DockerProjectIntegrationTests.scala +++ b/mill-git/test/src/com/goyeau/mill/git/DockerProjectIntegrationTests.scala @@ -11,9 +11,9 @@ class DockerProjectIntegrationTests extends FunSuite { assert(result.isSuccess, result.err) assert( result.out.matches("""\[ - | "project:[\da-f]{7}", - | "project:latest" - |\]""".stripMargin), + | "project:[\da-f]{7}", + | "project:latest" + |\]""".stripMargin), s"${result.out} is not an array with 7 chars hash and latest tags" ) } @@ -47,9 +47,9 @@ class DockerProjectIntegrationTests extends FunSuite { assert(result.isSuccess, result.err) assert( result.out.matches("""\[ - | "project:[\da-f]{7}", - | "project:latest" - |\]""".stripMargin), + | "project:[\da-f]{7}", + | "project:latest" + |\]""".stripMargin), s"${result.out} is not a 7 chars hash" ) } @@ -84,9 +84,9 @@ class DockerProjectIntegrationTests extends FunSuite { assert(result.isSuccess, result.err) assert( result.out.matches("""\[ - | "project:1\.0\.0-1-[\da-f]{7}", - | "project:latest" - |\]""".stripMargin), + | "project:1\.0\.0-1-[\da-f]{7}", + | "project:latest" + |\]""".stripMargin), s"${result.out} is not a version and distance from it, followed by a 7 chars hash" ) } @@ -107,9 +107,9 @@ class DockerProjectIntegrationTests extends FunSuite { assertEquals( result.out, s"""[ - | "project:1.0.0-1-$hash", - | "project:latest" - |]""".stripMargin + | "project:1.0.0-1-$hash", + | "project:latest" + |]""".stripMargin ) } @@ -128,9 +128,9 @@ class DockerProjectIntegrationTests extends FunSuite { assert(result.isSuccess, result.err) assert( result.out.matches("""\[ - | "project:1\.0\.0-2-[\da-f]{7}", - | "project:latest" - |\]""".stripMargin), + | "project:1\.0\.0-2-[\da-f]{7}", + | "project:latest" + |\]""".stripMargin), s"${result.out} is not a version and distance from it, followed by a 7 chars hash" ) } From fc8477510b4987ebe3a89389e281cb5be502e459 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Tue, 14 Jan 2025 18:30:55 +0000 Subject: [PATCH 3/3] Add 'Reformat with scalafmt 3.8.4' to .git-blame-ignore-revs --- .git-blame-ignore-revs | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .git-blame-ignore-revs diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs new file mode 100644 index 0000000..10ebf5a --- /dev/null +++ b/.git-blame-ignore-revs @@ -0,0 +1,2 @@ +# Scala Steward: Reformat with scalafmt 3.8.4 +dab03f7425954a2a7dca1fc14cf1939c9f58a5fb