Skip to content

Commit

Permalink
added release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
pk910 committed Jul 28, 2023
1 parent da08168 commit 40379f9
Show file tree
Hide file tree
Showing 2 changed files with 86 additions and 3 deletions.
83 changes: 83 additions & 0 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@

name: Build Release

on:
workflow_dispatch:
inputs:
version:
description: "Version Number ('0.x.y')"
required: true


jobs:
build_binaries:
name: Build Binaries
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

# setup global dependencies
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.20.x

# setup project dependencies
- name: Get dependencies
run: |
go get -v -t -d ./...
# build binaries
- run: |
make build
# create draft release
- name: Create latest release
uses: actions/create-release@v1
id: create_release
with:
draft: true
prerelease: false
release_name: "v${{ inputs.version }}"
tag_name: "v${{ inputs.version }}"
body: |
### Major Changes
...
### Release Artifacts
| Release File | Description |
| ------------- | ------------- |
| [explorer_windows_amd64.exe](https://github.com/pk910/light-beaconchain-explorer/releases/download/${{ inputs.version }}/explorer_windows_amd64.exe) | explorer executable for windows (64bit) |
| [explorer_linux_amd64](https://github.com/pk910/light-beaconchain-explorer/releases/download/${{ inputs.version }}/explorer_linux_amd64) | explorer executable for linux (64bit) |
| [explorer_darwin_amd64](https://github.com/pk910/light-beaconchain-explorer/releases/download/${{ inputs.version }}/explorer_darwin_amd64) | explorer executable for macos (64bit) |
env:
GITHUB_TOKEN: ${{ github.token }}

# upload release artifacts
- name: "Upload artifact: explorer_windows_amd64.exe"
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/explorer_windows_amd64.exe
asset_name: explorer_windows_amd64.exe
asset_content_type: application/octet-stream
env:
GITHUB_TOKEN: ${{ github.token }}
- name: "Upload artifact: explorer_linux_amd64"
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/explorer_linux_amd64
asset_name: explorer_linux_amd64
asset_content_type: application/octet-stream
env:
GITHUB_TOKEN: ${{ github.token }}
- name: "Upload artifact: explorer_darwin_amd64"
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/explorer_darwin_amd64
asset_name: explorer_darwin_amd64
asset_content_type: application/gzip
env:
GITHUB_TOKEN: ${{ github.token }}
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ https://github.com/ethpandaops/tooling-wishlist/blob/master/tools/lightweight-be
First Version TODO:

* Explorer Pages (UI)
* [ ] Layout polishing
* [x] Layout polishing
* [x] Startpage
* [x] Add Network Status (number of validators / deposit & exit queue / ...?)
* [x] Epoch Overview (`/epochs`)
Expand Down Expand Up @@ -54,8 +54,8 @@ First Version TODO:
* Packaging & Release
* [x] Add license info
* [ ] Add documentation (setup & configuration)
* [ ] Docker image
* [ ] Github build & release actions
* [x] Docker image
* [x] Github build & release actions

Advanced TODO (Things that might be worth adding after the first version is ready)

Expand Down

0 comments on commit 40379f9

Please sign in to comment.