4907 Commits

Author SHA1 Message Date
Jack Nagel
9e8da81302 doctor: try to detect osx-gcc-installer
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-08 11:51:51 -06:00
Jack Nagel
a743f8d862 create: homepage comes before url and checksum
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-06 17:19:54 -06:00
Jack Nagel
1a3a1249bf Warn the user of required arguments
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-04 00:27:05 -06:00
Adam Vandenberg
7ed76725c4 uses: do nothing if no args 2012-02-03 21:40:15 -08:00
Adam Vandenberg
8fe17772bb Show which Perl, Python and Ruby are in the path. 2012-02-02 19:10:56 -08:00
Misty De Meo
706da00b72 doctor: remove gcc-4.2 warning on Xcode 4.2+
Re: Homebrew/homebrew#9925, many others.
2012-02-02 14:08:49 -06:00
Jack Nagel
4ce8bdb32c prune: remove info dir entries for pruned files
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-01 22:52:15 -06:00
Jack Nagel
59458eac51 link: add missing newline in verbose mode
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-01 22:52:14 -06:00
Jack Nagel
66388b7a43 create: punt on bad URLs
When we can't detect a name from the URL, just ask the user.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-31 17:57:20 -06:00
Jack Nagel
8809c85cc3 versions: ignore NameError and ArgumentError
Fixes Homebrew/homebrew#9856.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-29 16:00:27 -06:00
Adam Vandenberg
62cfa49082 audit: make boost-jam a build-time dependency 2012-01-28 12:50:45 -08:00
Jack Nagel
8944cc6b66 versions: fix up error handling
Now we handle some things more explicitly and in the process get rid of
the blanket rescue on the mktemp block, which is something of an
antipattern.

By unloading the class *after* determining the version, we avoid the
case where the class had previously been unloaded but Formula.factory
failed, and trying to unload the nonexistent class results in a
NameError. Doing it this way, we avoid having to rescue NameError and
thereby avoid hiding other cases where it may occur.

We also rescue TypeError which gets us past a few more bad formula in
the history in some instances.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-27 03:40:24 -06:00
Jack Nagel
d10f2afbac versions: silence 'aka' warning and syntax errors
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-26 23:02:18 -06:00
Jack Nagel
ab19242d04 audit: reorganize some checks
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-25 22:41:53 -06:00
Jack Nagel
c36561f450 audit: make devel check more specific
There are a few false positives where the string 'devel' occurs in other
contexts.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-25 22:39:13 -06:00
Misty De Meo
d121bcdada Add devel to the DSL, + stable and bottle blocks
This commit adds a `devel` entry to the DSL, allowing formulae to
specify an unstable branch.

`devel` takes a block, which should contain standard `url` and `md5`
fields (and `version`, if necessary). This must come after the standard
DSL fields.

This commit also migrates over all formulae currently using `devel` to
the new syntax, as well as formulae which used `head` for non-VCS urls.

The new syntax is also available for `stable` and `bottle`. `stable` is
an option alongside the old syntax. `bottle` replaces the old syntax.

Note that the @stable ivar in Formula has been renamed to @standard,
and the @bottle ivar has been renamed to @bottle_url.

Closes Homebrew/homebrew#9735.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
2012-01-25 21:45:19 -06:00
Jack Nagel
c94e8b380f doctor: reset should be done in HOMEBREW_REPOSITORY
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-24 19:59:24 -06:00
Mike McQuaid
ab31e50574 Make brew doctor reset instructions clearer.
Fixes Homebrew/homebrew#9739.
2012-01-24 19:36:10 +00:00
Dylan Smith
66fbb607fd versions: don't print 'nil' when stdout is not a tty
Closes Homebrew/homebrew#8960.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-24 12:21:08 -06:00
Jack Nagel
cf16987845 audit: check for mercurial dependency
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-17 21:57:13 -06:00
Misty De Meo
8d100a0508 search: return results while parsing
Instead of returning a full list of results after parsing, yield and
print each result as it's found for a snappier user experience.

Closes Homebrew/homebrew#9576.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
2012-01-13 22:31:55 -06:00
Max Howell
6626966ddd Use the basename of which_editor
I had EDITOR set to /usr/local/bin/mate set and got the whole of /usr/local opened in TextMate which takes fricking forever!
2012-01-14 02:40:43 +00:00
Jack Nagel
6d1ef8d9ca search: don't try to escape nil
Fixes Homebrew/homebrew#9575.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-12 18:55:16 -06:00
Jack Nagel
e9a0f24ccb versions: use the actual class name when unloading
And document a bit more why this hack is present.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-12 01:16:02 -06:00
Jack Nagel
79439626b5 search: return matches from open pull requests
When search can't find any local results, hit the GitHub API and search
the titles of pending pull requests. This will help people find the many
proposed formulae and prevent them from wasting time duplicating them.

Closes Homebrew/homebrew#9018.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-11 21:11:53 -06:00
Jack Nagel
d106cfed06 Make MacOS.clang_build_version more useful
Let's choose the first \d{2,} as the build number, as it is the most
likely to indicate significant changes, and we need something to use for
comparison when selecting compilers.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-11 02:19:09 -06:00
Jack Nagel
5bfd8faf90 versions: unload old class before obtaining version
This is silly, but I am no Rubyist and I don't have time to
figure out why Formula.factory(foo).url works as expected but
Formula.factory(foo).version does not.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-06 22:07:45 -06:00
Jack Nagel
f3f04e595d versions: enable '--compact' output
This will be useful for shell tab completion when something like `brew
install <formula> --version <version>` is implemented.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-06 14:51:15 -06:00
Jack Nagel
016a508c7a versions: determine version from a Formula instance
Rather than regex the output of `git show <rev>:<path>`, we write the
output of `git cat-file blog <rev>:<path>` to a temporary file, and then
operate on it just as we would a normal formula.

I haven't observed any speed difference. `git cat-file blob` is faster
than `git show`, but the "slow part" is still the git-rev-list
invocation. But really it's pretty fast overall.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-01-06 14:51:15 -06: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
198135e8c0 audit: do not complain about --32-bit 2012-01-02 14:58:15 -08:00
Jack Nagel
d7c1d355f1 brew --env: respect --universal
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-31 21:22:22 -06:00
Jack Nagel
9c83af341f audit: check for trailing newline
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-31 00:05:25 -06:00
Jack Nagel
66dcfcd8cc doctor: clean up check_git_status
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-28 19:55:02 -06:00
Jack Nagel
647e7f1126 config: prettify sha method
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-28 19:54:59 -06:00
Adam Vandenberg
e416bd1115 audit: remove --strict 2011-12-21 14:52:15 -08:00
Adam Vandenberg
4b7b2a17da Clean up --config 2011-12-21 10:47:44 -08:00
Adam Vandenberg
fca07369ab Omit empty caveats 2011-12-20 20:11:54 -08:00
Adam Vandenberg
e65649aeb0 --HEAD checks
* Force --HEAD for head-only installs
* Don't allow --HEAD for stable-only formulae
2011-12-18 16:24:56 -08:00
Adam Vandenberg
a68152fc7d Audit: warn about head-only formulae 2011-12-18 16:24:56 -08:00
Adam Vandenberg
807ed36129 doctor: check for Enthought Python 2011-12-18 08:36:44 -08:00
Jack Nagel
fa586cd436 doctor: normalize representation of env variables
Current warnings contain a mix of variable names with a '$' prefix and
without; most documentation omits the '$', so drop it.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-16 20:34:30 -06:00
Jack Nagel
9f4f23a7f4 doctor: fix a couple of git-related checks
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-16 20:34:17 -06:00
Jack Nagel
7df7bd6a48 --env: dump a few more environment variables
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-16 19:47:37 -06:00
Adam Vandenberg
62e1dd8bd5 Enable 'brew edit' for non-Textmate editors. 2011-12-16 14:27:58 -08:00
Jack Nagel
e4bd231680 audit: hard wrap dep warning
The warning is lengthy, and usually wraps on 80-column terminals.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-15 16:59:02 -06:00
Adam Vandenberg
db02ad1acc Idioms 2011-12-08 21:32:58 -08:00
Jack Nagel
18bdd72827 audit: check for hard-coded compilers
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-12-08 23:08:42 -06:00
Misty De Meo
ea4d1f6b7b Restore --force behaviour in brew-install
Fixes Homebrew/homebrew#8933.
Closes Homebrew/homebrew#8936.

Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
2011-12-02 09:36:38 -08:00