Commit Graph
857 Commits
Author SHA1 Message Date
Jack Nagel 1a2f1cacf3 upgrade: tighten installed precondition 2013-05-18 22:09:15 -05:00
Jack Nagel 274a67e639 Stop running "prune" as part of "cleanup"
Rationale: "prune" is slow, does not need to be run as often as
"cleanup", and is potentially destructive to things like empty
directories that Homebrew did not create. Thus we should let users run
`brew prune` only when they wish to, while still being able to use `brew
cleanup`.

Closes #19863.
2013-05-18 20:22:24 -05:00
Jack Nagel 5b529b0851 Formula#fetch: always return the cached path
This allows us to remove some type checks that were protecting against
potential nils.
2013-05-16 14:06:26 -05:00
Jack Nagel 75e371684e Adjust semantics of Formula#fetch
It doesn't really make logical sense that this method returns both the
fetched path (or sometimes nil!) and the downloader, so just return the
path (again, or nil!) and callers that want the downloader can ask for
it separately.
2013-05-16 14:06:26 -05:00
Jack Nagel 5241271889 fetch: rename 'tarball' to 'download' 2013-05-16 14:06:26 -05:00
Jack Nagel 5b5d576084 fetch: use concat rather than << and flatten 2013-05-16 14:06:25 -05:00
Jack Nagel db426025cc Simplify uninstall --force 2013-05-15 22:27:30 -05:00
Jack Nagel 1614a13cc4 uninstall: stop assuming kegs always map to formulae 2013-05-15 22:19:58 -05:00
Jack Nagel 2e134437e2 cleanup: enable prune during dry-run mode
Closes #19826.
2013-05-15 12:57:02 -05:00
Jack Nagel e237dd274c prune: add dry-run mode 2013-05-15 12:57:01 -05:00
Jack Nagel 24acea9c76 cleanup: cleanup_all => cleanup_cellar 2013-05-15 12:57:01 -05:00
Jack Nagel 243089faf9 cleanup: refactor cleanup_cache 2013-05-15 12:57:01 -05:00
Jack Nagel 1539d8f598 cleanup: rename variable 2013-05-15 12:57:00 -05:00
Jack Nagel 3be1ac1ea9 cleanup: refactor cleanup_formula 2013-05-15 12:57:00 -05:00
Jack Nagel b02c5a82ec cleanup: only map dirs to kegs once 2013-05-15 12:57:00 -05:00
Jack Nagel 5d74f1ea3f cleanup: use Pathname#rmtree instead of FileUtils 2013-05-15 12:56:59 -05:00
Jack Nagel 2ec0fca0f7 cleanup: use subdirs, avoid .directory? checks 2013-05-15 12:56:59 -05:00
Jack Nagel 7b1d94f007 cleanup: remove redundant condition
If f.installed? is true, f.rack.directory? will always be true as well.
2013-05-15 12:56:59 -05:00
Jack Nagel bdf7913182 cleanup: rename method for consistency 2013-05-15 12:56:58 -05:00
Jack Nagel bceb8c57c8 cleanup: use early return rather than method-spanning conditional 2013-05-15 12:56:58 -05:00
Jack Nagel 717de9c6a7 cleanup: factor out unqualified cleanup code 2013-05-15 12:56:58 -05:00
Jack Nagel eb759a41ef Methods that end in _formula should only accept a formula 2013-05-15 12:56:57 -05:00
Jack Nagel 4bcb452d72 audit: fix version audit for Version subclasses
The version isn't redundant if a subclass of Version is specified.
2013-05-14 20:17:00 -05:00
Jack Nagel 8f828806cc outdated: always do comparisons with a Formula as the receiver
It is possible for the object returned by Formula#version to be a
subclass of Version with special behavior, so we want to use that for
the comparison.
2013-05-14 20:11:48 -05:00
Jack Nagel b29193d3b9 Use Hash#each_value rather than discarding key 2013-05-11 16:06:18 -05:00
Jack Nagel 724789d9f3 info: simplify keg listing 2013-05-10 23:45:36 -05:00
Jack Nagel 50700e8bc7 deps: fix --1 output
Fixes #17550.
Closes #19668.
2013-05-10 23:45:30 -05:00
Jack Nagel 0936cacd0b info: improve dependency listing 2013-05-10 23:45:06 -05:00
Jack Nagel 738d39285b doctor: update ruby version check 2013-05-07 19:45:10 -05:00
Jack Nagel 7c79f7ac48 doctor: update git version check 2013-05-07 19:45:10 -05:00
Jack Nagel 0778025732 audit: only generate aliases list once 2013-05-07 18:40:14 -05:00
Jack Nagel b304a3caf1 audit: only set up the build environment once 2013-05-07 18:39:45 -05:00
Jack Nagel 4e16c3de7c info: re-raise on blacklist miss 2013-05-02 21:34:48 -05:00
Adam Vandenberg 98c5b96454 --env: show HOMEBREW_CC in superenv
Closes #18247.
2013-05-02 11:36:30 -07:00
Adam Vandenberg 85fe4bd883 info: try blacklist for unknown formula names
Closes #17399.
2013-04-29 10:12:40 -07:00
Jack Nagel 03a4ecfbca Allow brew versions to work with underspecified formulae 2013-04-27 14:44:48 -05:00
Jack Nagel ddb90ed0f8 audit: fix interpolation check
Fixes #19363.
2013-04-26 19:18:13 -05:00
Misty De Meo 9b4310b362 doctor: don't shell out in coreutils check 2013-04-25 18:23:43 -05:00
Misty De Meo 2b34a9c612 doctor: add default-names findutils check
Fixes #19265.
2013-04-25 18:23:43 -05:00
Jack Nagel 10e60b092c audit: warn about top-level methods 2013-04-22 15:19:03 -05:00
Jack Nagel b596f73c03 Add tests for FormulaPin and simplify implementation 2013-04-16 01:58:11 -05:00
Jack Nagel bc33a40907 Avoid repeated interpolation here too 2013-04-14 23:48:20 -05:00
Adam Vandenberg 26dfa2ccbc Only prune taps if taps exist.
Closes #19192.
2013-04-14 09:35:16 -07:00
Jaime Marquínez Ferrándiz f5b8a6abd0 New visualization for brew deps --tree
Closes #18835.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-04-13 20:32:45 -05:00
Jack Nagel 5ba5e21536 Run tap --repair as part of prune
And by extension, `cleanup`.

Fixes #18658.
2013-04-13 17:23:14 -05:00
Jack Nagel f0f1bdf1a2 doctor: 'raring' => 'ready'
It was pointed out that 'raring' is a rare word can be confusing to
non-native speakers.

Closes #18659, see that for details.
2013-04-12 19:32:23 -05:00
Jack Nagel fd11f138bd doctor: consolidate directory access checks
Also include a writability check for lib.

Closes #18571.
2013-04-12 19:32:02 -05:00
Jiang Xin 885292e16e versions: work for tapped formulae
brew versions is hardcoded to cd to HOMEBREW_REPOSITORY before running
git, and as such fails to report previous versions for any formulae
from a tapped repository.

Add two new private methods repository and entry_name to replace the
hardcoded HOMEBREW_REPOSITORY and formula path, and brew versions
work for both builtin and tapped formulae.

Closes #12356.
Closes #19069.

Reported-by: Misty De Meo <mistydemeo@gmail.com>
Suggested-by: Jack Nagel <jacknagel@gmail.com>
Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-04-11 23:45:15 -05:00
Geoff Petrie 222b9ebc1b doctor: suggest brew update in outdated warning
Closes #19106.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-04-11 02:12:59 -05:00
Jack Nagel 0e8ed301a5 link: eliminate naked rescue 2013-04-10 12:02:35 -05:00