diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml new file mode 100644 index 000000000..6e588da07 --- /dev/null +++ b/.github/workflows/build-test.yml @@ -0,0 +1,49 @@ +name: Check + +on: + pull_request: + + push: + branches: + - main # Check branch after merge + +concurrency: + # Only run once for latest commit per ref and cancel other (previous) runs. + group: ci-${{ github.ref }} + cancel-in-progress: true + +jobs: + check-code-style: + name: Code Style + uses: playframework/.github/.github/workflows/cmd.yml@v2 + with: + cmd: sbt validateCode + + check-binary-compatibility: + name: Binary Compatibility + uses: playframework/.github/.github/workflows/binary-check.yml@v2 + + check-docs: + name: Docs + uses: playframework/.github/.github/workflows/cmd.yml@v2 + with: + cmd: sbt docs/validateDocs + + tests: + name: Tests + needs: + - "check-code-style" + - "check-binary-compatibility" + - "check-docs" + uses: playframework/.github/.github/workflows/cmd.yml@v2 + with: + java: 11, 8 + scala: 2.12.16, 2.13.8 + cmd: scripts/test-code.sh + + finish: + name: Finish + if: github.event_name == 'pull_request' + needs: # Should be last + - "tests" + uses: playframework/.github/.github/workflows/rtm.yml@v2 diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 000000000..9e999302c --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,15 @@ +name: Publish + +on: + push: + branches: # Snapshots + - main + tags: ["**"] # Releases + release: + types: [published] + +jobs: + publish-artifacts: + name: Publish / Artifacts + uses: playframework/.github/.github/workflows/publish.yml@v2 + secrets: inherit diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml index 33803af51..02ce9fb77 100644 --- a/.github/workflows/release-drafter.yml +++ b/.github/workflows/release-drafter.yml @@ -3,7 +3,7 @@ name: Release Drafter on: push: branches: - - 2.9.x + - main jobs: update_release_draft: @@ -12,7 +12,7 @@ jobs: - uses: release-drafter/release-drafter@v5 with: name: "Play JSON $RESOLVED_VERSION" - config-name: release-drafts/increasing-patch-version.yml # located in .github/ in the default branch within this or the .github repo + config-name: release-drafts/increasing-minor-version.yml # located in .github/ in the default branch within this or the .github repo commitish: ${{ github.ref_name }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index df3583bd9..000000000 --- a/.travis.yml +++ /dev/null @@ -1,78 +0,0 @@ -version: ~> 1.0 - -language: scala - -git: - depth: false # Avoid sbt-dynver not seeing the tag - -before_install: curl -Ls https://raw.githubusercontent.com/shyiko/jabba/0.11.2/install.sh | bash && . ~/.jabba/jabba.sh -install: jabba install "adopt@~1.$TRAVIS_JDK.0-0" && jabba use "$_" && java -Xmx32m -version - -jobs: - include: - - stage: check - name: "Code style check. Run locally with: sbt validateCode mimaReportBinaryIssues docs/validateDocs" - script: sbt validateCode mimaReportBinaryIssues docs/validateDocs - env: - - TRAVIS_JDK=11 - - - stage: test - name: "Run tests with Scala 2.12 and AdoptOpenJDK 11" - script: scripts/test-code.sh - env: - - SCALA_VERSION=2.12.12 - - TRAVIS_JDK=11 - - - name: "Run tests with Scala 2.13 and AdoptOpenJDK 11" - script: scripts/test-code.sh - env: - - SCALA_VERSION=2.13.2 - - TRAVIS_JDK=11 - - - name: "Run tests with Scala 2.12 and AdoptOpenJDK 8" - script: scripts/test-code.sh - env: - - SCALA_VERSION=2.12.12 - - TRAVIS_JDK=8 - - - name: "Run tests with Scala 2.13 and AdoptOpenJDK 8" - script: scripts/test-code.sh - env: - - SCALA_VERSION=2.13.2 - - TRAVIS_JDK=8 - - - stage: publish - name: "Publish artifacts to Bintray" - script: sbt +publish - env: - - TRAVIS_JDK=11 - -stages: - - name: check - - name: test - - name: publish - if: ((branch = main AND type = push) OR (tag IS present)) AND NOT fork - -cache: - directories: - - "$HOME/.cache/coursier" - - "$HOME/.ivy2/cache" - - "$HOME/.sbt" - - "$HOME/.jabba/jdk" - -before_cache: - - rm -rf $HOME/.ivy2/cache/com.typesafe.play/* - - rm -rf $HOME/.ivy2/cache/scala_*/sbt_*/com.typesafe.play/* - - find $HOME/.ivy2 -name "ivydata-*.properties" -delete - - find $HOME/.sbt -name "*.lock" -delete - -env: - global: - # encrypt with: travis encrypt --pro BINTRAY_USER=... - - secure: "xXojt9mS2T6XH/Ef7Ek8taVwWOEpAMxrAr7JZAVV1O7HkXr46b/kzaXOOyUh11j7kStYz0ZMGlWWfH7YJbSVw9OaInj2jUQCSKGSNCqIftKd1CRqjUvlzknIoI+22FrJQcD4WUGwyYKvuLsmGCeUK/KrjmPIkf3bqQJWqrKtow4XzohadE7yf38ClrWWvh09qjjgcJ+rSb6h2qCt4/TAb705D3yq6PA8lSMzBr+CtGxuXRb5e/UZMVLq44RPQPHHhUGEsrsKAWlwSf3CGzJ+l7RWMQkyrWqGy5hqHxRX/wvnf5pa9xfVNONMBdLM0avIsnauH6Q6Ls9TZi8Xd8pHvJsnmY9DVTeOuZcXwS5aCcw8mH2cOe2gGeGCr4sdqIDZI/uAyb2cmfNZ4P/x7DCazlhM0nG95CbEMs/XFkDWNs3S60Ukzry3GvVD3ZbHY5KgsLiHfJnA2eMKqiX9Q5N5uSzpFpL1+8nQACBkLMMva8Z5Cl6tStAhWk3k9DEUxjv1d1+13+URco1Gj8PGwUPLTJbz+ir4uFpRqzG2MkhAywLFvbShPWXEh1OwSvnxUypPi+uvmEcGIjYRDGIsZ5oztm0sV6rXhkwPr+L4lENEMmzwjUSoSU7jilXitCoAEm5YMDgIp0KoSeINqlmB9MB+qECj8i6gloTKJbUhqoqdxsE=" - # encrypt with: travis encrypt --pro BINTRAY_PASS=... - - secure: "OpfKFOBs/Iekq0DicTyviqyL8CXfCBnfEsxo8ijImKafZVEro2bI8TcpVAIKfMWGm5ER7bVbMCGMhLTE457BGj4j3kKK7W/XDRSlmV61nTSMUzjVT/4KuqhEjUSXwQ2gXinmGj9ydDE97SrD5Lao6KBKGe9jzC7ouWmr3dOsHfb0Sc0o+9BHdaC+rVWhxmdI2zCoE36ml+GF+wqPQWrD0VPlPj+UiMkfd5Ot4o3jEJJtapdZ2zY3OIwkxc1/tcw/bnuedr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5Onj4VgWjfaKsx3FpnLt3kBXFL2UUF/+scumV31USgTKSEnA= diff --git a/build.sbt b/build.sbt index 474da9f51..1dd2c392d 100644 --- a/build.sbt +++ b/build.sbt @@ -17,12 +17,12 @@ val specs2 = Seq( "org.specs2" %% "specs2-junit" % "4.10.5" % Test, ) -val jacksonDatabindVersion = "2.10.5.1" +val jacksonDatabindVersion = "2.11.4" val jacksonDatabind = Seq( "com.fasterxml.jackson.core" % "jackson-databind" % jacksonDatabindVersion ) -val jacksonVersion = "2.10.5" +val jacksonVersion = "2.11.4" val jacksons = Seq( "com.fasterxml.jackson.core" % "jackson-core", "com.fasterxml.jackson.core" % "jackson-annotations",