1319 Commits

Author SHA1 Message Date
Max Howell
39453f5a9d Auto-substitute certain variables in DATA patches
HOMEBREW_PREFIX for example.
2011-08-24 22:30:43 +01:00
Max Howell
4f4d70d457 Prettier brew uses output (columnate) 2011-08-24 22:30:43 +01:00
Max Howell
42cc28597c HOMEBREW_CURL_ARGS so that tests can be more silent 2011-08-24 22:30:43 +01:00
Max Howell
9713bb76b0 oh1 stdout display function 2011-08-24 22:30:42 +01:00
Max Howell
31885c2a99 Constants that are used once are dumb
It just means nobody knows what is being done without scrolling up and down, up and down the file like a doofus on a pogo stick.
2011-08-24 22:30:42 +01:00
Max Howell
e9aaef0e25 Revise cleanup text, we're removing, not uninstalling 2011-08-24 22:30:42 +01:00
Dave Bayer
84eae3c425 Fix uninstall.rb brew remove --force "Directory not empty" error
Finder activity such as moving the position of an icon can create an unexpected
.DS_Store file in a Cellar directory. This causes `brew remove --force` to throw
an error that is reported as

Error: Directory not empty - /usr/local/Cellar/<formula>

This fix avoids that error, by calling rmtree rather than rmdir.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-08-22 20:26:53 -07:00
Max Howell
471dc987e5 Specify that they are symlinks 2011-08-22 10:26:01 +01:00
Max Howell
79d78bf933 Blacklist MacRuby
For now we don't support this kind of thing because our formula is a worse option, even though you have to update it yourself.

Closes Homebrew/homebrew#6174
2011-08-19 16:01:39 +01:00
Max Howell
df113d3ce6 Only error out for sudo brew install
Note this only happens if Homebrew is *not* installed sudo. Which is most of the time true.

Fixes Homebrew/homebrew#6899
2011-08-17 12:30:21 +01: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
Adam Vandenberg
6666494551 brew doctor: do not check TMPDIR if it is not set 2011-08-07 10:01:52 -07:00
Max Howell
554147fa99 Reset --hard after the first git init
We don't know what revision the tarball was when homebrew was installed, so all we can do really is hard reset. In theory some set of git commands should suffice, but apparently --soft and --mixed resets ended up putting stuff in the index which would break subsequent `brew updates`.

Fixes Homebrew/homebrew#6851
2011-08-06 11:11:06 +01:00
CharlieRoot
c76ae1a94f Fix Xcode 4 compiler paths for --use-gcc
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-08-04 10:07:08 -07:00
Max Howell
48501e8e1f Prettier brew versions output 2011-08-02 14:45:37 +01:00
Max Howell
f576cae37a Bump copyright year 2011-08-02 14:45:26 +01:00
Max Howell
cb049409e5 Fix brew doctor if sbin directory doesn't exist 2011-08-02 14:45:03 +01:00
Jack Nagel
fd6c9833c6 Fix brew update local changes bug
Users were seeing local changes in their repository after updating, even
though they had made no local changes.

The repository setup sequence should use `git reset --soft` rather than
vanilla `git reset`, which defaults to '--mixed'. '--soft' updates
_only_ HEAD, leaving the index as-is, allowing future incantations of
`brew update` to proceed without errors.

Fixes Homebrew/homebrew#6732.
2011-08-02 13:21:06 +01:00
Max Howell
616b52e627 Oops, show proper git checkout command 2011-08-02 12:58:16 +01:00
Max Howell
18a54259e9 Improvements to brew versions
The output happens as it is determined, rather than all at once, which is preferable for CLI commands. This meant I had to hard-code the left-justification.

The pre-amble warning is removed. Instead the command outputs the git checkout command for each she that you can type to get that old formula.

I decided that reseting the one file will work 99% of the time and that it is too risky to reset the whole repo, this will roll-back bug fixes. Instead we should add functionality to compat/ in order to support old formula as required. Sometimes deps may have to be rolled-back too, but the user will have to figure this out on an ad-hoc basis. We are assuming a failure sophisticated user anyway, one who would like to get old versions of stuff.

I moved most of the functions into Formula since IMO this makes more conceptual sense.

I made the she get abbreviated by git (using --abbrev-commit) itself so it as short as can be.
2011-08-02 12:34:33 +01:00
Max Howell
b36dcc4ffd Improve compatibility for old formula
Allow compatibility to be disabled with --no-compat or HOMEBREW_NO_COMPAT environment variable.
2011-08-02 12:22:58 +01:00
Sebastian Staudt
6726fe090f Added new command "versions" 2011-08-02 10:35:30 +01:00
Adam Vandenberg
f30893a968 Fix brew update on Leopard 2011-07-31 10:32:09 -07:00
Mike McQuaid
9289c06299 Don't install bottles in non-default HOMEBREW_PREFIX. 2011-07-31 11:47:14 +01:00
Adam Vandenberg
733e280e61 fix doctor on 10.5 2011-07-30 22:24:19 -07:00
Adam Vandenberg
0818189b5d Fix stripping of keg-only reasons 2011-07-30 10:11:35 -07:00
Max Howell
7e2411eb4d Remove "boring" args from the pretty_args only
Dumb mistake. Sorry.

Closes Homebrew/homebrew#6722
2011-07-30 11:20:23 +01:00
Max Howell
71cc478a86 Strip keg_only? text to avoid double newlines 2011-07-30 11:04:11 +01:00
Max Howell
630c77a362 Exclude brew manpages from unbrewed. 2011-07-30 11:04:04 +01:00
Max Howell
1cfad8f502 Don't abort if /usr/local is not writable
Since this is our new policy for /usr/local.
2011-07-30 11:03:34 +01:00
Mike McQuaid
81c7ec9933 Build from source (for now) unless on Lion.
Longer-term we'll try and use install_name_tool to fix Lion
bottles so they run fine on 10.5 and/or 10.6.

Closes Homebrew/homebrew#6699.
2011-07-29 18:36:47 +01:00
Adam Vandenberg
8c50cb54c0 audit: make version checks strict only 2011-07-29 08:34:00 -07:00
Max Howell
76745610ec Emphasise the consequence of not installing to /usr/local 2011-07-29 15:21:10 +01:00
Max Howell
01a779655c Writability for /usr/local is no longer required
Provided the user installed with our installer anyway. It creates all the directories that Homebrew will need during its life thus negating the need for root writability.
2011-07-29 14:56:59 +01:00
Max Howell
98ffbeb8f5 Make the check for a valid git repo better
Because the new installer creates the .git directory when it installs.
2011-07-29 14:55:41 +01:00
Max Howell
36ce83fd8d Don't mention the sbin PATH issue unless files are there
Because the new installer will always create /usr/local/sbin. Because we must keep /usr/local root:wheel unless we want to be considered bad citizens.
2011-07-29 14:54:42 +01:00
Max Howell
924f92300f Fix cache extension for github tarballs 2011-07-29 11:58:41 +01:00
Max Howell
3cda43a681 Don’t display boring configure arguments 2011-07-29 11:58:41 +01:00
risk
a10aa12f29 check for a valid $TMPDIR path in brew doctor
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-28 19:50:39 -07:00
Trevor Wennblom
55791d4c10 Coerce flags to an array in remove_make_var!
This is needed for Ruby 1.9.x compatibility, but we still don't support
running Homebrew with anything other than a system provided 1.8.[67].

Fixes Homebrew/homebrew#6546

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-27 17:38:26 -07:00
Samuel Cochran
e3e7831b48 Add MacOS.lion? for MACOS_VERSION == 10.7
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-27 08:16:16 -07:00
Max Howell
72889ea6a8 Set origin remote URL when updating git clones
Thus the url we use can change.

This only works provided the urls both contain git repos with the same blobs. But this should always be true.
2011-07-27 12:51:16 +01:00
Max Howell
f3702b475b Raise if mirror can’t be determined
Adjust mirror ohai slightly.
2011-07-27 10:56:59 +01:00
Jan Lehnardt
c576f4088c Detect Apache mirror system and parse out the closest mirror.
All Apache Formulae should be updated to use the closer.vgi script
to specify downloads rather than a random mirror that could be out
of date or compromised. Apache's closer.cgi does periodic health
checks.

The base URL for the mirror system is

  http://www.apache.org/dyn/closer.cgi?path=#{filepath}

e.g.:

  http://www.apache.org/dyn/closer.cgi?path=/couchdb/1.0.3/apache-couchdb-1.0.3.tar.gz

Note: The addition of the "Actually downloading..." message is sub-optimal
as the message should probably be emitted in _fetch() rather than fetch(),
but I didn't want to change the way Homebrew works today, so I'm leaving
this for mxcl & team to sort out or adopt :)
2011-07-27 09:48:35 +01:00
Adam Vandenberg
e2b21b0b4a Fix brew doctor when no Xcode is detected. 2011-07-26 16:01:30 -07:00
Jack Nagel
5b06a27e99 doctor: be more forgiving about GREP_OPTIONS
Currently, `brew doctor` complains about GREP_OPTIONS being set,
regardless of its value. The cmake formula, for which this check was
introduced, is more specific about what actually makes it fail.

GREP_OPTIONS='--color=auto' will not cause the build to fail, so don't
warn about this.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-25 16:25:44 -07:00
Brant Bobby
113eaf26e4 Fix typo in brew doctor command
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-22 11:47:13 -07:00
Charlie Sharpsteen
fbff2ee853 Retire check for GCC 4.0 under XCode 4.x
XCode 4.x only includes GCC 4.2. Therefore, having `brew doctor` report that
GCC 4.0 is missing only spreads fear, uncertainty and doubt over a situation
that is status quo.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-21 08:10:33 -07:00
Mislav Marohnić
f0eab140f8 doctor: don't report wrong location of autoconf if it's missing
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-10 12:18:55 -07:00
Austin Seipp
567711ed74 sandybridge hardware identifier for brew --config
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-07-05 09:38:41 -07:00