aboutsummaryrefslogtreecommitdiffstats
path: root/Library
AgeCommit message (Collapse)Author
2011-11-28Document 'install --devel'Jack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-27Move brew-depstree into `brew deps --tree`Jack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-27formula.rb: Initialize path to nil or a PathnameCharlie Sharpsteen
For consistency, ensure that the `path` member of formula objects is always a `Pathname`.
2011-11-27Fix array concatenation in ARGV.filter_for_dependenciesCharlie Sharpsteen
Gah. This was supposed to be in the last commit, but I forgot to `--amend` it.
2011-11-27Don't suppress `--verbose` while installing depsCharlie Sharpsteen
Unless the `--quieter` flag is passed. Closes Homebrew/homebrew#8723.
2011-11-27Suppress `--devel` while installing dependenciesCharlie Sharpsteen
Unless the dependency is explicitly passed to `brew install --devel`.
2011-11-27Re-work ARGV filtering to properly handle --HEADCharlie Sharpsteen
Previously, stripping arguments like `--HEAD` for dependencies failed because that flag affects the installation prefix encoded into formula objects. The previous implementation of `ARGV` filtering tried to contain all changes to a single method call before the `FormulaInstaller` forks. This update spreads things out a bit: - The Homebrew `ARGV` extension adds a new method, `filter_for_dependencies` which strips flags like `--HEAD`, yields to a block, then restores the original contents of ARGV. - The `explicitly_requested?` test, which returns true or false depending on if a formula object is a member of `ARGV.formulae`, is now a method of `Formula` objects. - `FormulaInstaller` objects now execute the installation of dependencies inside an `ARGV.filter_for_dependencies` block if the dependency was `explicitly_requested?`. Fixes Homebrew/homebrew#8668. Closes Homebrew/homebrew#7724.
2011-11-27manpage: remove audit's '--strict' optionJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-27audit: remove --strictAdam Vandenberg
2011-11-26doctor: remove terminal width check for curlJack Nagel
This ended up being noise for some users. We need a better set of steps to trigger the bug in order to create a good doctor check; patches welcome from users who are encountering this issue. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-26doctor: use newer gcc version methodsJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-26Reset to remote HEAD when updating git clonesJack Nagel
Git checkouts that do not specify a branch should always reset to the remote's HEAD, as some remotes have HEAD set to 'unstable' or some other non-master branch. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-25Utils: update gcc version detection logicMisty De Meo
Homebrew was attempting to check the version of gcc-4.0 and gcc-4.2 even if they don't exist, causing `doctor` and `--config` to throw nasty errors. Also fixes the broken missing gcc-4.2 detection, which was confusing Xcode 4.2 users. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-11-25brew-config: remove recommended compiler versionsAdam Vandenberg
The recommended compiler versions printed from `brew-config` are out of date and misleading. The recommendation is always "Run the latest version of Xcode available for your platform".
2011-11-25Detect 2-digit clang build versionsMisty De Meo
Xcode 3.2.6's build of clang is 77, which wasn't being matched by the clang_build_version regexp. Closes Homebrew/homebrew#8796. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-25Display clang version in --config outputJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-25Add utility methods to determine clang versionJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-25doctor: remove outdated XCode version referenceJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-25Parse `compiler --version` instead of -vJack Nagel
For GCC and LLVM-GCC, '-v' is not a synonym for --version. When run without any other options or arguments, it gives similar output, but it is better to just parse the (terser) --version output. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-23formula_installer.rb: Improve receipt checkCharlie Sharpsteen
Using `f.installed?` instead of `f.prefix.exist?` ensures something was created by the installation step before the install receipt is written.
2011-11-23audit: check for MacPorts patches from trunkJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-23ENV.rb: Fix typo in Fortran environment variablesCharlie Sharpsteen
`FFFLAGS` should be `FFLAGS`.
2011-11-22options: treat outdated brews as installedJack Nagel
`brew options --installed` will now "do the right thing". There is getting to be a small but noticeable amount of code duplication among commands that take options like "--installed" or "--all"; it may be worth factoring this out into a method that will return a collection of formula objects based on the options that are passed. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-21Define and use ARGV.build_devel?Jack Nagel
Often it is useful to provide a development build in addition to the stable release or HEAD download. Signed-off-by: Jack Nagel <jacknagel@gmail.com> Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-11-21formula_installer.rb: Hotfix for head installsCharlie Sharpsteen
For now, don't strip `--HEAD` from `ARGV` prior to forking for install. Currently this doesn't work because the formula object the installer is acting on has its `prefix` set while under the influence of `--HEAD`. So, the installer bails out when it sees that nothing is installed to `f.prefix`. This is a hotfix for issue Homebrew/homebrew#8668 to allow formulae to keep building. A proper fix should ensure that formula installers are operating on objects with appropriately set `prefix` values.
2011-11-21audit.rb: Check version strings by defaultCharlie Sharpsteen
Tired of telling people that version numbers are redundant. Just check it by default since the `--strict` flag to `brew audit` is not well advertised.
2011-11-20Delete temp directory created during brew doctorJonathan Grochowski
Running brew doctor creates a temporary directory in $HOMEBREW_TEMP or /tmp but does not clean it up afterwards. This patch deletes the directory created to prevent polluting $HOMEBREW_TEMP or /tmp with empty directories. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-11-18audit: check for ARGV.flag? in formulaeJack Nagel
We don't want single letter options like '-v' or '-d' to unintentionally trigger formula-specific options. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-16Don't include receipt in `brew list` outputCharlie Sharpsteen
Fixes Homebrew/homebrew#8615.
2011-11-16Don't write receipt for empty installsCharlie Sharpsteen
Fixes Homebrew/homebrew#8616.
2011-11-15audit: don't check duplicate URLsJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-15Mercurial 1.9.3Adam Vandenberg
2011-11-14Add --fresh option to brew installCharlie Sharpsteen
When invoked, this option will ensure brew doesn't re-use any options from previous installs of a formula.
2011-11-14Hotfix for filtered_args breaking brew upgradeCharlie Sharpsteen
The `filtered_args` method added to the `FormulaInstaller` makes a call `ARGV.formulae`. Unfortunately, `ARGV.formulae` will throw a `FormulaUnspecifiedError` instead of returning an empty list. This patch avoids the issue by checking `ARGV.named.empty?` before calling `ARGV.formulae`. Fixes Homebrew/homebrew#8576.
2011-11-13info: display used options for installed formulaeJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-13Hardwire multi_json backendCharlie Sharpsteen
The `multi_json` gem dynamically selects a JSON implementation from a list of candidates. Since we cannot control which gems are installed on a user's machine, this patch hardwires `multi_json` to use the included copy of `ok_json`. `ok_json` is a pure-Ruby JSON encoder/decoder that is bundled with `multi_json`. `ok_json` may not be as fast as other choices, but speed is not critical for our application. Closes Homebrew/homebrew#8574. Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
2011-11-13Add copyright notice for MultiJsonCharlie Sharpsteen
2011-11-13metadata: Use options from previous installsCharlie Sharpsteen
FormulaInstaller now loads the install recipt of a previous install and appends the `used_options` to ARGV before forking to build. This means `brew upgrade` will "remember" which options were invoked for the last install and re-use them. Fixes Homebrew/homebrew#5250.
2011-11-13metadata: Record installation optionsCharlie Sharpsteen
Adds a new class called `Tab` that acts as a recipt for install options. A `Tab` can be serialized to a JSON file for future reference.
2011-11-13Vendor Library: multi-json 1.0.3Charlie Sharpsteen
Multi-JSON is a library that provides encode/decode support for casting Ruby objects to JSON strings and back again. This version of the library has been tested against ruby versions 1.8.6 and later. Having a JSON encoder/decoder in the toolbox helps now that the GitHub API only returns results in JSON format.
2011-11-13formula_installer.rb: Pre-process ARGV before forkCharlie Sharpsteen
`ARVG` is now filtered before the formula installer forks a new process. This allows a chance to do things like strip out `--HEAD` flags for formulae that weren't explicitly passed as arguments but came in as dependencies. Fixes Homebrew/homebrew#7724.
2011-11-11completion: add __brew_ps1 to annotate $PS1Jack Nagel
It is often useful to be reminded that you are, in fact, in the middle of a debug or interactive install. We provided this reminder in the form of HOMEBREW_DEBUG_INSTALL, but we can make this even easier for the end user to consume by exposing it in the form of a shell function. When HOMEBREW_DEBUG_INSTALL is set, the __brew_ps1() function returns the string "(formula_name|DEBUG)" by default (much like the __git_ps1() output when performing some long-running operation, e.g. "(branch|REBASE-i)". The formatting around "formula_name|DEBUG" can be customized by passing a format string to the function. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-10doctor: check_git_status in correct locationJack Nagel
This would silently fail if HOMEBREW_REPOSITORY != HOMEBREW_PREFIX, which is obviously a valid Homebrew setup. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-10doctor: document curl/terminal width issueJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-10doctor: warn about wide terminalsJack Nagel
A terminal width of 262 or greater can trigger a buffer overflow in curl's progress bar code, resulting in a segfault and aborted downloads. Warn about this. cf Homebrew/homebrew#8521. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-10doctor: minor grammatical fixJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-07cleanup: add an option to perform a 'dry run'Jack Nagel
Sometimes you want to know what `brew cleanup` will do before it actually removes anything. Introduce a '-n' option (chosen to match other UNIX tools) to do this. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-02audit: check for build_universal? calls if --universal unusedOleg Oshmyan
Closes Homebrew/homebrew#8123. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-11-02audit: check for empty sha256 checksumsJack Nagel
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2011-10-24brew-pull: Clarify comment concerning whitespaceCharlie Sharpsteen