Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

installation scripts #232

Merged
merged 2 commits into from
Mar 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions installation/brew/Formula/resonate.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
class Resonate < Formula
desc "A dead simple programming model for modern applications"
homepage "https://www.resonatehq.io/"
url "https://github.com/resonatehq/resonate/archive/refs/tags/v0.2.0.tar.gz"
license "Apache-2.0"

depends_on "go" => :build

def install
ENV["GOPATH"] = buildpath
system "go", "get", "-u", "github.com/resonatehq/resonate"
system "go", "build", "-o", bin/"resonate", "github.com/resonatehq/resonate"
end

test do
assert_match "Usage:", shell_output("#{bin}/resonatehq --help")
end
end
27 changes: 27 additions & 0 deletions installation/linux/install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#!/bin/bash

# Set the version you want to install
RES_VERSION="v0.2.0"

# Set the installation directory
INSTALL_DIR="/usr/local/bin"

# URL for the Resonate release tarball
RES_URL="https://github.com/resonatehq/resonate/releases/download/${RES_VERSION}/resonate-linux-amd64"

# Temporary directory for downloading
TMP_DIR=$(mktemp -d)

# Download Resonate binary
echo "Downloading Resonate ${RES_VERSION}..."
curl -L -o "${TMP_DIR}/resonate" "${RES_URL}"

# Install Resonate binary
echo "Installing Resonate to ${INSTALL_DIR}..."
sudo install "${TMP_DIR}/resonate" "${INSTALL_DIR}"

# Cleanup
echo "Cleaning up..."
rm -rf "${TMP_DIR}"

echo "Resonate ${RES_VERSION} has been installed!"
Loading