Skip to content

Commit

Permalink
Prepare release (#41)
Browse files Browse the repository at this point in the history
  • Loading branch information
ennru authored Jan 31, 2024
1 parent 15d639c commit 6566542
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 59 deletions.
60 changes: 20 additions & 40 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,51 +23,41 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.12.17]
scala: [2.12.18]
java: [temurin@11, temurin@17]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Java (temurin@11)
if: matrix.java == 'temurin@11'
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 11
cache: sbt

- name: Setup Java (temurin@17)
if: matrix.java == 'temurin@17'
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17

- name: Cache sbt
uses: actions/cache@v2
with:
path: |
~/.sbt
~/.ivy2/cache
~/.coursier/cache/v1
~/.cache/coursier/v1
~/AppData/Local/Coursier/Cache/v1
~/Library/Caches/Coursier/v1
key: ${{ runner.os }}-sbt-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }}
cache: sbt

- name: Check that workflows are up to date
run: sbt ++${{ matrix.scala }} githubWorkflowCheck
run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck

- run: sbt ++${{ matrix.scala }} test scripted
- run: sbt '++ ${{ matrix.scala }}' test scripted

- name: Compress target directories
run: tar cf targets.tar target project/target

- name: Upload target directories
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: target-${{ matrix.os }}-${{ matrix.scala }}-${{ matrix.java }}
path: targets.tar
Expand All @@ -79,47 +69,37 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.12.17]
scala: [2.12.18]
java: [temurin@11]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Java (temurin@11)
if: matrix.java == 'temurin@11'
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 11
cache: sbt

- name: Setup Java (temurin@17)
if: matrix.java == 'temurin@17'
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
cache: sbt

- name: Cache sbt
uses: actions/cache@v2
with:
path: |
~/.sbt
~/.ivy2/cache
~/.coursier/cache/v1
~/.cache/coursier/v1
~/AppData/Local/Coursier/Cache/v1
~/Library/Caches/Coursier/v1
key: ${{ runner.os }}-sbt-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }}

- name: Download target directories (2.12.17)
uses: actions/download-artifact@v2
- name: Download target directories (2.12.18)
uses: actions/download-artifact@v4
with:
name: target-${{ matrix.os }}-2.12.17-${{ matrix.java }}
name: target-${{ matrix.os }}-2.12.18-${{ matrix.java }}

- name: Inflate target directories (2.12.17)
- name: Inflate target directories (2.12.18)
run: |
tar xf targets.tar
rm targets.tar
Expand All @@ -129,4 +109,4 @@ jobs:
PGP_SECRET: ${{ secrets.PGP_SECRET }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
run: sbt ++${{ matrix.scala }} ci-release
run: sbt ci-release
3 changes: 2 additions & 1 deletion .github/workflows/clean.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Delete artifacts
shell: bash {0}
run: |
# Customize those three lines with your repository and credentials:
REPO=${GITHUB_API_URL}/repos/${{ github.repository }}
Expand All @@ -25,7 +26,7 @@ jobs:
ghapi() { curl --silent --location --user _:$GITHUB_TOKEN "$@"; }
# A temporary file which receives HTTP response headers.
TMPFILE=/tmp/tmp.$$
TMPFILE=$(mktemp)
# An associative array, key: artifact name, value: number of artifacts of that name.
declare -A ARTCOUNT
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,5 +165,5 @@ Feel free to ping contributors for code review or discussions. Pull requests are

[maven-central]: https://maven-badges.herokuapp.com/maven-central/com.lightbend.paradox/sbt-paradox-project-info
[maven-central-badge]: https://maven-badges.herokuapp.com/maven-central/com.lightbend.paradox/sbt-paradox-project-info/badge.svg
[github-actions]: https://github.com/lightbend/sbt-paradox-project-info/actions/workflows/ci.yml?query=branch%3Amaster
[github-actions-badge]: https://github.com/lightbend/sbt-paradox-project-info/actions/workflows/ci.yml/badge.svg?branch=master
[github-actions]: https://github.com/lightbend/sbt-paradox-project-info/actions/workflows/ci.yml?query=branch%3Amain
[github-actions-badge]: https://github.com/lightbend/sbt-paradox-project-info/actions/workflows/ci.yml/badge.svg?branch=main
11 changes: 3 additions & 8 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
# Releasing

1. Check [closed issues without a milestone](https://github.com/lightbend/sbt-paradox-project-info/issues?utf8=%E2%9C%93&q=is%3Aissue%20is%3Aclosed%20no%3Amilestone) and either assign them the upcoming release milestone or 'invalid'
1. Create a [new release](https://github.com/lightbend/sbt-paradox-project-info/releases/new) with:
* the next tag version (e.g. `v0.2`)
* title and release description including notable changes
* link to the [milestone](https://github.com/lightbend/sbt-paradox-project-info/milestones) showing an overview of closed issues for this release
* overview of contributors generated by [`sbt-authors`](https://github.com/2m/authors) (eg. `sbt authors v0.1 v0.2`)
1. Travis CI will start a [CI build](https://travis-ci.org/lightbend/sbt-paradox-project-info/builds) for the new tag and publish artifacts to Bintray.
1. Close the milestone for this release and start a new one.
* Draft a [new release on GitHub](https://github.com/lightbend/sbt-paradox-project-info/releases)
* Tag it (with a `v` prefix)
* Github actions should automatically release to maven-central
6 changes: 2 additions & 4 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ThisBuild / scalaVersion := "2.12.17"
ThisBuild / scalaVersion := "2.12.18"

sbtPlugin := true

Expand Down Expand Up @@ -54,9 +54,7 @@ ThisBuild / githubWorkflowPublish := Seq(
)
)

ThisBuild / test / publishArtifact := false
ThisBuild / pomIncludeRepository := (_ => false)
sonatypeProfileName := "com.lightbend"
sonatypeProfileName := "com.lightbend"

ThisBuild / githubWorkflowJavaVersions := List(
JavaSpec.temurin("11"),
Expand Down
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sbt.version=1.6.2
sbt.version=1.9.8
6 changes: 3 additions & 3 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
addSbtPlugin("de.heikoseeberger" % "sbt-header" % "5.6.5")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.4.6")
addSbtPlugin("com.codecommit" % "sbt-github-actions" % "0.14.2")
addSbtPlugin("de.heikoseeberger" % "sbt-header" % "5.10.0")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2")
addSbtPlugin("com.github.sbt" % "sbt-github-actions" % "0.22.0")
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.12")

0 comments on commit 6566542

Please sign in to comment.