-
-
Notifications
You must be signed in to change notification settings - Fork 3
Upload desktop binaries as Github Release assets #439
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
|
|
@@ -11,8 +11,13 @@ on: | |
|
|
||
| # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | ||
| permissions: | ||
| contents: read | ||
| # Needed for reading repository contents (read) | ||
| # and uploading assets to Github Releases (write) | ||
| contents: write | ||
| # Needed for deploying to GitHub Pages | ||
| pages: write | ||
| # Needed for getting the OIDC token for the Github Pages deployment | ||
| # See https://github.com/actions/deploy-pages?tab=readme-ov-file#oidc | ||
| id-token: write | ||
|
|
||
| # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. | ||
|
|
@@ -25,54 +30,56 @@ jobs: | |
| # Single deploy job since we're just deploying | ||
| conveyor: | ||
| name: "Create desktop distributions" | ||
| environment: production | ||
| environment: | ||
| name: github-pages | ||
| url: ${{ steps.deployment.outputs.page_url }} | ||
| runs-on: ubuntu-22.04 | ||
| env: | ||
| CONVEYOR_AGREE_TO_LICENSE: "1" | ||
| APP_VERSION: ${{ github.ref_name }} | ||
| steps: | ||
| - uses: actions/checkout@v2 | ||
| - uses: actions/setup-java@v3 | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Java | ||
| uses: actions/setup-java@v3 | ||
| with: | ||
| distribution: 'temurin' | ||
| java-version: '17' | ||
| - name: Setup Gradle | ||
|
|
||
| - name: Set up Gradle | ||
| uses: gradle/actions/setup-gradle@v3 | ||
|
|
||
| - run: ./gradlew jvmJar | ||
| - name: Build JAR | ||
| run: ./gradlew jvmJar | ||
|
|
||
| - uses: hydraulic-software/conveyor/actions/[email protected] | ||
| - name: Build desktop distributions | ||
| uses: hydraulic-software/conveyor/actions/[email protected] | ||
| with: | ||
| command: make site | ||
| signing_key: ${{ secrets.SIGNING_KEY }} | ||
| agree_to_license: 1 | ||
| cache_key: conveyor-${{ matrix.os }}-${{ matrix.arch }} | ||
|
|
||
| - uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: download-page | ||
| path: output | ||
| retention-days: 1 | ||
| - name: Extract download page files from output | ||
| run: | | ||
| mkdir -p pages_output/download | ||
| mv output/download.html pages_output/download/index.html | ||
| mv output/icon.png pages_output/download | ||
|
|
||
| - name: Upload artifacts to Github Release | ||
| env: | ||
| GH_TOKEN: ${{ github.token }} | ||
| run: gh release upload "$GITHUB_REF_NAME" output/* --clobber | ||
|
|
||
| deploy: | ||
| environment: | ||
| name: github-pages | ||
| url: ${{ steps.deployment.outputs.page_url }} | ||
| runs-on: ubuntu-latest | ||
| needs: [conveyor] | ||
| steps: | ||
| - name: Download a single artifact | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: download-page | ||
| path: download | ||
| - run: mv download/download.html download/index.html | ||
| - name: Setup Pages | ||
| uses: actions/configure-pages@v3 | ||
|
|
||
| - name: Upload artifact | ||
| uses: actions/upload-pages-artifact@v1 | ||
| uses: actions/upload-pages-artifact@v3 | ||
| with: | ||
| path: '.' | ||
| path: pages_output | ||
|
|
||
| - name: Deploy to GitHub Pages | ||
| id: deployment | ||
| uses: actions/deploy-pages@v2 | ||
| uses: actions/deploy-pages@v4 | ||
This file contains hidden or 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 hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.