456 Commits

Author SHA1 Message Date
Samuel John
e851e88863 brew doctor: Check for CaSe SeNsItIvE fs
Closes Homebrew/homebrew#16658.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2013-01-31 21:48:28 -08:00
Mike McQuaid
27700390b4 Improve brew doctor autocrlf message.
Better version of ed357d.

References Homebrew/homebrew#15711.
References Homebrew/homebrew#17361.
References Homebrew/homebrew#17437.
2013-01-30 21:29:19 -08:00
Jack Nagel
b6631ac23f doctor: core.autocrlf can be empty
c.f. Homebrew/homebrew#17361.
2013-01-30 01:26:28 -06:00
Mike McQuaid
92a5c765a9 Improve brew doctor autocrlf check.
Closes Homebrew/homebrew#15711.
2013-01-29 17:14:00 -08:00
Misty De Meo
14bb39b898 Don't print git origin check without git repo 2013-01-29 09:48:43 -06:00
Jack Nagel
1ca5b7a204 doctor: fix typo 2013-01-28 23:02:25 -06:00
Sema
667b53ffb0 doctor: fix transposed git command
Closes Homebrew/homebrew#17338.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-01-27 13:17:19 -06:00
Jack Nagel
fe802f05ef missing: ignore unused optional and recommended deps 2013-01-26 12:14:48 -06:00
Adam Vandenberg
2c6a7bdca8 Check ownership of logs folder
Closes Homebrew/homebrew#16607.
2013-01-23 20:12:55 -08:00
Jack Nagel
6b59e610f0 doctor: loosen git origin regexp
If the repository is set up by `brew update`, the remote URL is
https://github.com/mxcl/homebrew.git, but if it is set up by the install
script, the .git suffix is omitted.
2013-01-17 21:46:02 -06:00
Simon Sigurdhsson
8000fb807f Doctor check for origin
Added checks on doctor.rb for:

* Missing git origin
* git origin not pointing at mxcl/homebrew

Tests use `git config --get remote.origin.url`.
Also added printout of origin to --config.rb.

Fixes Homebrew/homebrew#14399.
Closes Homebrew/homebrew#17117.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-01-17 17:18:15 -06:00
Misty De Meo
05772f8ccf doctor: use -V for python version
`python --version` doesn't work in some (very) old versions of
python. While I doubt this is going to come up very often, it's
theoretically possible someone has an old python first in their
path. (python -V works on all versions I'm aware of, including
python3, and comes before --version in the --help anyway.)

Also skips the warning in case the regexp matches nothing, which
probably shouldn't happen. But if it does we shouldn't produce the
wrong warning.
2013-01-09 17:09:28 -06:00
Jack Nagel
e3068f631a Prune LinkedKegs relative to correct path
Fixes Homebrew/homebrew#16948.
2013-01-08 11:03:13 -06:00
Jack Nagel
d2d4813a07 doctor: add helper for printing file listings 2012-12-22 12:48:53 -06:00
Jack Nagel
4e9128aa6c doctor: f.prefix is already a pathname 2012-12-21 19:33:24 -06:00
Jack Nagel
2b47739822 doctor: print offending paths in check_for_gettext
c.f. Homebrew/homebrew#16688.
2012-12-21 18:03:24 -06:00
Jack Nagel
847547167a doctor: rename path_folders to paths 2012-12-21 17:16:57 -06:00
Jack Nagel
1780855023 doctor: use a more rubyish conditional 2012-12-21 17:14:01 -06:00
Jack Nagel
73a206a316 doctor: avoid pointless creation of pathname object 2012-12-21 17:12:00 -06:00
Jack Nagel
a64e9e542f doctor: run slowest checks last 2012-12-21 15:15:42 -06:00
Jack Nagel
3dcce70a6a Better reporting for MacPorts/Fink installations
closes Homebrew/homebrew#15853.
2012-12-17 17:18:22 -06:00
Jack Nagel
3589465297 doctor: don't check keg-onlies if cellar doesn't exist 2012-12-08 16:41:31 -06:00
Mike McQuaid
ff356b6192 Whitelist 10.8.2 Supplemental Update static libs.
Fixes Homebrew/homebrew#16215.
2012-11-26 09:41:05 +00:00
Jack Nagel
6c4c37a01f bash completion for doctor checks 2012-11-13 16:49:43 -06:00
Jack Nagel
6b6e22ffae Don't advise XQuartz upgrades for system X11
Yeah, yeah. The XQuartz/X11 stuff is confusing.
2012-11-12 19:48:09 -06:00
Adam Vandenberg
847baa9e14 doctor checks XQuartz version
Closes Homebrew/homebrew#14182.
2012-11-11 12:33:50 -08:00
Jack Nagel
1cb59ea5fd Fix curlrc existence check
Enumerable#one? is not available under Ruby 1.8.6. Further, we really
want #any? here, as setting both HOME and CURL_HOME can trigger a false
negative.

Fixes Homebrew/homebrew#15883.
2012-11-06 19:02:02 -06:00
Jack Nagel
f8183d9510 Hoist top-level directory list into a constant 2012-11-06 12:32:09 -06:00
Charlie Sharpsteen
c92971f475 doctor: Remove fuse.pc from the whitelist
Having a third-party `fuse.pc` file will conflict with the `fuse4x` formula.
2012-11-03 15:44:51 -07:00
Max Howell
f6091b1c85 Specify where to get the CLT package 2012-10-28 10:52:07 -04:00
Stephen Nelson
e7a9f6eb89 Homebrew should not ignore curlrc
Added doctor check for .curlrc rather than silently ignoring it (#13836).

Closes Homebrew/homebrew#15419.

Signed-off-by: Max Howell <mxcl@me.com>

Removed test in doctor where it actually curl'd a file. It's enough to warn if the curlrc exists. I understand people want to remove the warnings, but the point in the doctor is to help diagnose and not to be some ramification of your UNIX system.
2012-10-28 10:52:07 -04:00
Adam Vandenberg
babf25af1a doctor: check that Xcode prefix actually exists
Closes Homebrew/homebrew#14373.
2012-10-24 11:16:57 -07:00
Adam Vandenberg
d88158b9fe doctor: fix iconv dylib name 2012-10-03 12:41:20 -07:00
Max Howell
82c58bb615 Fix doctor hanging if xcode-select is bad
Also fix typo in the superenv DEVELOPER_DIR set detection code.
2012-09-24 08:49:58 -04:00
Misty De Meo
3473bbc010 Make check for stray developer dir more specific
It looks like there can be harmless stuff leftover in
/Developer/Library, even after Xcode uninstalls older versions. The
existence of the uninstall-developer-folder script should be a better
indicator.

Fixes Homebrew/homebrew#14970.
2012-09-16 14:07:38 -05:00
Misty De Meo
e8c372a315 Skip standard compilers check for unknown Xcode
Rescuing false on the StandardCompilers map meant that the doctor
check assumed that the compilers were incorrect, not merely
unknown.

Instead, skip the check and return nil for unknown Xcode; nil
should be interpreted as "dunno", instead of "true" or "false",
and the doctor check no longer prints on nil.
2012-09-14 17:11:51 -05:00
Misty De Meo
0329307770 doctor: Add check for stray pre-4.3 Xcode files
/Developer/Library shouldn't exist if all the remnants of old
Xcode versions have been uninstalled, and tends to cause problems if
it's kept alongside modern Xcode.

"uninstall-developer-folder" should only remove /Developer/Library.
2012-09-13 10:18:21 -05:00
Jack Nagel
b20c35cf0e doctor: ignore case when checking PATH for config scripts
Fixes Homebrew/homebrew#14752.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-09-06 10:05:49 -05:00
Max Howell
b98c4792d0 Doctor check for unlicensed Xcode
Checking the license text is probably the most future proofed method. Though for future reference other possible methods are listed in the below ticket.

Closes Homebrew/homebrew#14558.
2012-08-31 10:22:11 -04:00
Max Howell
b834027b17 Doctor suggest git clean -f if unstaged files
This is safe, I tested various scenarios, including Homebrew installed in ~. The only files that are removed are unexpected files in Homebrew's already managed directories.
2012-08-29 12:41:37 -04:00
Max Howell
9274f7cda1 Formula.Enumerable
Deprecated Formula.all, replaced usage with more appropriate enumerable options. Just check out how much nicer `brew audit` runs now.
2012-08-21 12:09:05 -04:00
Max Howell
c5266654ff In fact, there are 2 xcode-select files to delete 2012-08-21 12:09:04 -04:00
Jack Nagel
d95f467362 Refactor brew missing
The heuristic for determining whether something is installed changes
from "f.installed?" to "f.rack.exist? and f.rack.subdirs.length > 0" in
order to properly consider outdated formulae.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-08-18 11:25:59 -05:00
Jack Nagel
166a9ba0ed Deprecate MacOS.version? style methods
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-08-18 11:25:59 -05:00
Max Howell
6ffe27fa98 Stop warning about CLT w/o Xcode
Also made the latest_versions checks smarter. Hopefully correct too.
2012-08-17 17:18:17 -04:00
Max Howell
3dec84de8a Improve libiconv diagnostic and suggestion
This is coming up a lot at the moment, so here is an attempt to be more helpful.
2012-08-14 11:46:18 -04:00
Max Howell
fef6d5b8c0 brew doctor -D (diagnostic-dump)
-D is now the switch for diagnostic-dumps. Let it be so.

Shows how long each doctor method takes in a sorted table at end. I used this to move the two slowest methods to the end of the doctor run so that as much useful information can be shown as quickly as possible.

Also now possible to specify on command line which tests should be run.
2012-08-14 11:46:18 -04:00
Jack Nagel
c9f824b54a Make Set available globally
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-08-12 00:58:31 -05:00
Brandon Black
bcde6432f3 Fix issues with writable? detection in brew doctor
Closes Homebrew/homebrew#13689.

Signed-off-by: Max Howell <mxcl@me.com>

There are subtle distinctions between writable? and writable_real? we don't
understand precisely why we need this, but it fixes the bugs :/
2012-08-06 22:02:38 -04:00
Max Howell
1f62284384 Restore check for broken xcode-select path
How did this get removed? Had a bug today where user had this but no doctor check so I was confused!
2012-08-06 19:28:39 -04:00