Skip to content

Commit

Permalink
build(github:actions): fix github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
yiteam committed Dec 28, 2022
1 parent 775303b commit 698e3f0
Show file tree
Hide file tree
Showing 8 changed files with 63 additions and 31 deletions.
58 changes: 37 additions & 21 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,25 @@ env:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

if: startsWith(github.event.head_commit.message, 'bumped version to ') != true

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Set up JDK 1.8
uses: actions/setup-java@v1
- name: Set up JDK 17
uses: actions/setup-java@v3.9.0
with:
java-version: 1.8
java-version: 17
distribution: 'temurin'

- name: Cache dependencies
uses: actions/cache@v1
uses: actions/cache@v3.2.2
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
Expand All @@ -40,21 +44,25 @@ jobs:
test:
needs: [ build ]
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

if: startsWith(github.event.head_commit.message, 'bumped version to ') != true

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Set up JDK 1.8
uses: actions/setup-java@v1
- name: Set up JDK 17
uses: actions/setup-java@v3.9.0
with:
java-version: 1.8
java-version: 17
distribution: 'temurin'

- name: Cache dependencies
uses: actions/cache@v1
uses: actions/cache@v3.2.2
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
Expand All @@ -69,21 +77,25 @@ jobs:
deploy_snapshot:
needs: [ build, test ]
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

if: (github.ref == 'refs/heads/master') && startsWith(github.event.head_commit.message, 'release:') != true
if: (github.ref == 'refs/heads/main') && startsWith(github.event.head_commit.message, 'release:') != true

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Set up JDK 1.8
uses: actions/setup-java@v1
- name: Set up JDK 17
uses: actions/setup-java@v3.9.0
with:
java-version: 1.8
java-version: 17
distribution: 'temurin'

- name: Cache dependencies
uses: actions/cache@v1
uses: actions/cache@v3.2.2
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
Expand Down Expand Up @@ -114,21 +126,25 @@ jobs:
deploy_release:
needs: [ build, test ]
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

if: startsWith(github.ref, 'refs/tags/') && startsWith(github.event.head_commit.message, 'release')

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Set up JDK 1.8
uses: actions/setup-java@v1
- name: Set up JDK 17
uses: actions/setup-java@v3.9.0
with:
java-version: 1.8
java-version: 17
distribution: 'temurin'

- name: Cache dependencies
uses: actions/cache@v1
uses: actions/cache@v3.2.2
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
Expand Down
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,20 @@

### Chores

- **deps**: bumped spring version to 3.0.1 ([6c6f4521](https://github.com/ymind/rsql-querydsl/commit/6c6f4521f7833546c53dc9a29946101e779f0d84))
- **deps**: bumped spring version to 3.0.1 ([a5d3da5f](https://github.com/ymind/rsql-querydsl/commit/a5d3da5f1571775184290553db4b47911d9de330))
- no longer print stack trace when TypeNotSupportedException occurred ([1fd80544](https://github.com/ymind/rsql-querydsl/commit/1fd805446ba0522c679f84b633d0be9c617e4e80))


### Styles

- code cleanup ([3e7152bc](https://github.com/ymind/rsql-querydsl/commit/3e7152bcaf1254bfd957ffa7ce61562320836f39))


### Build System

- **github:actions**: fix github actions ([5864ee73](https://github.com/ymind/rsql-querydsl/commit/5864ee7376c1499ee346b791a59ccdee32c28537))
- **gradle**: bumped gradle wrapper version to 7.5.1 ([fb6c22e7](https://github.com/ymind/rsql-querydsl/commit/fb6c22e7c1d8d5190580e9e7f38c7ea8cbd99463))
- **gradle**: bumped gradle wrapper version to 7.6 ([775303b1](https://github.com/ymind/rsql-querydsl/commit/775303b1f79300eaf94668a08337164e2635fdd4))
- **gradle:plugin**: remove ktlint plugin ([7cddf171](https://github.com/ymind/rsql-querydsl/commit/7cddf171994e046a53ba664c5d3ebbfb9f885054))
- **gradle:plugin**: bumped io.gitlab.arturbosch.detekt version to 1.22.0 ([c07c4173](https://github.com/ymind/rsql-querydsl/commit/c07c4173ee567111d28840f65f505df8dfd9ebe8))
- **gradle:plugin**: bumped com.github.ben-manes.versions version to 0.44.0 ([586c08e3](https://github.com/ymind/rsql-querydsl/commit/586c08e337afc1b46594f9971010a6e02a20782d))
Expand Down
10 changes: 9 additions & 1 deletion CHANGELOG.zh-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,20 @@

### Chores

- **deps**: bumped spring version to 3.0.1 ([6c6f4521](https://github.com/ymind/rsql-querydsl/commit/6c6f4521f7833546c53dc9a29946101e779f0d84))
- **deps**: bumped spring version to 3.0.1 ([a5d3da5f](https://github.com/ymind/rsql-querydsl/commit/a5d3da5f1571775184290553db4b47911d9de330))
- no longer print stack trace when TypeNotSupportedException occurred ([1fd80544](https://github.com/ymind/rsql-querydsl/commit/1fd805446ba0522c679f84b633d0be9c617e4e80))


### Styles

- code cleanup ([3e7152bc](https://github.com/ymind/rsql-querydsl/commit/3e7152bcaf1254bfd957ffa7ce61562320836f39))


### Build System

- **github:actions**: fix github actions ([5864ee73](https://github.com/ymind/rsql-querydsl/commit/5864ee7376c1499ee346b791a59ccdee32c28537))
- **gradle**: bumped gradle wrapper version to 7.5.1 ([fb6c22e7](https://github.com/ymind/rsql-querydsl/commit/fb6c22e7c1d8d5190580e9e7f38c7ea8cbd99463))
- **gradle**: bumped gradle wrapper version to 7.6 ([775303b1](https://github.com/ymind/rsql-querydsl/commit/775303b1f79300eaf94668a08337164e2635fdd4))
- **gradle:plugin**: remove ktlint plugin ([7cddf171](https://github.com/ymind/rsql-querydsl/commit/7cddf171994e046a53ba664c5d3ebbfb9f885054))
- **gradle:plugin**: bumped io.gitlab.arturbosch.detekt version to 1.22.0 ([c07c4173](https://github.com/ymind/rsql-querydsl/commit/c07c4173ee567111d28840f65f505df8dfd9ebe8))
- **gradle:plugin**: bumped com.github.ben-manes.versions version to 0.44.0 ([586c08e3](https://github.com/ymind/rsql-querydsl/commit/586c08e337afc1b46594f9971010a6e02a20782d))
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
![rsql-querydsl](https://github.com/ymind/rsql-querydsl/workflows/rsql-querydsl/badge.svg?branch=master)
![rsql-querydsl](https://github.com/ymind/rsql-querydsl/workflows/rsql-querydsl/badge.svg?branch=main)
[![GitHub release (latest by date)](https://img.shields.io/github/v/release/ymind/rsql-querydsl)](https://github.com/ymind/rsql-querydsl/releases)
[![Maven Central](https://img.shields.io/maven-central/v/team.yi.rsql/rsql-querydsl)](https://search.maven.org/artifact/team.yi.rsql/rsql-querydsl)
[![Semantic Versioning 2.0.0](https://img.shields.io/badge/Semantic%20Versioning-2.0.0-brightgreen)](https://semver.org/)
[![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg)](https://conventionalcommits.org)
[![GitHub](https://img.shields.io/github/license/ymind/rsql-querydsl)](https://github.com/ymind/rsql-querydsl/blob/master/LICENSE)
[![GitHub](https://img.shields.io/github/license/ymind/rsql-querydsl)](https://github.com/ymind/rsql-querydsl/blob/main/LICENSE)

# rsql-querydsl

Expand Down
4 changes: 2 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ tasks {
changelog {
group = "publishing"

toRef = "master"
toRef = "main"
strategy = team.yi.tools.semanticgitlog.VersionStrategy.slow

minorTypes = "feat,refactor,perf,revert"
Expand Down Expand Up @@ -129,7 +129,7 @@ tasks {
derive {
group = "publishing"

toRef = "master"
toRef = "main"
strategy = team.yi.tools.semanticgitlog.VersionStrategy.slow
derivedVersionMark = "NEXT_VERSION:=="

Expand Down
4 changes: 2 additions & 2 deletions docs/_coverpage.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
[Getting Started](en-us/)
[GitHub](https://github.com/ymind/rsql-querydsl)

[10]: https://github.com/ymind/rsql-querydsl/workflows/rsql-querydsl/badge.svg?branch=master
[10]: https://github.com/ymind/rsql-querydsl/workflows/rsql-querydsl/badge.svg?branch=main
[11]: https://github.com/ymind/rsql-querydsl/actions
[20]: https://img.shields.io/github/v/release/ymind/rsql-querydsl
[21]: https://github.com/ymind/rsql-querydsl/releases
Expand All @@ -25,4 +25,4 @@
[50]: https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg
[51]: https://conventionalcommits.org
[60]: https://img.shields.io/github/license/ymind/rsql-querydsl
[61]: https://github.com/ymind/rsql-querydsl/blob/master/LICENSE
[61]: https://github.com/ymind/rsql-querydsl/blob/main/LICENSE
2 changes: 1 addition & 1 deletion docs/en-us/changelog.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[remoteMarkdownUrl](https://raw.githubusercontent.com/ymind/rsql-querydsl/master/CHANGELOG.md)
[remoteMarkdownUrl](https://raw.githubusercontent.com/ymind/rsql-querydsl/main/CHANGELOG.md)
2 changes: 1 addition & 1 deletion docs/zh-cn/changelog.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[remoteMarkdownUrl](https://raw.githubusercontent.com/ymind/rsql-querydsl/master/CHANGELOG.zh-cn.md)
[remoteMarkdownUrl](https://raw.githubusercontent.com/ymind/rsql-querydsl/main/CHANGELOG.zh-cn.md)

0 comments on commit 698e3f0

Please sign in to comment.