docs: update docs #54
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: Build Kwsify | |
on: | |
- push | |
- pull_request | |
jobs: | |
build: | |
strategy: | |
matrix: | |
java: | |
- 8 | |
os: | |
- ubuntu-latest | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Validate gradle wrapper | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Setup jdk ${{ matrix.java }} | |
uses: actions/setup-java@v1 | |
with: | |
java-version: ${{ matrix.java }} | |
- name: Make Gradle wrapper executable | |
if: ${{ runner.os != 'Windows' }} | |
run: chmod +x ./gradlew | |
- name: Build with shadowJar | |
run: ./gradlew shadowJar | |
- name: Create Git Tag | |
id: create_tag | |
run: version=$(cat build.gradle | grep "version =" | sed "s/version = '\(.*\)'/\1/" | tr -d "'") && git tag $version && echo "tag=$version" >> $GITHUB_OUTPUT | |
- name: Rename artifact file | |
id: rename_artifact_file | |
run: mv ./build/libs/*-all.jar ./kwsify-${{ steps.create_tag.outputs.tag }}.jar | |
- name: Upload jar to release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.REPO_TOKEN }} | |
file: ./kwsify-${{ steps.create_tag.outputs.tag }}.jar | |
tag: ${{ steps.create_tag.outputs.tag }} | |
release_name: ${{ steps.create_tag.outputs.tag }}-Release | |
overwrite: true | |
file_glob: true | |
body: "Release for tag: ${{ steps.create_tag.outputs.tag }}" |