From 0f70cc1291738fddb9d621ee3dc84eee177f43dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A2=A6=E9=87=8C=E4=B8=8D=E7=9F=A5=E8=BA=AB=E6=98=AF?= =?UTF-8?q?=E5=AE=A2?= Date: Wed, 11 Oct 2023 13:50:22 +0800 Subject: [PATCH] feat: prepare for 1.4.4 (#194) * feat: prepare for 1.4.4 * feat: Add workflow --------- Co-authored-by: unknowIfGuestInDream --- .github/auto_assign.yml | 8 ++ .github/dependabot.yml | 15 ++++ .github/labeler.yml | 1 - .github/linters/.markdown-lint.yml | 2 +- .github/linters/sun_checks.xml | 121 +++++++++++++++++++++++++---- .github/workflows/automerge.yml | 4 +- .github/workflows/changelog.yml | 22 +++--- .github/workflows/maven.yml | 23 ++---- .github/workflows/release.yml | 31 ++++++++ .github/workflows/stale.yml | 5 +- LICENSE | 2 +- SECURITY.md | 4 +- pom.xml | 5 +- 13 files changed, 187 insertions(+), 56 deletions(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/auto_assign.yml b/.github/auto_assign.yml index 28a6c18..8a3638f 100644 --- a/.github/auto_assign.yml +++ b/.github/auto_assign.yml @@ -4,7 +4,15 @@ addReviewers: false # Set to true to add assignees to pull requests addAssignees: author +#reviewers: +# - unknowIfGuestInDream +# - DreamAwakenFateBroke + # A number of assignees to add to the pull request # Set to 0 to add all of the assignees. # Uses numberOfReviewers if unset. numberOfAssignees: 0 +#numberOfReviewers: 0 + +skipKeywords: + - wip diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 5b06320..82eec26 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -9,3 +9,18 @@ updates: directory: "/" # Location of package manifests schedule: interval: "daily" + reviewers: + - "unknowIfGuestInDream" + - "DreamAwakenFateBroke" + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" + day: "friday" + timezone: "Asia/Shanghai" + reviewers: + - "unknowIfGuestInDream" + - "DreamAwakenFateBroke" + labels: + - "workflow" + - "github_actions" diff --git a/.github/labeler.yml b/.github/labeler.yml index 1e6b083..e5ae547 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -15,5 +15,4 @@ dependencies: automerge: - all: [ 'README.md' ] - all: [ 'CHANGELOG.md' ] - - all: [ '.github/**' ] - all: [ 'CONTRIBUTORS.md' ] \ No newline at end of file diff --git a/.github/linters/.markdown-lint.yml b/.github/linters/.markdown-lint.yml index f2dec62..88ab16f 100644 --- a/.github/linters/.markdown-lint.yml +++ b/.github/linters/.markdown-lint.yml @@ -22,7 +22,7 @@ MD004: false # Unordered list style MD007: indent: 2 # Unordered list indentation MD013: - line_length: 808 # Line length + line_length: 200 # Line length MD026: punctuation: ".,;:!。,;:" # List of not allowed MD029: false # Ordered list item prefix diff --git a/.github/linters/sun_checks.xml b/.github/linters/sun_checks.xml index 13b7bcb..b81edfd 100644 --- a/.github/linters/sun_checks.xml +++ b/.github/linters/sun_checks.xml @@ -1,4 +1,31 @@ + + @@ -39,7 +66,8 @@ - + @@ -53,14 +81,21 @@ - + + + + + + + + + - - - + + @@ -90,11 +125,27 @@ - - - - - + + + + + + + + + + + + + + + + + + + + + @@ -109,10 +160,15 @@ + + + + + @@ -124,12 +180,22 @@ + + + + + + + + + + @@ -147,6 +213,7 @@ + @@ -158,30 +225,50 @@ - - + + + + + + + + + + + + + + + + - - + + + - + + + + + - + - + diff --git a/.github/workflows/automerge.yml b/.github/workflows/automerge.yml index f2a895a..fdff679 100644 --- a/.github/workflows/automerge.yml +++ b/.github/workflows/automerge.yml @@ -32,11 +32,11 @@ jobs: runs-on: ubuntu-latest steps: - name: Merge pull requests - uses: pascalgn/automerge-action@v0.15.5 + uses: pascalgn/automerge-action@v0.15.6 env: GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" MERGE_LABELS: "automerge,!work in progress" MERGE_METHOD: "squash" MERGE_COMMIT_MESSAGE: "pull-request-title" MERGE_RETRIES: "10" - MERGE_RETRY_SLEEP: "60000" \ No newline at end of file + MERGE_RETRY_SLEEP: "60000" diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index 3c62eec..a1f96b3 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -9,14 +9,14 @@ jobs: generate-changelog: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: BobAnkh/auto-generate-changelog@v1.2.3 - with: - ACCESS_TOKEN: ${{secrets.GITHUB_TOKEN}} - PATH: 'CHANGELOG.md' - COMMIT_MESSAGE: 'docs(changelog): update release notes' - TYPE: 'feat:Feature,fix:Bug Fixes,refactor:Refactor,perf:Performance Improvements' - PULL_REQUEST: 'master' - BRANCH: 'changelog' + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: BobAnkh/auto-generate-changelog@v1.2.5 + with: + ACCESS_TOKEN: ${{secrets.GITHUB_TOKEN}} + PATH: 'CHANGELOG.md' + COMMIT_MESSAGE: 'docs(changelog): Update release notes' + TYPE: 'feat:Feature,fix:Bug Fixes,refactor:Refactor,perf:Performance Improvements' + PULL_REQUEST: 'master' + BRANCH: 'changelog' diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index b7e0f5e..708c8ec 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -4,30 +4,19 @@ name: Java CI with Maven on: - push: - branches: [ "master" ] pull_request: branches: [ "master" ] - pull_request_target: - types: - - labeled - - unlabeled - - synchronize - - opened - - edited - - ready_for_review - - reopened - - unlocked jobs: build: - - runs-on: ubuntu-latest - strategy: + fail-fast: false matrix: java: [ '11', '17' ] - + os: [ ubuntu-latest, macos-latest, windows-latest ] + experimental: [ false ] + runs-on: ${{ matrix.os }} + continue-on-error: ${{ matrix.experimental }} steps: - uses: actions/checkout@v3 - name: Set up JDK ${{ matrix.Java }} @@ -37,4 +26,4 @@ jobs: distribution: 'temurin' cache: maven - name: Build with Maven - run: mvn -B package --file pom.xml -Dmaven.test.skip=true + run: mvn -B package --file pom.xml -DskipTests diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..13ac5da --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,31 @@ +name: Maven Central Repo Deployment +# 触发脚本的事件 这里为发布release之后触发 +on: + workflow_dispatch: + release: + types: [ released ] +jobs: + publish: + runs-on: ubuntu-latest + steps: + - name: Checkout Git Repo + uses: actions/checkout@v2 + - name: Set up Maven Central Repo + uses: actions/setup-java@v1 + with: + java-version: 11 + - name: Set up Apache Maven Central + uses: actions/setup-java@v1 + with: # running setup-java again overwrites the settings.xml + java-version: 11 + server-id: sonatype-nexus-snapshots # Value of the distributionManagement/repository/id field of the pom.xml + server-username: MAVEN_USERNAME + server-password: MAVEN_CENTRAL_TOKEN + gpg-passphrase: MAVEN_GPG_PASSPHRASE + gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} + - name: Publish to Apache Maven Central + run: mvn clean deploy -P release + env: + MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }} + MAVEN_CENTRAL_TOKEN: ${{ secrets.OSSRH_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSWORD }} \ No newline at end of file diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index ae5e7ea..340e422 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -18,12 +18,15 @@ jobs: pull-requests: write steps: - - uses: actions/stale@v5 + - uses: actions/stale@v8 with: repo-token: ${{ secrets.GITHUB_TOKEN }} stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days' stale-pr-message: 'Stale pull request message' stale-issue-label: 'no-issue-activity' stale-pr-label: 'no-pr-activity' + exempt-issue-labels: 'wip' + exempt-pr-labels: 'wip' days-before-stale: 30 days-before-close: 5 + labels-to-remove-when-stale: "Ready-to-Go" diff --git a/LICENSE b/LICENSE index ac3f151..293b3c6 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2022 unknowIfGuestInDream +Copyright (c) 2023 unknowIfGuestInDream Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/SECURITY.md b/SECURITY.md index 384b016..cf0eb69 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -12,6 +12,6 @@ ## Reporting a Vulnerability(报告漏洞) -如果你发现有安全问题或漏洞,请发送邮件到`tang97155@gmail.com`。 +如果你发现有安全问题或漏洞,请发送邮件到`liang.tang.cx@gmail.com`。 -To report any found security issues or vulnerabilities, please send a mail to `tang97155@gmail.com`. +To report any found security issues or vulnerabilities, please send a mail to `liang.tang.cx@gmail.com`. diff --git a/pom.xml b/pom.xml index 7f1aa26..ab29c6c 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.tlcsdm tlcsdm-common tlcsdm-common - 1.4.3 + 1.4.4 tlcsdm工具类 https://www.tlcsdm.com @@ -32,7 +32,7 @@ unknowIfGuestInDream - tang97155@gmail.com + liang.tang.cx@gmail.com @@ -65,7 +65,6 @@ UTF-8 UTF-8 UTF-8 - -Xdoclint:none