Skip to content
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
# These are explicitly windows files and should use crlf
*.bat text eol=crlf

# Mark generated OpenAPI models as generated code
# This collapses diffs in PRs and excludes from language statistics
src/main/java/io/permit/sdk/openapi/models/** linguist-generated=true
33 changes: 33 additions & 0 deletions .github/workflows/javadoc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Javadoc Verification

on:
pull_request:
branches: [ master ]
push:
branches: [ master ]

jobs:
javadoc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Comment thread
zeevmoney marked this conversation as resolved.
Outdated
- uses: actions/setup-java@v3.11.0
with:
java-version: '8'
distribution: 'corretto'
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: Generate Javadoc
uses: gradle/gradle-build-action@v2
with:
arguments: javadoc
- name: Check Javadoc generation
run: |
if [ -d "build/docs/javadoc" ]; then
echo "Javadoc generated successfully"
echo "Javadoc files:"
find build/docs/javadoc -name "*.html" | head -20
else
echo "ERROR: Javadoc directory not found"
exit 1
fi
24 changes: 18 additions & 6 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
name: Publish package to GitHub Packages
on:
release:
types: [created]
types: [ created ]
workflow_dispatch:

jobs:
publish:
runs-on: ubuntu-latest
permissions:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
packages: write
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v3.11.0
Expand All @@ -18,6 +18,18 @@ jobs:
distribution: 'corretto'
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: Verify Javadoc generation
uses: gradle/gradle-build-action@v2
with:
arguments: javadoc
- name: Check Javadoc generation
run: |
if [ -d "build/docs/javadoc" ]; then
echo "Javadoc verified successfully"
else
echo "ERROR: Javadoc directory not found"
exit 1
fi
- name: Publish package
uses: gradle/gradle-build-action@v2
with:
Expand All @@ -29,4 +41,4 @@ jobs:
GPG_SIGNING_KEY: ${{ secrets.GPG_SIGNING_KEY }}
GPG_SIGNING_PASSPHRASE: ${{ secrets.GPG_SIGNING_PASSPHRASE }}
NEXUS_TOKEN_USERNAME: ${{ secrets.NEXUS_TOKEN_USERNAME }}
NEXUS_TOKEN_PASSWORD: ${{ secrets.NEXUS_TOKEN_PASSWORD }}
NEXUS_TOKEN_PASSWORD: ${{ secrets.NEXUS_TOKEN_PASSWORD }}
5 changes: 5 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,11 @@ tasks.named('test') {
useJUnitPlatform()
}

tasks.named('javadoc') {
// Exclude generated OpenAPI models from javadoc generation
exclude 'io/permit/sdk/openapi/models/**'
}

tasks.named('jar') {
manifest {
attributes('Implementation-Title': project.name,
Expand Down
Loading