Add a desc field to Formula
This commit is contained in:
parent
60f2377853
commit
86365470e6
@ -163,6 +163,12 @@ class Formula
|
|||||||
Bottle.new(self, bottle_specification) if bottled?
|
Bottle.new(self, bottle_specification) if bottled?
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# The description of the software.
|
||||||
|
# @see .desc
|
||||||
|
def desc
|
||||||
|
self.class.desc
|
||||||
|
end
|
||||||
|
|
||||||
# The homepage for the software.
|
# The homepage for the software.
|
||||||
# @see .homepage
|
# @see .homepage
|
||||||
def homepage
|
def homepage
|
||||||
@ -685,6 +691,7 @@ class Formula
|
|||||||
def to_hash
|
def to_hash
|
||||||
hsh = {
|
hsh = {
|
||||||
"name" => name,
|
"name" => name,
|
||||||
|
"desc" => desc,
|
||||||
"homepage" => homepage,
|
"homepage" => homepage,
|
||||||
"versions" => {
|
"versions" => {
|
||||||
"stable" => (stable.version.to_s if stable),
|
"stable" => (stable.version.to_s if stable),
|
||||||
@ -921,6 +928,12 @@ class Formula
|
|||||||
# @private
|
# @private
|
||||||
attr_reader :keg_only_reason
|
attr_reader :keg_only_reason
|
||||||
|
|
||||||
|
# @!attribute [w]
|
||||||
|
# A one-line description of the software. Used by users to get an overview
|
||||||
|
# of the software and Homebrew maintainers.
|
||||||
|
# Shows when running `brew info`.
|
||||||
|
attr_rw :desc
|
||||||
|
|
||||||
# @!attribute [w]
|
# @!attribute [w]
|
||||||
# The homepage for the software. Used by users to get more information
|
# The homepage for the software. Used by users to get more information
|
||||||
# about the software and Homebrew maintainers as a point of contact for
|
# about the software and Homebrew maintainers as a point of contact for
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user