-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Maups
committed
Nov 27, 2024
1 parent
f577c0f
commit 77b9b24
Showing
2 changed files
with
68 additions
and
3 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: Build and Release Escript | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v*' | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
# This step checks out a copy of your repository. | ||
- name: Checkout the code | ||
uses: actions/chechout@v3 | ||
|
||
- name: Set up Erlang and Elixir | ||
uses: erlef/setup-beam@v1 | ||
with: | ||
otp-version: "latest" | ||
elixir-version: "latest" | ||
install-hex: true | ||
install-rebar: true | ||
|
||
- name: Install Dependencies | ||
run: | | ||
mix local.hex | ||
mix local.rebar | ||
mix deps.get | ||
- name: Build | ||
run: mix escript.build | ||
|
||
- name: Upload Artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: escript-binary | ||
path: ./tl | ||
|
||
release: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Download Artifact | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: escript-binary | ||
|
||
- name: Create Github Release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | ||
with: | ||
tag_name: ${{github.ref_name}} | ||
release_name: Release ${{github.ref_name}} | ||
body: "Automatically generated release for ${{github.ref_name}}" | ||
draft: false | ||
prerelease: false | ||
|
||
- name: Upload Binary to Release | ||
uses: actions/upload-release-asset@v1 | ||
with: | ||
asset_path: ./tl | ||
asset_name: tl | ||
asset_content_type: application/octet-stream |
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