homebrew-core/Formula/rails-completion.rb

27 lines
737 B
Ruby

class RailsCompletion < Formula
desc "Bash completion for Rails"
homepage "https://github.com/mernen/completion-ruby"
url "https://github.com/mernen/completion-ruby.git",
revision: "f3e4345042b0cc48317e45b673dfd3d23904b9a7"
version "2"
license "MIT"
head "https://github.com/mernen/completion-ruby.git", branch: "main"
livecheck do
formula "ruby-completion"
end
bottle do
sha256 cellar: :any_skip_relocation, all: "e52f96f415b50192094012cd4678e96b1c5e119c133224d4302e0bf2f6acea0e"
end
def install
bash_completion.install "completion-rails" => "rails"
end
test do
assert_match "-F __rails",
shell_output("bash -c 'source #{bash_completion}/rails && complete -p rails'")
end
end