If you have a bunch of symlinks and they all point at one file and you use Pathname.install on them all the error checking would fail if the file was moved before the symlinks because the symlinks would then point at a non existent file.
Running `brew cleanup` (with no arguments or multiple arguments) will
run `brew prune` after _every_ cleaned formula, i.e. possibly after
every installed formula.
With this change it will instead only run `prune` after all formulae are
cleaned, and only when no arguments were given to `cleanup`.
Signed-off-by: Max Howell <max@methylblue.com>
ClosesHomebrew/homebrew#743
* Break single test case class into several test cases.
* Fix broken arch test.
* Make update tests optional (seem to only work for mxcl).
* Add more tests.
* Move fixtures to separate folder.
To existing flag value can be specified with "\\1".
To append values to a flag, call with:
s.change_make_var! "THE_FLAG", "\\1 more-flag-values"
The same trick can be used to prepend or surround values as well.
* Instantiate DownloadStrategy instance when creating a formula.
* Rename CurlDownloadStrategy member to clarify what it is for.
* Generate downloaded tarball name in initialize.
If the formula was updated and not yet installed, then cleanup would delete all kegs. Which is most likely not what the user wanted.
Ideally we'd do a version check to figure out which keg is newest. But we don't yet have a function that can determine with accuracy version order.
RubyCocoa is a large dependency, and any large system can cause unexpected errors. In this case the user's system was badly setup and RubyCocoa caused a dynamic loader issue.
We don't use beer_events currently due to other bugs that occurred sporadically with its use. So requiring it is unnecessary. So lets save ourselves trouble.
FixesHomebrew/homebrew#487
Since Homebrew's Library doesn't have to be linked under prefix,
we need to do some extra work in the bash completion script to
support this configuration.
Added a "--repository" option to brew, and updated the completion
script to use paths relative to this location.
CMake ignores the CPPFLAGS and LDFLAGS environment variables. This makes sure CMake finds libraries when homebrew is not installed at /usr/local.
Signed-off-by: Max Howell <max@methylblue.com>
FixesHomebrew/homebrew#242
Not using path.basename for mktemp due to risk of bugs due to incorrect escaping. But mainly, mktemp gives a unique name and this operation is procedural.