From 781311e94c7967080119daec41d288a3a90b7691 Mon Sep 17 00:00:00 2001 From: Cody Cutrer Date: Wed, 12 Oct 2022 08:51:02 -0600 Subject: [PATCH] update git user for release action see https://github.com/actions/checkout/issues/13#issuecomment-724415212 also update the actions to non-deprecated versions --- .github/workflows/deploy.yml | 9 +++++---- .github/workflows/maven.yml | 5 +++-- .github/workflows/release.yml | 9 +++++---- RELEASING.md | 2 +- 4 files changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index d439198c7..ba402983e 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -13,10 +13,11 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up JDK 11 for Maven Central - uses: actions/setup-java@v1 + uses: actions/setup-java@v2 with: + distribution: 'zulu' java-version: '11' architecture: x64 server-id: ossrh @@ -26,8 +27,8 @@ jobs: server-password: MAVEN_CENTRAL_TOKEN - name: Setup git profile run: | - git config --global user.name github-actions - git config --global user.email github-actions@github.com + git config --global user.name "github-actions[bot]" + git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: Publish Snapshot to Maven Central run: mvn deploy -B -Possrh env: diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index a07bff253..c7f0c8de8 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -13,10 +13,11 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up JDK 11 - uses: actions/setup-java@v1 + uses: actions/setup-java@v2 with: + distribution: 'zulu' java-version: '11' architecture: x64 - name: Build with Maven diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0aa72794f..3e1ae1875 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,10 +16,11 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up JDK 11 - uses: actions/setup-java@v1 + uses: actions/setup-java@v2 with: + distribution: 'zulu' java-version: '11' architecture: x64 server-id: ossrh @@ -29,8 +30,8 @@ jobs: server-password: MAVEN_CENTRAL_TOKEN - name: Setup git profile run: | - git config user.name github-actions - git config user.email github-actions@github.com + git config --global user.name "github-actions[bot]" + git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: Maven release run: mvn release:prepare release:perform -B -DreleaseVersion=${{ github.event.inputs.releaseVersion }} -Possrh env: diff --git a/RELEASING.md b/RELEASING.md index a3001c9f3..6dd790693 100644 --- a/RELEASING.md +++ b/RELEASING.md @@ -2,6 +2,6 @@ These actions can only be performed by someone with maintainer level access to the repository. -1. Run the [Stage Release on Master Branch](https://github.com/hap-java/HAP-Java/actions/workflows/release.yml) Action +1. Run the [Stage Release on Master Branch](https://github.com/hap-java/HAP-Java/actions/workflows/release.yml) Action with a version such as `2.0.2` 2. After this completes, find the release on the [Releases page](https://github.com/hap-java/HAP-Java/releases) 3. Edit the release to include the changelog details