Skip to content

Commit

Permalink
Merge branch 'release/5.0.7'
Browse files Browse the repository at this point in the history
  • Loading branch information
bratkartoffel committed Jul 24, 2023
2 parents 13e203c + 5cac57f commit f2e483c
Show file tree
Hide file tree
Showing 12 changed files with 80 additions and 27 deletions.
15 changes: 7 additions & 8 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ jobs:
allowed-endpoints: >
api.adoptopenjdk.net:443
api.github.com:443
api.snapcraft.io:443
auth.docker.io:443
codecov.io:443
docker.io:443
Expand Down Expand Up @@ -54,7 +55,7 @@ jobs:
key: ${{ runner.os }}-maven-${{ github.run_id }}
- uses: niden/actions-memcached@3b3ecd9d0d035ea92db716dc1540a7dbe9e56349 # v7
- uses: supercharge/redis-github-action@f63fe516254d0af5df91755a4488274c2e71e38c # v1.5.0
- uses: gradle/wrapper-validation-action@8d49e559aae34d3e0eb16cde532684bc9702762b # v1.0.6
- uses: gradle/wrapper-validation-action@56b90f209b02bf6d1deae490e9ef18b21a389cd4 # v1.1.0
- run: ./gradlew --no-daemon check publishToMavenLocal
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # v3.1.4
with:
Expand All @@ -75,10 +76,12 @@ jobs:
integration-tests:
if: github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/support/4.6'
strategy:
fail-fast: false
matrix:
springBootVersion:
- 3.0.8
- 3.1.1
- 3.0.9
- 3.1.2
- 3.2.0-M1
runs-on: ubuntu-latest
needs: build
steps:
Expand All @@ -90,13 +93,11 @@ jobs:
api.adoptopenjdk.net:443
api.github.com:443
auth.docker.io:443
codecov.io:443
docker.io:443
downloads.gradle-dn.com:443
downloads.gradle.org:443
github.com:443
jcenter.bintray.com:443
jfrog-prod-use1-shared-virginia-main.s3.amazonaws.com:443
objects.githubusercontent.com:443
plugins.gradle.org:443
plugins-artifacts.gradle.org:443
Expand All @@ -105,8 +106,6 @@ jobs:
repo.maven.apache.org:443
repo.spring.io:443
services.gradle.org:443
storage.googleapis.com:443
uploader.codecov.io:443
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
with:
repository: 'bratkartoffel/security-jwt-examples'
Expand All @@ -126,6 +125,6 @@ jobs:
cache: 'gradle'
- uses: niden/actions-memcached@3b3ecd9d0d035ea92db716dc1540a7dbe9e56349 # v7
- uses: supercharge/redis-github-action@f63fe516254d0af5df91755a4488274c2e71e38c # v1.5.0
- uses: gradle/wrapper-validation-action@8d49e559aae34d3e0eb16cde532684bc9702762b # v1.0.6
- uses: gradle/wrapper-validation-action@56b90f209b02bf6d1deae490e9ef18b21a389cd4 # v1.1.0
- run: ./gradlew --no-daemon -PspringBootVersion=${{ matrix.springBootVersion }} -PsecurityJwtVersion=${{ needs.build.outputs.securityJwtVersion }} check
- run: ./gradlew --no-daemon -PspringBootVersion=${{ matrix.springBootVersion }} -PsecurityJwtVersion=${{ needs.build.outputs.securityJwtVersion }} starter-hibernate:dependencies | egrep '(:spring|:security-jwt)' | grep -v -- '->' | sed -e 's/^[+-\\| ]\+//' -e 's/ ([n\*])$//' | sort | uniq
14 changes: 12 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
# Changelog

### [unreleased]
* no changes yet
- no changes yet

## [5.0.7] (2023-07-24
* Add workaround for [spring-projects/spring-security#13572]

### [5.0.6] (2023-07-17)
* (all) fix invalid generated pom files with self-referential dependencies

### [4.6.8] (2023-07-17)
* (all) fix invalid generated pom files with self-referential dependencies

### [5.0.5] (2023-05-19)
* (base) upgrade openapi dependency to 2.2.10
* (base) upgrade jackson to 2.15.1
Expand Down Expand Up @@ -210,8 +216,10 @@
* Initial release to github and maven central


[unreleased]: https://github.com/bratkartoffel/security-jwt/compare/5.0.6...develop
[unreleased]: https://github.com/bratkartoffel/security-jwt/compare/5.0.7...develop
[5.0.7]: https://github.com/bratkartoffel/security-jwt/compare/5.0.6...5.0.7
[5.0.6]: https://github.com/bratkartoffel/security-jwt/compare/5.0.5...5.0.6
[4.6.8]: https://github.com/bratkartoffel/security-jwt/compare/4.6.7...4.6.8
[5.0.5]: https://github.com/bratkartoffel/security-jwt/compare/5.0.4...5.0.5
[4.6.7]: https://github.com/bratkartoffel/security-jwt/compare/4.6.6...4.6.7
[5.0.4]: https://github.com/bratkartoffel/security-jwt/compare/5.0.3...5.0.4
Expand Down Expand Up @@ -247,3 +255,5 @@
[0.7.0]: https://github.com/bratkartoffel/security-jwt/compare/0.6.0...0.7.0
[0.6.0]: https://github.com/bratkartoffel/security-jwt/compare/0.5.2...0.6.0
[0.5.2]: https://github.com/bratkartoffel/security-jwt/tree/0.5.2

[spring-projects/spring-security#13572]: https://github.com/spring-projects/spring-security/issues/13572
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@ should be sufficient for the most use cases.
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-base</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
<!-- or -->
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-base-spring-boot-starter</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
</dependencies>
```
Expand All @@ -68,27 +68,27 @@ When you want to add refresh token support, then choose one of the following dep
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-internal</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-memcache</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-hibernate</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-redis</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-files</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
</dependencies>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@

@Configuration
@AutoConfigureBefore(SecurityAutoConfiguration.class)
@EnableMethodSecurity(securedEnabled = true)
@Slf4j
public class SecurityJwtBaseAutoConfiguration {
@Bean
Expand Down
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ plugins {
id 'io.freefair.lombok' version "8.1.0" apply false
id 'com.adarshr.test-logger' version "3.2.0" apply false
id 'com.github.ben-manes.versions' version "0.47.0"
id 'org.springframework.boot' version "3.1.1" apply false
id 'org.springframework.boot' version "3.1.2" apply false
}

subprojects {
Expand Down Expand Up @@ -48,12 +48,12 @@ subprojects {
}

dependencies {
annotationProcessor group: "org.springframework.boot", name: "spring-boot-configuration-processor", version: "3.1.1"
annotationProcessor group: "org.springframework.boot", name: "spring-boot-configuration-processor", version: "3.1.2"

testFixturesApi group: "org.springframework.boot", name: "spring-boot-starter-test", version: "3.0.0"
testFixturesApi group: "org.springframework.boot", name: "spring-boot-starter-web", version: "3.0.0"
testFixturesApi group: "com.fasterxml.jackson.datatype", name: "jackson-datatype-jsr310", version: "2.15.2"
testFixturesApi group: 'org.junit.jupiter', name: 'junit-jupiter', version: "5.9.3"
testFixturesApi group: 'org.junit.jupiter', name: 'junit-jupiter', version: "5.10.0"
}

configurations.configureEach {
Expand Down
45 changes: 45 additions & 0 deletions cicd/release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#!/bin/bash
set -e

current_version=$(cat version.txt)
release_version=${current_version/-SNAPSHOT/}
previous_version=$(grep -Eo '^\[[0-9.]+\]' CHANGELOG.md | tr -d '[]' | sort -V | tail -n1)
next_version="$(perl -pe 's/^((\d+\.)*)(\d+)(.*)$/$1.($3+1).$4/e' <<<"$release_version")-SNAPSHOT"

# start release
git flow release start "$release_version"

# set version number to release
sed -i "s/$current_version/$release_version/" version.txt
git add version.txt
git commit -m "Version updated from $current_version to version $release_version"

# update the changelog
sed -i \
-e "/## \[unreleased/a - no changes yet\n\n## [$release_version] ($(date +%Y-%m-%d)" \
-e "/^\[unreleased\]:/a [$release_version]: https://github.com/bratkartoffel/security-jwt/compare/${previous_version}...${release_version}" \
-e "s|^\[unreleased\]:.\+develop$|[unreleased]: https://github.com/bratkartoffel/security-jwt/compare/${release_version}...develop|" \
CHANGELOG.md

# commit the changelog
git add CHANGELOG.md
git commit -m "Add release $release_version to changelog"

# update the READMEs
find . -name README.md -exec sed -i "s@<version>${previous_version}</version>@<version>${release_version}</version>@" {} \;
find . -name README.md -exec git add {} \;
git commit -m "Update README with new release"

# run the build and publish to central
./gradlew clean publish

# finish the release, merge the branches and create tag
git flow release finish -m "Release $release_version"

# set version number to next snapshot
sed -i "s/$release_version/$next_version/" version.txt
git add version.txt
git commit -m "Update version to next snapshot"

# push everything upstream
git push --atomic origin -- develop master refs/tags/"$release_version"
2 changes: 1 addition & 1 deletion files/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This module adds support for storing refresh tokens within an simple json docume
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-files</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion hibernate/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ for rows you have to regularly cleanup the token table, e.g. by using a cronjob.
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-hibernate</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion internal/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This module adds support for storing refresh tokens within an in-memory storage.
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-internal</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion memcache/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Please note that the memcache-plugin needs an external memcached server.
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-memcache</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion redis/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Please note that the redis-plugin needs an external redisd server.
<dependency>
<groupId>eu.fraho.spring</groupId>
<artifactId>security-jwt-redis</artifactId>
<version>5.0.6</version>
<version>5.0.7</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.0.6
5.0.7

0 comments on commit f2e483c

Please sign in to comment.