-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update hermes binaries to 1.7.3 and add a script to download automati…
…cally
- Loading branch information
Pantani
authored and
Pantani
committed
Dec 13, 2023
1 parent
7158ca3
commit c06da13
Showing
11 changed files
with
68 additions
and
5 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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Generate nodetime binaries | ||
name: Generate GEX binaries | ||
|
||
on: | ||
push: | ||
|
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,29 @@ | ||
name: Generate Hermes binaries | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- 'hermes/*.go' | ||
- 'scripts/gen-hermes' | ||
|
||
jobs: | ||
gen-hermes: | ||
name: "Generate hermes binaries" | ||
runs-on: ubuntu-latest | ||
concurrency: gen-hermes | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- run: ./scripts/gen-hermes | ||
|
||
- name: Create Pull Request | ||
id: cpr | ||
uses: peter-evans/create-pull-request@v4 | ||
with: | ||
title: "feat(hermes): update binaries" | ||
commit-message: "feat(hermes): update binaries" | ||
body: "" | ||
branch: feat/gen-hermes | ||
delete-branch: true |
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
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
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
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
Binary file renamed
BIN
+12.7 MB
...hermes-v1.7.1-aarch64-apple-darwin.tar.gz → hermes/hermes-aarch64-apple-darwin.tar.gz
Binary file not shown.
Binary file renamed
BIN
+13.3 MB
...s-v1.7.1-aarch64-unknown-linux-gnu.tar.gz → ...s/hermes-aarch64-unknown-linux-gnu.tar.gz
Binary file not shown.
Binary file renamed
BIN
+11.6 MB
.../hermes-v1.7.1-x86_64-apple-darwin.tar.gz → hermes/hermes-x86_64-apple-darwin.tar.gz
Binary file not shown.
Binary file renamed
BIN
+12 MB
...es-v1.7.1-x86_64-unknown-linux-gnu.tar.gz → ...es/hermes-x86_64-unknown-linux-gnu.tar.gz
Binary file not shown.
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,34 @@ | ||
#!/bin/bash | ||
|
||
# Define the repository URL and the folder where you want to save the binaries | ||
LAST_RELEASE_API="https://api.github.com/repos/informalsystems/hermes/releases/latest" | ||
REPO_URL="https://github.com/informalsystems/hermes" | ||
DEST_FOLDER="hermes" | ||
|
||
# Get the latest release version from GitHub API | ||
RELEASE_INFO=$(curl -s -L "$LAST_RELEASE_API") | ||
LATEST_TAG=$(echo "$RELEASE_INFO" | grep -o '"tag_name": "[^"]*' | grep -o '[^"]*$') | ||
echo "Download Hermes $LATEST_TAG binaries" | ||
|
||
# Loop through each platform and download the corresponding binary | ||
#hermes-v1.7.3-x86_64-unknown-linux-gnu.zip | ||
PLATFORMS=("aarch64-apple-darwin" "aarch64-unknown-linux-gnu" "x86_64-apple-darwin" "x86_64-unknown-linux-gnu") | ||
for PLATFORM in "${PLATFORMS[@]}"; do | ||
BINARY_NAME="hermes-$LATEST_TAG-$PLATFORM.tar.gz" | ||
DOWNLOAD_URL="$REPO_URL/releases/download/$LATEST_TAG/$BINARY_NAME" | ||
NEW_BINARY_NAME="hermes-$PLATFORM.tar.gz" | ||
DEST_FILE="$DEST_FOLDER/$NEW_BINARY_NAME" | ||
|
||
# Download the binary | ||
echo "Downloading $BINARY_NAME..." | ||
curl -sL "$DOWNLOAD_URL" -o "$DEST_FILE" | ||
|
||
# Check if the download was successful | ||
if [ $? -eq 0 ]; then | ||
echo "Downloaded $BINARY_NAME to $DEST_FILE" | ||
else | ||
echo "Failed to download $BINARY_NAME" | ||
fi | ||
done | ||
|
||
echo "All binaries downloaded to $DEST_FOLDER" |