Publish Web #7
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
name: Publish Web | |
on: | |
workflow_dispatch: | |
inputs: | |
versionName: | |
description: '' | |
required: true | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
jobs: | |
publish: | |
name: Publish Web | |
runs-on: macos-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Grant Permission to Execute Gradle | |
run: chmod +x gradlew | |
- name: Build with Gradle | |
uses: gradle/gradle-build-action@v2 | |
with: | |
arguments: sample:composeApp:build | |
- name: Build sample JS - Main | |
run: ./gradlew :sample:composeApp:jsBrowserDistribution | |
- name: Upload your page as github pages artifact | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: sample/composeApp/build/dist/js/productionExecutable/ | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 |