diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..4446cc9 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,25 @@ +# Description + +Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. + +Fixes # (issue) + +## Type of change + +Please tick options that are relevant. + +- [ ] Bug fix (non-breaking change which fixes an issue) +- [ ] New feature (non-breaking change which adds functionality) +- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) +- [ ] This change requires a documentation update + +# Checklist: + +- [ ] My code follows the style guidelines of this project +- [ ] I have performed a self-review of my own code +- [ ] I have commented my code, particularly in hard-to-understand areas +- [ ] I have made corresponding changes to the documentation +- [ ] My changes generate no new warnings +- [ ] I have added tests that prove my fix is effective or that my feature works +- [ ] New and existing unit tests pass locally with my changes +- [ ] Any dependent changes have been merged and published in downstream modules diff --git a/.github/release-drafter.yaml b/.github/release-drafter.yaml new file mode 100644 index 0000000..cd1f401 --- /dev/null +++ b/.github/release-drafter.yaml @@ -0,0 +1,31 @@ +name-template: 'v$RESOLVED_VERSION' +tag-template: '$RESOLVED_VERSION' +categories: + - title: '🚀 Features' + labels: + - 'feature' + - 'enhancement' + - title: '🐛 Bug Fixes' + labels: + - 'fix' + - 'bugfix' + - 'bug' + - title: '🧰 Maintenance' + label: 'dependencies' +change-template: '- $TITLE @$AUTHOR (#$NUMBER)' +change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks. +version-resolver: + major: + labels: + - 'major' + minor: + labels: + - 'minor' + patch: + labels: + - 'patch' + default: patch +template: | + ## Changes + + $CHANGES diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index e006fe6..e4eebd7 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -18,16 +18,6 @@ jobs: distribution: temurin java-version: 11 - - name: Set up Test Environment - run: | - pip install localstack awscli-local - docker pull localstack/localstack - - - name: Test - run: ./gradlew test - env: - OPENAI_TOKEN: ${{ secrets.OPENAI_TOKEN }} - - name: Publish run: ./gradlew build publish --no-parallel env: diff --git a/.github/workflows/release-drafter.yaml b/.github/workflows/release-drafter.yaml new file mode 100644 index 0000000..ae89b8a --- /dev/null +++ b/.github/workflows/release-drafter.yaml @@ -0,0 +1,20 @@ +name: Release Drafter + +on: + push: + branches: + - main + +permissions: + contents: read + +jobs: + update_release_draft: + permissions: + contents: write + pull-requests: write + runs-on: ubuntu-latest + steps: + - uses: release-drafter/release-drafter@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/build.gradle b/build.gradle index 3937bbe..a1dba1a 100644 --- a/build.gradle +++ b/build.gradle @@ -1,14 +1,16 @@ plugins { id 'scala' id 'jacoco' - id 'com.diffplug.spotless' version '6.20.0' id 'maven-publish' id 'signing' + id 'com.palantir.git-version' version '3.0.0' + id 'io.github.gradle-nexus.publish-plugin' version "1.3.0" id "com.avast.gradle.docker-compose" version "0.17.4" + id 'com.diffplug.spotless' version '6.20.0' } group = 'dev.joss' -version = '1.5.0' +version = gitVersion() sourceCompatibility = JavaVersion.VERSION_11 targetCompatibility = JavaVersion.VERSION_11 @@ -121,14 +123,15 @@ publishing { } } } +} + +nexusPublishing { repositories { - maven { - name = "OSSRH" - url = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/" - credentials { - username = project.findProperty("sonatypeUsername") - password = project.findProperty("sonatypePassword") - } + sonatype { + nexusUrl = uri("https://s01.oss.sonatype.org/service/local/") + snapshotRepositoryUrl = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/") + username = project.findProperty("sonatypeUsername") + password = project.findProperty("sonatypePassword") } } }