Commit Graph
1537 Commits
Author SHA1 Message Date
Charlie Sharpsteen 09c2a69f89 patches.rb: Fix warning thrown by Ruby 1.8.6
Need to be consistent with use of parenthesis in functions.
2012-04-04 08:28:15 -07:00
Mike McQuaid 137bb03389 Populate empty mirror_list for bottles.
Fixes #11434.
2012-04-04 20:50:22 +10:00
Mike McQuaid 4864b1ba17 Use current bottle versions to calculate new ones. 2012-04-04 15:44:51 +10:00
Rory O’Kane f00c90b552 doctor: fix typos
Closes #11418.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-03 16:21:01 -05:00
Jack Nagel f66238ba13 fetch: don't display cached location twice
The download strategy will print the cached location if we've already
fetched it, so avoid printing redundant information.

Also just "puts" it instead of using a second `ohai` line.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-02 21:04:30 -05:00
Mike McQuaid e827884e04 Version bottles. 2012-04-03 11:43:41 +10:00
Jack Nagel dae8631c4f Reset compiler when testing fails_with
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-01 14:56:04 -05:00
Jack Nagel b36f59dd3c New fails_with infrastructure
- Formulae can now declare failures on any compiler.
 - FailsWithLLVM and associated formula elements have been moved to
   compat.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-04-01 12:39:59 -05:00
Adam Vandenberg ef416878d5 Show target path when empty 2012-03-30 23:02:43 -07:00
Adam Vandenberg 423a8c34fe install: warn when passed no files
Rationale: we warn when inreplace makes no changes; this is a similar
sort of warning. We expected some list (probably via Dir) to include
some files, but none were found.

Either the list was wrong, or the install can now be omitted.
2012-03-30 22:36:45 -07:00
Jack Nagel c7d9a09a96 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 #11300.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-29 21:30:13 -05:00
Mike McQuaid 48a82e5f02 Exit with bad exit code on command failures. 2012-03-29 18:44:37 +11:00
Mike McQuaid c6d37fb237 brew-bottle doesn't need to specify filenames now. 2012-03-29 18:41:47 +11:00
Diego Plentz 0dd5ad5360 typo
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-03-28 20:02:07 -07:00
Max Howell fe76848a7d Fix brew unlink
Whoops.
2012-03-25 13:09:30 +01:00
Max Howell f372dafd98 Speed-up brew-unlink under certain conditions
This massively speeds up upgrades for certain formula, ie. formula with lots of files that aren't in the directories we link. I found upgrading android took ages before the un-tar step and it was indeed for this reason.
2012-03-25 11:07:30 +01:00
Max Howell 130131524b Search Homebrew/games 2012-03-25 11:06:28 +01:00
Jack Nagel c4b547a861 Fix typo in --config.rb
Closes #11183.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-24 12:11:37 -05:00
Jack Nagel ba85e7563e Parse raw diff output in brew update
Using each_cons() "works", but to report all changes correctly we need
to look at the last elements even after we've looked at the last 3
consecutive elements.

Instead, let's parse each line of the raw diff output using a regexp.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-23 20:39:24 -05:00
Jack Nagel f8fefcc51e Pass the tab to FormulaInstaller
Callers of FormulaInstaller now usually unlink the existing keg prior to
running the installer. However, Tab.for_formula uses the LinkedKeg
record to obtain the tab.

Since we need the tab to persist install options across upgrades, we
must start creating the Tab object before unlinking the old keg and
passing it to the FormulaInstaller.

Fixes #11086.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-23 13:05:08 -05:00
Jack Nagel 40599c3ed5 Detect and display renames in brew update
Renamed formulae will cease to display as an add/delete pair and instead
end up the in the "Renamed" section. In the future we should be able to
take this information and use it to rename existing kegs during updates,
allowing us to rename formulae without breaking upgrades.

Renaming a formula requires renaming the class, so there will be at
least one add/delete pair in the file. Thus, the similarity threshold
for detecting renames is set at 85% to allow a little bit of content
turnover without losing track of the rename.

Closes #11158.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-22 22:15:57 -05:00
Jack Nagel a58497368b Use --verify when querying HEAD
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-22 22:15:57 -05:00
Max Howell 131e19a019 Check tapped before trying to untap
If the tap-formula wasn't symlinked for some reason, don't throw an exception—the job is already done.
2012-03-23 00:16:08 +00:00
Mike McQuaid 5a5462f624 Bottles currently require 64-bit hardware on 10.6. 2012-03-23 09:24:56 +13:00
Mike McQuaid f40fc06da1 Fix broken default bottle URL. 2012-03-23 05:58:14 +13:00
Max Howell 45d9bb28ec Don't double print ln message in verbose mode
Refs #11091.
2012-03-22 09:33:41 +00:00
Adam Vandenberg 6a6e76e2cb brew doctor: check for trailing slashes in path
Having path directories with trailing slashes can cause other false
warnings.

Closes #9986.
2012-03-21 22:03:21 -07:00
Adam Vandenberg bc0f31d911 Patch: expose download_filename 2012-03-21 12:12:10 -07:00
Jack Nagel 0e9eb9e17e Update missing Xcode advice
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-21 12:47:51 -05:00
Jack Nagel d82bfafa79 ENV: reset LD when switching compilers
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-21 12:22:22 -05:00
Jack Nagel f34e48c35c ENV: normalize usage of "self" and "ENV"
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-21 12:22:22 -05:00
Adam Vandenberg e307054cf8 brew fetch: show downloaded path 2012-03-21 09:09:11 -07:00
Adam Vandenberg a4a9a01196 Fix Dependency equality 2012-03-20 22:31:14 -07:00
Adam Vandenberg c9d8528c8c Allow a different package and import name for language deps.
Some times the module to import is different than the module to install
when dealing with external dependencies. This change allows an optional
import name to be specififed when it is different from the module name.

Closes #11078.
2012-03-20 19:43:41 -07:00
janv 84e2a7f596 Generate unique patch filenames
Closes #11098.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-03-20 19:24:58 -07:00
Adam Vandenberg 65cea5e9bb Add tests for patches.rb 2012-03-20 19:24:58 -07:00
Jack Nagel 5a8c2af99b Update Xcode version checks
Closes #11044.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-20 19:06:59 -05:00
Jack Nagel 1d61bb9da2 Update issues URL
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-20 18:48:42 -05:00
Misty De Meo 49ed6413ae Don't try to link info/dir with HOMEBREW_KEEP_INFO
Some formulae have local info/dir files from before 9610ff2, and
attempting to link their info/dir over PREFIX/share/info/dir caused
linking to fail.
2012-03-20 17:00:38 -05:00
Misty De Meo 7b16fc3c4d Fix inappropriate linking of info files
share/info files were always being linked if they existed, regardless of
whether the user had HOMEBREW_KEEP_INFO set. This primarily affects
users with software built before
9610ff2e9e.

This also fixes a bug in Keg#link_dir, in which a file would always be
linked if no argument was passed.
2012-03-20 14:33:46 -05:00
Misty De Meo 452f0ffbf9 Skip linking info/dir
The regexp that handles skipping info files was only skipping
info/*.info files, but several formula would create info/dir files as
well. Since these conflicted with each other, Homebrew would error out
during the linking step.
2012-03-20 11:46:10 -05:00
Jack Nagel dcdc678920 Remove broken puts from verbose brew link
The print wrapper which has its own `puts` broke this line; though with
the changes to `link` it isn't necessary any longer, so just remove it.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-20 11:24:35 -05:00
Max Howell da917ed466 Don't query online for plain brew search 2012-03-20 16:03:27 +00:00
Adam Vandenberg edc8d46506 audit: add tests for patches 2012-03-19 18:50:17 -07:00
Adam Vandenberg 7cafbf94e0 Use Patches 2012-03-19 18:50:17 -07:00
Adam Vandenberg b8196a4103 Add Patches class 2012-03-19 18:50:17 -07:00
Max Howell 109c5eb88b Be more helpful about how to resolve this issue 2012-03-19 14:19:56 +00:00
Max Howell 14fc553ac7 If no formula but multiple kegs, advise resolution
In this case the user will simply have to delete all but one keg in order to use the command that uses ARGV.kegs.

Refs #11050.
2012-03-19 14:17:50 +00:00
Max Howell 45710770a3 Don't error if exact link already exists
If the link already exists exactly (well almost exactly) as we are about to correct it, then it's okay. Otherwise we error out. This is a safe choice, and really, the correct choice too.

This will prevent the tickets like #11050 from occurring.
2012-03-19 12:24:13 +00:00
Max Howell ce082c167c Better error when linking fails
Refs http://stackoverflow.com/questions/9762943

The system ln no longer outputs anything. Though the user can force its output with a --verbose of course. So in cases where it's not the usual of: not writable or existing file, we can ask the user to run with --verbose. I don't particularly like hiding its output, but it just confused the error IMO since it is creating a relative symlink the output was weird every time I've seen it in tickets.

I made a print wrapper so that the brew-link output doesn't get mucked up if an exception is thrown.
2012-03-19 00:28:38 +00:00