Update release build to include MacOS, and to package README.md.

This commit is contained in:
Nolan Darilek 2020-08-14 08:37:11 -05:00
parent 8dfa941ba6
commit 6fd18b0de1

View File

@ -3,78 +3,95 @@ name: Release
on: on:
push: push:
tags: tags:
- 'v*' - "v*"
jobs: jobs:
build_linux: build_linux:
name: Build Linux name: Build Linux
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- run: | - run: |
sudo apt-get update sudo apt-get update
sudo apt-get install -y libspeechd-dev sudo apt-get install -y libspeechd-dev
cargo build --release --verbose cargo build --release --verbose
mv target linux mv target linux
- uses: actions/upload-artifact@v1 - uses: actions/upload-artifact@v1
with: with:
name: linux name: linux
path: linux path: linux
build_windows: build_windows:
name: Build Windows name: Build Windows
runs-on: windows-latest runs-on: windows-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- run: | - run: |
choco install -y llvm choco install -y llvm
cargo build --release --verbose cargo build --release --verbose
move target windows move target windows
- uses: actions/upload-artifact@v1 - uses: actions/upload-artifact@v1
with: with:
name: windows name: windows
path: windows path: windows
build_macos:
name: Build MacOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- run: |
cargo build --release
mv target macos
- uses: actions/upload-artifact@v1
with:
name: macos
path: macos
package: package:
name: Package name: Package
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [build_linux, build_windows] needs: [build_linux, build_windows, build_macos]
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/download-artifact@v1 - uses: actions/download-artifact@v1
with: with:
name: linux name: linux
- uses: actions/download-artifact@v1 - uses: actions/download-artifact@v1
with: with:
name: windows name: windows
- run: | - uses: actions/download-artifact@v1
mkdir godot-tts with:
cp godot-tts.gdnlib.release godot-tts/godot-tts.gdnlib name: macos
mkdir -p godot-tts/target/release - run: |
cp linux/release/*.so godot-tts/target/release mkdir godot-tts
cp windows/release/*.dll godot-tts/target/release cp godot-tts.gdnlib.release godot-tts/godot-tts.gdnlib
cp LICENSE godot-tts mkdir -p godot-tts/target/release
cp TTS.gd godot-tts.g* godot-tts cp linux/release/*.so godot-tts/target/release
cp godot-tts.gdnlib.release godot-tts/godot-tts.gdnlib cp windows/release/*.dll godot-tts/target/release
rm godot-tts/*.release cp macos/release/*.dylib godot-tts/target/release
cp -R android godot-tts cp LICENSE godot-tts
zip -r9 godot-tts godot-tts cp README.md godot-tts
- uses: actions/create-release@v1 cp TTS.gd godot-tts.g* godot-tts
id: create_release cp godot-tts.gdnlib.release godot-tts/godot-tts.gdnlib
env: rm godot-tts/*.release
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} cp -R android godot-tts
with: zip -r9 godot-tts godot-tts
tag_name: ${{ github.ref }} - uses: actions/create-release@v1
release_name: Release ${{ github.ref }} id: create_release
draft: false env:
prerelease: false GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/upload-release-asset@v1 with:
id: upload-release-asset tag_name: ${{ github.ref }}
env: release_name: Release ${{ github.ref }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} draft: false
with: prerelease: false
upload_url: ${{ steps.create_release.outputs.upload_url }} - uses: actions/upload-release-asset@v1
asset_path: ./godot-tts.zip id: upload-release-asset
asset_name: godot-tts.zip env:
asset_content_type: application/zip GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./godot-tts.zip
asset_name: godot-tts.zip
asset_content_type: application/zip