Skip to content

Merge pull request #220 from iamgio/runtime-refactor #212

Merge pull request #220 from iamgio/runtime-refactor

Merge pull request #220 from iamgio/runtime-refactor #212

Workflow file for this run

# This workflow will build the project with Gradle and release its build.
name: Gradle deploy
on:
push:
branches: [ "main", "workflow-test" ]
tags: [ "v*" ]
paths-ignore:
- '*.md'
- '**/README.md'
- 'LICENSE'
- '.github/FUNDING.yml'
jobs:
test:
uses: iamgio/quarkdown/.github/workflows/gradle-test.yml@main
build:
runs-on: ubuntu-latest
needs: [test]
steps:
- uses: iamgio/quarkdown/.github/actions/setup-environment@main
with:
full-checkout: true
- name: Build distribution
uses: burrunan/gradle-cache-action@v3
with:
job-id: main
arguments: distZip
- name: Echo output files
run: ls -d "$PWD/build/"*
- name: Distribute artifact
uses: actions/upload-artifact@v4
with:
name: quarkdown
path: build/distributions/quarkdown.zip
- name: Move devbuild tag to latest commit
run: |
git tag -d latest || true
git tag -f latest
git push origin +latest
- name: Create devbuild release
uses: softprops/[email protected]
with:
token: "${{ secrets.GITHUB_TOKEN }}"
tag_name: "latest"
prerelease: true
generate_release_notes: true
name: Development build
files: build/distributions/quarkdown.zip
- name: Create release
uses: softprops/[email protected]
if: github.ref_type == 'tag'
with:
token: "${{ secrets.GITHUB_TOKEN }}"
generate_release_notes: true
files: build/distributions/quarkdown.zip
- name: Generate docs
uses: burrunan/gradle-cache-action@v3
with:
job-id: main
arguments: quarkdocGenerateAll
- name: Deploy docs
uses: peaceiris/actions-gh-pages@v4
if: github.ref_type == 'tag'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build/docs
destination_dir: docs
- name: Deploy devbuild docs
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build/docs
destination_dir: docs/latest
# Bump Homebrew
- uses: mislav/bump-homebrew-formula-action@v3
if: github.ref_type == 'tag'
with:
formula-name: quarkdown
homebrew-tap: 'quarkdown-labs/homebrew-quarkdown'
env:
COMMITTER_TOKEN: ${{ secrets.COMMITTER_TOKEN }}
# Bump Scoop
- uses: iamgio/quarkdown/.github/actions/bump-scoop@main
if: github.ref_type == 'tag'
with:
version: ${{ github.ref_name }}
committer_token: ${{ secrets.COMMITTER_TOKEN }}
dependency-submission:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
# Generates and submits a dependency graph, enabling Dependabot Alerts for all project dependencies.
# See: https://github.com/gradle/actions/blob/main/dependency-submission/README.md
- name: Generate and submit dependency graph
uses: gradle/actions/dependency-submission@v4