CI and tests; clean up makefiles #1
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: Compile and Publish Console | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
docker run --rm -v $PWD:/app -w /app ghcr.io/panda-re/embedded-toolchains:latest /app/build.sh | |
tar -czvf console-latest.tar.gz build | |
- name: Save package | |
uses: actions/upload-artifact@v3 | |
with: | |
name: console | |
path: build | |
- name: Create release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: release_${{ github.sha }} | |
release_name: Release ${{ github.ref }} | |
body: | | |
Release @${{ github.ref }} | |
draft: true | |
prerelease: false | |
- name: Upload release asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./console-latest.tar.gz | |
asset_name: console-latest.tar.gz | |
asset_content_type: application/gzip | |
- name: Publish release | |
uses: StuYarrow/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
id: ${{ steps.create_release.outputs.id }} |