-
Notifications
You must be signed in to change notification settings - Fork 719
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into ghe-pre-receive-hooks
- Loading branch information
Showing
7,332 changed files
with
252,191 additions
and
113,171 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: Create New Release Tag and PR | ||
|
||
on: workflow_dispatch | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: write | ||
|
||
jobs: | ||
create_release_tag: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Maven Central Repository | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
- name: Reset staging/main | ||
id: staging | ||
run: | | ||
git checkout -B staging/main | ||
git push --set-upstream -f origin staging/main | ||
- name: Set Release Version | ||
id: release | ||
run: | | ||
mvn -B versions:set versions:commit -DremoveSnapshot | ||
echo "version=$(mvn -B help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_OUTPUT | ||
- uses: stefanzweifel/git-auto-commit-action@v5 | ||
with: | ||
commit_message: "Prepare release (${{ github.actor }}): github-api-${{ steps.release.outputs.version }}" | ||
tagging_message: 'github-api-${{ steps.release.outputs.version }}' | ||
branch: staging/main | ||
|
||
- name: Increment Snapshot Version | ||
run: | | ||
mvn versions:set versions:commit -DnextSnapshot | ||
- uses: stefanzweifel/git-auto-commit-action@v5 | ||
with: | ||
commit_message: "Prepare for next development iteration" | ||
branch: staging/main | ||
|
||
- name: pull-request to main | ||
uses: repo-sync/pull-request@v2 | ||
with: | ||
pr_title: "Prepare release (${{ github.actor }}): github-api-${{ steps.release.outputs.version }}" | ||
source_branch: "staging/main" | ||
destination_branch: "main" | ||
github_token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
name: Publish package to the Maven Central Repository | ||
on: | ||
push: | ||
branches: | ||
- release/* | ||
|
||
# this is required by spotless for JDK 16+ | ||
env: | ||
JAVA_11_PLUS_MAVEN_OPTS: "--add-opens jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED --add-opens jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED --add-opens jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED --add-opens jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED --add-opens jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED" | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Maven Central Repository | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
- name: Maven Install and Site with Code Coverage | ||
env: | ||
MAVEN_OPTS: ${{ env.JAVA_11_PLUS_MAVEN_OPTS }} | ||
run: mvn -B clean install site -D enable-ci --file pom.xml "-Dsurefire.argLine=--add-opens java.base/java.net=ALL-UNNAMED" | ||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: maven-release-target-directory | ||
path: target/ | ||
retention-days: 3 | ||
|
||
publish_package: | ||
runs-on: ubuntu-latest | ||
needs: build | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Maven Central Repository | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
server-id: sonatype-nexus-staging | ||
server-username: MAVEN_USERNAME | ||
server-password: MAVEN_PASSWORD | ||
gpg-private-key: ${{ secrets.OSSRH_GPG_SECRET_KEY }} | ||
gpg-passphrase: MAVEN_GPG_PASSPHRASE | ||
|
||
- name: Publish package | ||
run: mvn -B clean deploy -DskipTests -Prelease | ||
env: | ||
MAVEN_OPTS: ${{ env.JAVA_11_PLUS_MAVEN_OPTS }} | ||
MAVEN_USERNAME: ${{ secrets.OSSRH_TOKEN_USERNAME }} | ||
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN_PASSWORD }} | ||
MAVEN_GPG_PASSPHRASE: ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSPHRASE }} | ||
|
||
publish_gh_pages: | ||
runs-on: ubuntu-latest | ||
needs: build | ||
if: ${{ github.ref == 'refs/heads/release/v1.x' }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set Release Version | ||
id: release | ||
run: | | ||
echo "version=$(mvn -B help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_OUTPUT | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: maven-release-target-directory | ||
path: target | ||
|
||
- name: Checkout GH Pages | ||
run: | | ||
git checkout -B gh-pages origin/gh-pages | ||
find . -type f -and -not -path './target/*' -and -not -path './.*' -and -not -name CNAME -delete | ||
cp -r ./target/site/* ./ | ||
- name: Publish GH Pages | ||
uses: stefanzweifel/git-auto-commit-action@v5 | ||
with: | ||
commit_message: "Release (${{ github.actor }}): v${{ steps.release.outputs.version }}" | ||
branch: gh-pages | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.