Prepare for 3.2.2 release #149
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test and deploy | |
on: push | |
jobs: | |
test_and_deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Run tests | |
run: sbt 'set coverageEnabled := true' +test | |
- name: Aggregate coverage data | |
run: sbt coverageAggregate | |
- name: Check formatting | |
run: sbt scalafmtCheck | |
- name: Publish to Maven central | |
if: startsWith(github.ref, 'refs/tags/') | |
env: | |
PGP_PASSPHRASE: ${{ secrets.SONA_PGP_PASSPHRASE }} | |
PGP_SECRET: ${{ secrets.SONA_PGP_SECRET }} | |
SONATYPE_USERNAME: ${{ secrets.SONA_USER }} | |
SONATYPE_PASSWORD: ${{ secrets.SONA_PASS }} | |
run: sbt ci-release | |
- name: Generate API website | |
if: startsWith(github.ref, 'refs/tags/') | |
run: sbt makeSite | |
- name: Publish website | |
if: startsWith(github.ref, 'refs/tags/') | |
run: | | |
echo Publishing Scaladoc | |
git fetch | |
git checkout gh-pages | |
cp -r target/site/* . | |
git config user.name "GitHub Actions" | |
git config user.email "<>" | |
git add index.html $project_version | |
git commit -m "Added Scaladoc for $project_version" | |
git push origin gh-pages |