Skip to content

ci: fix ci configuration for coverage, scaladoc updated location #4

ci: fix ci configuration for coverage, scaladoc updated location

ci: fix ci configuration for coverage, scaladoc updated location #4

Workflow file for this run

name: Release
on:
push:
branches:
- main
paths-ignore:
- CHANGELOG.md
- README.md
- CONTRIBUTING.md
- renovate.json
- ".github/workflows/**"
- .releaserc.yml
- .scalafix.conf
- .scalafmt.conf
- "package*.json"
- codecov.yml
workflow_dispatch:
jobs:
test:
name: Test
uses: ./.github/workflows/test.yml
release:
name: Release on GitHub and Maven Central
runs-on: ubuntu-20.04
env:
TERM: dumb
needs:
- test
steps:
- name: Checkout
uses: actions/checkout@v3
with:
persist-credentials: false
- name: Setup scala environment
uses: olafurpg/setup-scala@v14
with:
java-version: openjdk@1.17
- name: Cache sbt
uses: actions/cache@v3
with:
path: |
~/.sbt
~/.coursier
key: ${{ runner.os }}-sbt-${{ hashfiles('**/build.sbt') }}
- name: Import GPG key for signing commits
id: import-gpg
uses: crazy-max/ghaction-import-gpg@v5
with:
gpg_private_key: ${{ secrets.BOT_GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.BOT_GPG_PASSPHRASE }}
git_config_global: true
git_user_signingkey: true
git_commit_gpgsign: true
- name: Install gnupg
run: sudo apt update && sudo apt install -y gnupg
- name: Decode PGP key
run: echo $PGP_SECRET | base64 --decode | gpg --batch --import
env:
PGP_SECRET: ${{ secrets.PGP_SECRET }}
- name: Install node
uses: actions/setup-node@v3
with:
node-version: "lts/*"
- name: Install dependencies
run: npm install
- name: Publish on GitHub and Maven Central
id: publish
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GIT_CREDENTIALS: ${{ secrets.GIT_CREDENTIALS }}
GIT_AUTHOR_NAME: ${{ steps.import-gpg.outputs.name }}
GIT_AUTHOR_EMAIL: ${{ steps.import-gpg.outputs.email }}
GIT_COMMITTER_NAME: ${{ steps.import-gpg.outputs.name }}
GIT_COMMITTER_EMAIL: ${{ steps.import-gpg.outputs.email }}
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
PGP_SECRET: ${{ secrets.PGP_SECRET }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
- name: Generate scaladoc
run: sbt doc
- name: Publish scaladoc on GitHub Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: target/api