Code Monkey home page Code Monkey logo

Comments (4)

danopia avatar danopia commented on May 24, 2024 3

I've published a variant of the above on a personal tap, you can use it like so on either platform:

brew install danopia/tools/amber

This is the formula before bottles were inserted: https://github.com/danopia/homebrew-tools/blob/241fb4eeb58e301efb463a1d6bc52ffb9bd34fd1/Formula/amber.rb

I use both macOS and Linux so was able to verify this on both machines. (It's actually quite smooth to make a personal tap...)

To get the formula listed upstream, I believe it has to be PR'd to both https://github.com/Homebrew/homebrew-core and https://github.com/Homebrew/linuxbrew-core (the same file to both repos... There's ongoing work to merge the repos but it has not happened yet). The formula I wrote should pass any criteria though maybe the name should be more specific. Perhaps amber-search to line up with AUR.

from amber.

dalance avatar dalance commented on May 24, 2024

Homebrew accepts PR through https://github.com/Homebrew/homebrew-core.
If you are interesting in Homebrew packaging, could you try to send PR?
I can't maintain Homebrew package because I don't use brew and don't have macOS machine.

from amber.

danopia avatar danopia commented on May 24, 2024

Similarly, Homebrew on Linux support would be quite nice. This is one of the few tools that I have to seek out a binary of when setting up a Linux dev env vs. adding it to a brew install copy paste.

To my understanding Homebrew wants to be able to build everything from source, so one would want to expect to tell it how to do that (and then the prebuilts will be formed from the same instructions). So it'd probably be smart to look at other Rust taps/formulas/whatever.

from amber.

dalance avatar dalance commented on May 24, 2024

I used Homebrew on Linux, but don't use now because glibc compatibility issue can't be resolved on my environment.
If anyone try to send PR, the following may be helpful.

https://github.com/Homebrew/homebrew-core/pull/39584/files

I think the formula of amber is like below:

class Amber < Formula
  desc "A code search and replace tool"
  homepage "https://github.com/dalance/amber"
  url "https://github.com/dalance/amber/archive/v0.5.8.tar.gz"
  sha256 "f12e0b176273e011209e7d8613d1b9a049e50aeb536871c1f6c05a9d6a494935"

  depends_on "rust" => :build

  def install
    system "cargo", "install", "--root", prefix, "--path", "."
  end

  test do
    output = shell_output("#{bin}/ambr --help")
    count = output.lines.count
    assert count > 2
    assert output.start_with?("ambr")
  end
end

from amber.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.