Skip to content

Commit

Permalink
Code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
cowwoc committed Oct 31, 2024
1 parent e6ab1a5 commit 834301c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 29 deletions.
37 changes: 9 additions & 28 deletions .github/workflows/deploy_to_maven_central.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ jobs:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
token: ${{ secrets.WORKFLOW_TOKEN }}
- uses: actions/setup-java@v4
with:
distribution: zulu
Expand Down Expand Up @@ -107,6 +106,8 @@ jobs:
- uses: actions/checkout@v4
with:
ref: ${{ needs.open-release.outputs.TAG }}
token: ${{ secrets.WORKFLOW_TOKEN }}
fetch-depth: 0
- uses: actions/setup-java@v4
with:
distribution: zulu
Expand Down Expand Up @@ -137,43 +138,23 @@ jobs:
-Dstaging_host="${{ env.STAGING_HOST }}"
deploy -P release
document:
name: Publish Javadoc documentation
needs: [ open-release, deploy ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ needs.open-release.outputs.TAG }}
fetch-depth: 0
- uses: actions/setup-java@v4
with:
distribution: zulu
java-version: |
8
23
- name: Configure Git User
run: |
git config user.email "[email protected]"
git config user.name "Gili Tzabari"
# Must quote exclamation mark on bash: https://stackoverflow.com/a/27177197/14731
- name: Generate Javadoc
run: |
./mvnw --batch-mode -V -e verify javadoc:aggregate -pl !dropwizard,!jersey
./mvnw --batch-mode -V -e javadoc:aggregate -pl '!dropwizard,!jersey'
mkdir --parents "${{ needs.open-release.outputs.VERSION }}/docs"
mv target/reports/apidocs "${{ needs.open-release.outputs.VERSION }}/docs/api"
- name: Commit changes
run: |
git checkout gh-pages
git checkout gh-pages -f
echo "INITIAL_GH_PAGES_POSITION=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
git add "${{ needs.open-release.outputs.VERSION }}/docs/api"
git commit -m "Released version ${{ needs.open-release.outputs.VERSION }}"
git push
close-release:
needs: [ open-release, deploy, document ]
needs: [ open-release, deploy ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -215,8 +196,8 @@ jobs:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
fetch-depth: 0
token: ${{ secrets.WORKFLOW_TOKEN }}
fetch-depth: 0
- uses: actions/setup-java@v4
with:
distribution: zulu
Expand Down Expand Up @@ -250,8 +231,8 @@ jobs:
git push -f origin ${{ github.ref_name }}
fi
- name: Delete master's tag
if: needs.open-release.outputs.INITIAL_MASTER_POSITION != ''
- name: Delete tag
if: needs.open-release.outputs.TAG != ''
run: |
git push --delete origin ${{ needs.open-release.outputs.TAG }}
Expand Down
2 changes: 1 addition & 1 deletion docs/Changelog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Minor updates involving cosmetic changes have been omitted from this list. See [commits](../../commits/master)
for a full list.

## Version 5.1 - 2024/10/29
## Version 5.1 - 2024/10/31

* Javadoc fixes.

Expand Down

0 comments on commit 834301c

Please sign in to comment.