Skip to content

Build Release

Build Release #2

Workflow file for this run

name: Build Release
on:
workflow_dispatch:
env:
packageName: "com.varneon.vudon.common"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: get version
id: version
uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8
with:
path: "Packages/${{env.packageName}}/package.json"
prop_path: "version"
- run: echo ${{steps.version.outputs.prop}}
- name: Set Environment Variables
run: |
echo "zipFile=${{ env.packageName }}-${{ steps.version.outputs.prop }}".zip >> $GITHUB_ENV
echo "unityPackage=${{ env.packageName }}-${{ steps.version.outputs.prop }}.unitypackage" >> $GITHUB_ENV
- name: Create Zip
uses: thedoctor0/zip-release@a24011d8d445e4da5935a7e73c1f98e22a439464
with:
type: "zip"
directory: "Packages/${{env.packageName}}/"
filename: "../../${{env.zipFile}}" # make the zip file two directories up, since we start two directories in above
- run: find "Packages/${{env.packageName}}/" -name \*.meta >> metaList
- name: Create UnityPackage
uses: pCYSl5EDgo/create-unitypackage@cfcd3cf0391a5ef1306342794866a9897c32af0b
with:
package-path: ${{ env.unityPackage }}
include-files: metaList
- name: Make Release
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844
with:
tag_name: ${{ steps.version.outputs.prop }}
draft: true
files: |
${{ env.zipFile }}
${{ env.unityPackage }}
Packages/${{ env.packageName }}/package.json