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

Homebrew integration for mac #147

Open
johnhe4 opened this issue Apr 27, 2023 · 0 comments
Open

Homebrew integration for mac #147

johnhe4 opened this issue Apr 27, 2023 · 0 comments

Comments

@johnhe4
Copy link

johnhe4 commented Apr 27, 2023

I am using replxx for an internal tool (which I hope to open source at some point) and am putting together a Tap for homebrew (private for now). Replxx is the only lib I'm using that doesn't have a homebrew formula. Homebrew is the most common way to install open-source libs on a Mac. Would you be interested in working with me to submit a formula for replxx?

I have never contributed a "core" formula but the instructions seem clear: https://docs.brew.sh/Formula-Cookbook

Here is what works in my private tap that can be used (with some modification) as a baseline for a submitted formula:

require "formula"

class Replxx < Formula
  desc "A small, portable GNU readline replacement for Linux, Windows and MacOS which is capable of handling UTF-8 characters. Unlike GNU readline, which is GPL, this library uses a BSD license and can be used in any kind of program."
  homepage "https://github.com/AmokHuginnsson/replxx"
#  # Use this once github releases are made 
#  url "https://github.com/AmokHuginnsson/replxx/archive/refs/tags/release-0.0.4.tar.gz", :using => GitHubPrivateRepositoryReleaseDownloadStrategy
  url "git@github.com:AmokHuginnsson/replxx.git", :using => :git, :tag => 'release-0.0.4'
  license "BSD 3-Clause"
  version "0.0.4"

  depends_on "cmake" => :build

  def install
    mkdir "build" do
      # std_cmake_args already includes build=release, testing=off
      system "cmake", "..", *std_cmake_args
      system "make"
      system "make", "install"
    end
  end
end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant