Homebrew tap when there is no artifact for the current OS Let's say I have a formula like this:
class Foo &lt; Formula
  desc &quot;Foo desc...&quot;
  homepage &quot;https://foo.com&quot;
  version &quot;1.2.3&quot;
  bottle :unneeded

  if OS.mac?
    url &quot;https://foo.com/1.2.3/foo_macos_x86_64.tar.gz&quot;
    sha256 &quot;fake&quot;
  end
  if OS.linux? &amp;&amp; Hardware::CPU.intel?
    url &quot;https://foo.com/1.2.3/foo_linux_x86_64.tar.gz&quot;
    sha256 &quot;fake&quot;
  end

  def install
    bin.install &quot;foo&quot;
  end

  test do
    system &quot;#{bin}/foo --version&quot;
  end
end

This works fine on both macOS and Linux amd64, but if the user tries it on a Linux arm, for example, they'll get an error like:
formulae require at least a URL
Error: Cannot tap foo/foo: invalid syntax in tap!

Which is in fact what's happening, there is no URL for Linux Arm.
Is there a way to make this error better? Maybe somehow say which architectures and OSs are supported or something?
I am not overly familiar with Homebrew, but depends_on seems to allow you to specify an architecture. I think adding
depends_on arch: :x86_64

to your formula will solve the issue nicely.