121 Commits

Author SHA1 Message Date
Adam Vandenberg
d5ba82ca7e fix info command 2012-08-07 12:23:25 -07:00
Max Howell
6629a9e23f Don't error out if never brew updated
Fixes Homebrew/homebrew#12944.
2012-08-06 16:44:11 -04:00
Max Howell
4b5052f614 Show options for foo with brew info foo
About time right?
2012-08-04 15:40:36 -04:00
Misty De Meo
0c237a8679 Add conflicts_with DSL method
conflicts_with is a thin wrapper around Requirement which simplifies
marking conflicts between formulae.

Closes Homebrew/homebrew#13687.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
2012-07-30 13:47:12 -03:00
Jack Nagel
6420943552 info: display available formula specs 2012-07-04 22:47:33 -05:00
Jack Nagel
210c9ac205 Use 'which' helper method more
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-05-13 19:28:03 -05:00
Maurice Kelly
3ab2cc62e2 info: handle git:// URLs in origin remote
The URL being constructed is only able to extract the correct username
when git@ or https:// URLs are found as the origin remote. This change
allows git:// to be used as well.

Signed-off-by: Maurice Kelly <osv-github@chatswood.org.uk>

Closes Homebrew/homebrew#11670.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-15 14:41:41 -05:00
Jack Nagel
d2c9b27e14 info: output correct URL for tapped dupes
Tapped formulae that dupe those in core now display the correct URL when
invoked like `brew info homebrew/dupes/openssl`.

This also fixes the broken `brew info` test.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-06 23:54:41 -05:00
Jack Nagel
49b0b3903f info: always indicate if a keg is linked
We mark the linked keg with an asterisk when multiple kegs exist, but
not when there is only a single keg. Start marking even in this case,
giving consistent behavior and a reliable indicate of the link status.

Fixes Homebrew/homebrew#11300.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-29 21:30:13 -05:00
Max Howell
6c0950999f brew info understands taps
Note I removed some of the code that changed the URL to be that of the github.user. Because this doesn't make any sense really. We want people to reference the commit history for whatever fork of homebrew they have checked out. So this is now what it does.
2012-03-16 21:06:16 +00:00
Jack Nagel
6858c00feb info: always mark currently linked keg with *
When multiple kegs are installed, `brew info` marks a keg with an
asterisk if f.installed_prefix == keg, but this is only true if either
HEAD or the newest version of the formula is installed. This isn't
always useful, so let's mark the currently linked keg with an asterisk
regardless of the version.

Obviously, keg-only formula will never be marked, but this is probably a
feature. When multiple keg-only kegs exist, chances are that they are
each being utilized by something, so there isn't really a "used" and
"unused" version.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-03 19:50:20 -06:00
Jack Nagel
d2bf7b4e2c info: display used options for all installed kegs
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-03 19:50:19 -06:00
Adam Vandenberg
fca07369ab Omit empty caveats 2011-12-20 20:11:54 -08:00
Jack Nagel
9e5c0da85b info: display used options for installed formulae
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-13 23:27:53 -06:00
Charlie Sharpsteen
94dba21f7d Centralize definition of rack in formula.rb
`rack` is a commonly used alias for `formula.prefix.parent`---so common that it
gets defined and used quite a bit. This patch makes `rack` an official method
of the `Formula` class.
2011-09-16 08:55:38 -07:00
Jack Nagel
32c746ef45 Add keg-only text to brew info output
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-08-11 11:46:35 -07:00
Jack Nagel
4b6de22cf2 Fix brew-info when on branch master and github.user set
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-06-16 19:30:19 -07:00
Sebastian Staudt
be482fb9ab Fixed reading branch name
The git command now uses --git-dir instead of --work-tree.
Using --work-tree won't work if you are inside another Git repository.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-04-18 22:30:48 -07:00
Joshua Peek
80886ff34a brew info should fetch remote formula info
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-03-14 10:18:39 -07:00
Adam Vandenberg
2a5f757816 Use + instead of /. 2011-03-12 11:55:07 -08:00
Max Howell
768910283a Refactor the brew command into one file per command
The code was sucking. To the extent that maintenance was hard. It's a lot
easier to work with code that is sensibly split at sensible boundaries. So
now it is more like that.

But the refactor is minimal. Because we don't want you to have more merge
hell than absolutely necessary.

If you merge you will need to pay attention to brew.h.rb (as it is deleted)
and bin/brew (as command logic is gone). It will be painful, but you will just
have to help git out by moving any changes around manually.

Note compatibility.rb. It ensures that any function renames or removals don't
break anything. We're pretty serious about backwards compatibility. And that's
because we encourage you to hack around with the innards. And we couldn't do
that if we would then just make stuff disappear behind your back.
2011-03-12 11:55:02 -08:00