-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workflow to refresh jdk23 from upstream
- Loading branch information
Showing
1 changed file
with
32 additions
and
0 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: "Refresh jdk23 from Upstream" | ||
on: | ||
schedule: | ||
- cron: '0 8 * * *' | ||
workflow_dispatch: | ||
env: | ||
UPSTREAM_REMOTE: https://github.com/openjdk/jdk.git | ||
LOCAL_BRANCH: jdk23 | ||
jobs: | ||
refresh-jdk: | ||
runs-on: ubuntu-latest | ||
name: "Update Corretto-jdk" | ||
if: github.repository_owner == 'corretto' | ||
steps: | ||
- name: "Checkout code" | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
ref: ${{ env.LOCAL_BRANCH }} | ||
- name: "Configure the user" | ||
run: | | ||
git config user.email "[email protected]" | ||
git config user.name "corretto-github-robot" | ||
- name: "Merge openjdk/jdk:jdk23 to the corretto-jdk:jdk23" | ||
run: | | ||
git fetch $UPSTREAM_REMOTE jdk23 || exit 1 | ||
git merge -m "Merge upstream-jdk" FETCH_HEAD | ||
- name: "Update Corretto version" | ||
shell: bash | ||
run: bash ./.github/scripts/update-version.sh $UPSTREAM_REMOTE | ||
- name: "Push to the corretto-jdk" | ||
run: git push origin $LOCAL_BRANCH |