diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..c856e2b --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,23 @@ +name: CI + +on: + push: + branches: + - main + pull_request: + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-java@v4 + with: + distribution: 'zulu' + java-version: '21' + cache: 'sbt' + + - name: 📦 Run Gitter to apply template + run: sbt g8 diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index b145ec6..0000000 --- a/.travis.yml +++ /dev/null @@ -1,24 +0,0 @@ -language: scala - -scala: - - 2.13.7 - -jdk: - - oraclejdk8 - -dist: trusty - -# These directories are cached to S3 at the end of the build -cache: - directories: - - $HOME/.ivy2/cache - - $HOME/.sbt/boot/ - -before_cache: - # Cleanup the cached directories to avoid unnecessary cache updates - - find $HOME/.ivy2/cache -name "ivydata-*.properties" -print -delete - - find $HOME/.sbt -name "*.lock" -print -delete - -script: - ## This generates a new project inside `target/sbt-test/` applying the assuming the `src/main/g8/default.properties`. - - sbt -Dfile.encoding=UTF8 -J-XX:ReservedCodeCacheSize=256M g8 diff --git a/LICENSE b/LICENSE index 33c018b..c9ed838 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ -MIT License +The MIT License -Copyright (c) 2018 CodelyTV staff@codely.tv +Copyright (c) 2024 Codely Enseña y Entretiene SL. https://codely.com Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -9,13 +9,13 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/build.sbt b/build.sbt index fda9a3f..0d87a43 100644 --- a/build.sbt +++ b/build.sbt @@ -1,9 +1,9 @@ lazy val root = (project in file(".")) .settings( - scalaVersion := "2.13.7", + scalaVersion := "2.13.13", organization := "tv.codely", - name := "CodelyTV Scala Bootstrap", - version := "1.2.3", + name := "Codely Scala Bootstrap", + version := "1.3.0", test in Test := { val _ = (g8Test in Test).toTask("").value }, diff --git a/project/build.properties b/project/build.properties index 133a8f1..04267b1 100644 --- a/project/build.properties +++ b/project/build.properties @@ -1 +1 @@ -sbt.version=0.13.17 +sbt.version=1.9.9 diff --git a/project/giter8.sbt b/project/giter8.sbt index ead8741..b9c4fe6 100644 --- a/project/giter8.sbt +++ b/project/giter8.sbt @@ -1 +1 @@ -addSbtPlugin("org.foundweekends.giter8" %% "sbt-giter8" % "0.11.0") +addSbtPlugin("org.foundweekends.giter8" %% "sbt-giter8" % "0.16.2") diff --git a/src/main/g8/.travis.yml b/src/main/g8/.travis.yml deleted file mode 100644 index 3b98768..0000000 --- a/src/main/g8/.travis.yml +++ /dev/null @@ -1,22 +0,0 @@ -language: scala - -scala: - - 2.13.1 - -jdk: - - oraclejdk8 - -# These directories are cached to S3 at the end of the build -cache: - directories: - - \$HOME/.ivy2/cache - - \$HOME/.sbt/boot - -before_cache: - # Cleanup the cached directories to avoid unnecessary cache updates - - find \$HOME/.ivy2/cache -name "ivydata-*.properties" -print -delete - - find \$HOME/.sbt -name "*.lock" -print -delete - -script: - - sbt prep # See `build.sbt` to check out which tasks this alias performs (compile, compile test, style check...) - - sbt test diff --git a/src/main/g8/LICENSE b/src/main/g8/LICENSE index 80444ae..a5019e8 100644 --- a/src/main/g8/LICENSE +++ b/src/main/g8/LICENSE @@ -1,6 +1,6 @@ -MIT License +The MIT License -Copyright (c) 2018 $organization$ support@$organization$ +Copyright (c) 2024 $organization$ https://$organization$ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -9,13 +9,13 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/src/main/g8/build.sbt b/src/main/g8/build.sbt index 1f4b7e6..426056c 100644 --- a/src/main/g8/build.sbt +++ b/src/main/g8/build.sbt @@ -7,14 +7,14 @@ Configuration.settings /** ********* PROD DEPENDENCIES *****************/ libraryDependencies ++= Seq( - "com.github.nscala-time" %% "nscala-time" % "2.22.0", - "com.lihaoyi" %% "pprint" % "0.5.6" + "com.github.nscala-time" %% "nscala-time" % "2.32.0", + "com.lihaoyi" %% "pprint" % "0.9.0" ) /** ********* TEST DEPENDENCIES *****************/ libraryDependencies ++= Seq( - "org.scalatest" %% "scalatest" % "3.1.1" % Test, - "org.scalamock" %% "scalamock" % "4.4.0" % Test + "org.scalatest" %% "scalatest" % "3.2.18" % Test, + "org.scalamock" %% "scalamock" % "5.1.0" % Test ) /** ********* COMMANDS ALIASES ******************/ diff --git a/src/main/g8/default.properties b/src/main/g8/default.properties index 63b4892..10df72b 100644 --- a/src/main/g8/default.properties +++ b/src/main/g8/default.properties @@ -1,8 +1,8 @@ -sbt_version = 1.5.5 -scala_version = 2.13.7 -name = Scala bootstrap +sbt_version = 1.9.9 +scala_version = 2.13.13 +name = Scala skeleton version = 1.0 -description = Template following Scala best practices in order to bootstrap your environment and be ready for your next kata or project! -organization = tv.codely +description = Template following Scala best practices to bootstrap your environment and be ready for your next kata or project! +organization = com.codely package = $organization$.$name;format="lower,snake"$ verbatim = install-hooks.sh pre-push