Skip to content

Commit

Permalink
Merge branch 'release/1.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
zambrovski committed Apr 16, 2021
2 parents 915744d + 4fba0cb commit 632a2c8
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 56 deletions.
44 changes: 23 additions & 21 deletions .github/workflows/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,33 @@ on:
- '*'
- '**/*'
- '!master'
- '!release/*'

jobs:
build:

runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11

- name: Cache .m2
uses: actions/cache@v1
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven
- name: Prepare mvnw
run: chmod +x ./mvnw

- name: Build
run: ./mvnw clean package
- name: Checkout code
uses: actions/checkout@v1

- name: Cache .m2
uses: actions/cache@v1
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven
# Setup JDK and Maven
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11.0.5

- name: Prepare Maven Wrapper
run: chmod +x ./mvnw

- name: Build with Maven
run: ./mvnw clean verify -U -B -T4
49 changes: 25 additions & 24 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,51 @@
name: Master branch
name: Master or release candidate branch

on:
push:
branches:
- master
- 'release/*'
jobs:
build:

runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
uses: actions/checkout@v1

- name: Cache .m2
uses: actions/cache@v1
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Prepare mvnw
run: chmod +x ./mvnw

- name: Build
run: ./mvnw clean package
${{ runner.os }}-maven
# Get GPG private key into GPG
- name: Import GPG Owner Trust
run: echo ${{secrets.GPG_OWNER_TRUST}} | base64 --decode | gpg --import-ownertrust

run: echo ${{ secrets.GPG_OWNERTRUST }} | base64 --decode | gpg --import-ownertrust
- name: Import GPG key
run: echo ${{secrets.GPG_SECRET_KEYS}} | base64 --decode | gpg --import --no-tty --batch --yes --always-trust

- name: Clean settings.xml
run: rm -rf ~/.m2/settings.xml
run: echo ${{ secrets.GPG_SECRET_KEYS }} | base64 --decode | gpg --import --no-tty --batch --yes

- name: Create settings.xml
uses: s4u/maven-settings-action@v1
# Setup JDK and Maven
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
servers: '[{"id": "ossrh", "username": "${{secrets.SONATYPE_USERNAME}}", "password": "${{secrets.SONATYPE_PASSWORD}}"}]'
java-version: 11.0.5
server-id: ossrh
server-username: OSS_CENTRAL_USERNAME # env variable for Maven Central
server-password: OSS_CENTRAL_PASSWORD # env variable for Maven Central

- name: Prepare Maven Wrapper
run: chmod +x ./mvnw

- name: Build with Maven
run: ./mvnw clean verify -U -B -T4

- name: Deploy a new version to central
run: ./mvnw clean deploy -B -DskipTests -DskipExamples -Prelease -Dgpg.keyname=${{secrets.GPG_KEYNAME}} -Dgpg.passphrase=${{secrets.GPG_PASSPHRASE}}
run: ./mvnw clean deploy -B -DskipTests -DskipExamples -Prelease -Dgpg.keyname=${{secrets.GPG_KEYNAME}} -Dgpg.passphrase="${{secrets.GPG_PASSPHRASE}}"
env:
OSS_CENTRAL_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
OSS_CENTRAL_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}

21 changes: 17 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,22 @@

Extensions that make working with the JVM BDD testing tool [jgiven](https://jgiven.org) and Kotlin even more fun.

[![Build Status](https://github.com/toolisticon/jgiven-kotlin/workflows/default/badge.svg)](https://github.com/toolisticon/jgiven-kotlin/actions)

[![Build Status](https://github.com/toolisticon/jgiven-kotlin/workflows/Development%20branches/badge.svg)](https://github.com/toolisticon/jgiven-kotlin/actions)
[![sponsored](https://img.shields.io/badge/sponsoredBy-Holisticon-RED.svg)](https://holisticon.de/)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/io.toolisticon.testing/jgiven-kotlin/badge.svg)](https://maven-badges.herokuapp.com/maven-central/io.toolisticon.testing/jgiven-kotlin)

## Usage

### Maven
```
<dependency>
<groupId>io.toolisticon.testing</groupId>
<artifactId>jgiven-kotlin</artifactId>
<version>0.1.0</version>
<scope>test</scope>
</dependency>
```

## Features

Expand Down Expand Up @@ -71,7 +84,7 @@ Since all classes and functions are final by default in kotlin, you have to expl

Using the `JGivenKotlinStage` annotation and kotlin's "all-open" compiler plugin, this can be avoided.

#### gradle
#### Gradle

```kotlin
plugins {
Expand All @@ -85,7 +98,7 @@ allOpen {
}
```

#### maven
#### Maven

```xml

Expand Down
17 changes: 10 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>io.toolisticon.testing</groupId>
<artifactId>jgiven-kotlin</artifactId>
<version>0.1.0</version>
<version>1.0.0</version>

<name>${project.artifactId}</name>
<description>jgiven kotlin extension</description>
Expand All @@ -16,10 +16,10 @@
<java.version>11</java.version>
<maven.compiler.source>${java.version}</maven.compiler.source>
<maven.compiler.target>${java.version}</maven.compiler.target>
<kotlin.version>1.4.21</kotlin.version>
<kotlin.version>1.4.32</kotlin.version>
<kotlin.compiler.incremental>true</kotlin.compiler.incremental>

<jgiven.version>1.0.0-RC7</jgiven.version>
<jgiven.version>1.0.0</jgiven.version>
<spring-boot.version>2.3.7.RELEASE</spring-boot.version>

</properties>
Expand Down Expand Up @@ -47,7 +47,6 @@
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib-jdk8</artifactId>
<version>${kotlin.version}</version>
<scope>provided</scope>
</dependency>

Expand Down Expand Up @@ -263,7 +262,7 @@
<plugin>
<groupId>org.jetbrains.dokka</groupId>
<artifactId>dokka-maven-plugin</artifactId>
<version>1.4.20</version>
<version>1.4.30</version>
<executions>
<execution>
<id>attach-javadocs</id>
Expand All @@ -288,6 +287,7 @@
</sourceDirectories>
</configuration>
</plugin>

<!-- Source from kotlin -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
Expand Down Expand Up @@ -332,7 +332,7 @@
<plugin>
<groupId>com.amashchenko.maven.plugin</groupId>
<artifactId>gitflow-maven-plugin</artifactId>
<version>1.15.1</version>
<version>1.16.0</version>
<configuration>
<gitFlowConfig>
<productionBranch>master</productionBranch>
Expand All @@ -356,7 +356,6 @@
<artifactId>maven-gpg-plugin</artifactId>
<version>1.6</version>
<configuration>
<keyname>${gpg.keyname}</keyname>
<gpgArguments>
<arg>--batch</arg>
<arg>--yes</arg>
Expand Down Expand Up @@ -428,11 +427,15 @@
<requireMavenVersion>
<version>3.6.0</version>
</requireMavenVersion>
<requireJavaVersion>
<version>11</version>
</requireJavaVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>

</plugins>
</pluginManagement>

Expand Down

0 comments on commit 632a2c8

Please sign in to comment.