Skip to content

Test release action #3 #10

Test release action #3

Test release action #3 #10

name: Build and Release
on:
push:
tags:
- "v*"
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
cache: gradle
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build DEX
run: ./gradlew generateDexRelease
- name: Get changelogs
id: changelogs
run: echo "::set-output name=content::$(cat ./changelogs/${{ github.ref_name }}.md | sed ':a;N;$!ba;s/\n/\\n/g')"
- name: Release
uses: ncipollo/release-action@v1
with:
artifacts: "./lib/build/outputs/dex/release/classes.dex"
name: "Release ${{ github.ref_name }}"
body: "## Changelogs\n${{ steps.changelogs.outputs.content }}\n\nSee [Wiki:Installing](https://github.com/HaruByte/Mitobi/wiki/Installing) for installation tutorial."