brew.h info takes a formula parameter rather than a string
* Preference is for commands to take instantiated formulae as parameters rather than formula names, so alias resolution can be centralized.
This commit is contained in:
parent
a496ca0166
commit
bc5ee7c482
@ -185,12 +185,9 @@ def github_info name
|
||||
return "http://github.com/#{user}/homebrew/commits/#{branch}/Library/Formula/#{formula_name}"
|
||||
end
|
||||
|
||||
def info name
|
||||
require 'formula'
|
||||
|
||||
def info f
|
||||
exec 'open', github_info(name) if ARGV.flag? '--github'
|
||||
|
||||
f=Formula.factory name
|
||||
puts "#{f.name} #{f.version}"
|
||||
puts f.homepage
|
||||
|
||||
@ -213,7 +210,7 @@ def info name
|
||||
puts
|
||||
end
|
||||
|
||||
history = github_info(name)
|
||||
history = github_info(f.name)
|
||||
puts history if history
|
||||
|
||||
rescue FormulaUnavailableError
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user