workflow #21
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: Create Release with Binary | ||
on: | ||
push: | ||
branches: [ "master" ] | ||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Get version from config.make | ||
id: get_version | ||
run: | | ||
VERSION=$(sed -ne 's/^VERSION := //p' config.make | tr -d '\n') | ||
echo "::set-output name=version::$VERSION" | ||
- name: Download Binary using wget | ||
run: | | ||
wget https://github.com/michael105/static-bin/raw/refs/heads/main/xorg/slterm | ||
chmod a+x slterm | ||
mv slterm slterm_linux_amd64 | ||
- name: Create GitHub Release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ steps.get_version.outputs.version }} | ||
release_name: Release ${{ steps.get_version.outputs.version }} testing | ||
body: | | ||
statically linked binary for linux/64bit attached | ||
draft: false | ||
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: ./slterm_linux_amd64 | ||
asset_name: slterm_linux_amd64 | ||
asset_content_type: application/octet-stream | ||