362 Commits

Author SHA1 Message Date
Bruce Steedman
8ebddca0fe fix other 10 failing tests - doh 2016-11-12 12:31:35 +00:00
Mike McQuaid
6c9ca906af install: only check fatal development tools checks. 2016-11-05 10:58:39 -04:00
ihatetoregister
12c252855a Added a hint how to link a formula that is installed but not linked 2016-11-05 00:17:02 +01:00
Josh Hagins
c7e6613f7b tap_constants: rename HOMEBREW_CASK_TAP_FORMULA_REGEX
New name is HOMEBREW_CASK_TAP_CASK_REGEX
2016-10-23 21:48:11 -04:00
Markus Reiter
198bf4d3bd Convert puts_columns to puts Formatter.columns. 2016-10-15 17:13:38 +02:00
Markus Reiter
01d87f8107 Don’t use puts_columns if empty? or single item. 2016-10-15 17:13:38 +02:00
Markus Reiter
cafe149780 Merge pull request #1145 from reitermarkus/module-function
Use `module_function` for `Homebrew` module.
2016-10-04 10:31:49 +02:00
Bruce Steedman
62e14ea673 invalid build options - fixed conflicts; rename 2016-10-03 09:42:53 +01:00
Markus Reiter
0ab750bf24 Use module_function for commands. 2016-10-02 00:24:47 +02:00
Mike McQuaid
c699597c4c install: remove not updated warning.
This is no longer relevant after moving to taps/tags and if ever
re-added it should probably target homebrew/core.

Fixes #1194.
2016-10-01 19:42:38 +01:00
Markus Reiter
58e36c7319 Fix Style/GuardClause. 2016-09-24 12:24:35 +02:00
Markus Reiter
a5b11a6a5c Fix Style/GuardClause. 2016-09-23 15:30:07 +02:00
Mike McQuaid
c45119de75 Merge pull request #971 from penman/follow_alias
Make `brew upgrade` and `brew outdated` follow alias changes
2016-09-19 15:22:24 +01:00
Alyssa Ross
c874b4e4c2 install: don't install alias if already installed 2016-09-18 19:58:11 +01:00
Mike McQuaid
3f9cce0a03 Use new "macOS" naming where appropriate.
Not quite a mass replacement as I've used OS X and Mac OS X where
describing specific older versions and added compatibility methods
for things in the DSL.
2016-09-18 19:57:19 +01:00
Mike McQuaid
5d761f651a cmd/install: fix Rubocop warnings. 2016-09-11 17:58:59 +01:00
Mike McQuaid
f1cc1265af Refactor MacOS check_development_tools usage.
Better use the abstraction layer so e.g. Linux could have similarly
fatal checks for these things.
2016-09-07 09:11:06 +01:00
Dominyk Tiller
921aa01576
install: die if Xcode/CLT not up-to-date on prereleases 2016-08-30 05:10:59 +01:00
Misty De Meo
fdf55e77e1 Improve formula not found handling (#96) 2016-08-10 10:37:35 +01:00
Xu Cheng
a8566c9848 various: eliminate the usage of any? (#638)
`any?` is not the opposite of `empty?`. Besides the case that
`[false, nil].any?` will return false, `any?`(O(n)) has much worse
performance than `empty?`(O(1)).
2016-08-05 22:01:32 +08:00
Mike McQuaid
164e46a729 Add missing development_tools requires. 2016-07-29 21:21:02 -06:00
Mike McQuaid
2c792076dc cmd/install: port to generic OS. (#458) 2016-07-08 20:52:07 +01:00
Mike McQuaid
3a127e405e development_tools: add installed? method. (#455) 2016-07-06 11:07:24 +01:00
Mike McQuaid
59074e91d6 diagnostic: more porting to generic OS. (#449) 2016-07-04 18:35:03 +01:00
Mike McQuaid
468ebc5ed5 install: undocument --force-bottle. (#443)
This is a developer-only option I created for testing purposes. It
should not be used by end-users.
2016-07-04 14:03:03 +01:00
Vlad Shablinsky
da06e813c2
cmd/install: use migration_needed?
Closes #411.

Signed-off-by: Xu Cheng <xucheng@me.com>
2016-06-29 21:04:28 +08:00
Zhiming Wang
bc1d5ae4d4 install: fix documentation of --keep-tmp option (#258)
Obvious copy/paste failure in acc9a7ca8554bc2413dee2d6d0f407b3a59c628c.
2016-05-19 08:43:42 +02:00
Jam
a558629654 gist-logs: add proper documentation, improve error handling (#217) 2016-05-09 04:39:22 +02:00
Andrew Janke
d887dd39ec brew install: make -s apply only to given formula, not deps (#205) 2016-05-06 12:02:13 -07:00
Andrew Janke
acc9a7ca85 brew test, install, update-test: add --keep-tmp option
Also enables sandbox for --interactive and --debug use of install
and test, using automatic retention.

Closes #66.

Signed-off-by: Andrew Janke <andrew@apjanke.net>
2016-04-18 12:23:08 -04:00
Martin Afanasjew
94a627d7aa install: handle FormulaClassUnavailableError
Don't search for alternatives if formula was found, but has issues, as
this will create confusing output, particularly for contributors working
on a formula file.
2016-04-17 21:16:01 +02:00
Max Nordlund
fa1fd70a37 Add all the top level comments 2016-04-10 22:59:25 +02:00
Xu Cheng
28f3dae8cd rename CoreFormulaRepository to CoreTap
Core tap will be separated from core code in the near future.
It makes sense to rename it to CoreTap.
2016-03-07 19:43:46 +08:00
Baptiste Fontaine
9f1442db14 doctor: move code away from cmd/
Closes Homebrew/homebrew#47665.

Signed-off-by: Baptiste Fontaine <batifon@yahoo.fr>
2016-01-05 14:33:06 +01:00
Xu Cheng
0f84b976ba move CoreFormulaRepository into separate file
For users whose local brew is at around 2015-06-11 to 2015-08-06,
running `brew update` will emit following error:

  Error: uninitialized constant Formulary::CoreFormulaRepository

This is caused by the same bug described in Homebrew/homebrew#42553.

This commit workarounds this issue and restores `brew update` compatibility
for users mentioned above.

Also cleanup legacy `require "cmd/tap"`.
2015-12-19 22:05:30 +08:00
Josh Hagins
d5de719c2b Do not brew install brew-cask
Refs caskroom/homebrew-cask#15381

Closes Homebrew/homebrew#46845.
2015-12-10 09:32:53 +00:00
Xu Cheng
6e92609cf4 Formulary: use same logic to handle core fully-qualified name 2015-12-09 16:56:59 +08:00
Xu Cheng
48950f2cc0 centralize the logic of handling homebrew- in Tap.fetch
Closes Homebrew/homebrew#46537.

Signed-off-by: Xu Cheng <xucheng@me.com>
2015-12-03 13:46:59 +08:00
Alex Dunn
95bbd8ef02 cmd/install: check before tapping
Changes introduced in dfdc570abcd7c19a7b385c2fe8c6b26b12bca646 were
causing installations using fully-qualified formula names to fail.
2015-11-09 07:25:26 -08:00
Xu Cheng
82689d81f7 use Tap#install 2015-11-09 15:34:20 +08:00
Eric Andrew Lewis
5ec396ed38 install: make search output more intuitive.
Closes Homebrew/homebrew#42222.
Closes Homebrew/homebrew#44892.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2015-10-19 10:16:40 +01:00
Xu Cheng
1ae44d4429 use directory? to check rack existence 2015-10-09 19:06:08 +08:00
Vlad Shablinsky
b68562d941 install: fix if isn't migrated 2015-08-27 13:51:04 +01:00
Misty De Meo
727239e12f Merge bottle install without Xcode branch
Merge branch 'bottle_hooks'
2015-08-21 11:04:22 -07:00
William Woodruff
56795ec1ed Call check_xcode check for CLT, too 2015-08-21 11:02:33 -07:00
William Woodruff
1face808f5 Add guards to calls that would trigger Xcode install requests
add guard in Formula#file_modified? to prevent git popup

add guard in Superenv.bin before calling MacOS::Xcode.version

add guard against missing Xcode/CLT in Xcode.uncached_version

return nil instread of 0 in uncached_version when Xcode/CLT are not present, to distinguish from linuxbrew behavior

checks against pour_bottle? and needs_relocation?, add guard around keg.relocate_install_names to check pour_bottle?/needs_relocation? as well

needs_relocation? becomes skip_relocation?, use cellar attr to indicate relocation instead of does_not_need_relocation

MacOS.can_build? becomes MacOS.has_apple_developer_tools?
2015-08-21 11:02:33 -07:00
William Woodruff
f58506ea6f FormulaInstaller: add prevent_build_flags to eliminate code repetition
remove unneeded definition

change variable in FormulaInstaller.check_build_flags from bf to build_flags
2015-08-21 10:59:35 -07:00
William Woodruff
91e598cf3f Install: add BuildToolsError and BuildFlagsError
Add these new errors, and guards in formula installation and
cmd/{,un,re}install to match, move can_build? to the MacOS module,
flatten conditions, remove redundant can_build? check

reinstate removed (doctor) check
2015-08-21 10:59:09 -07:00
William Woodruff
85187bf6d3 MacOS: update locate_cctool
This becomes MacOS.{install_name_tool,otool}, only do check_xcode if
xcode is installed, otherwise emit a warning
2015-08-21 10:58:13 -07:00
William Woodruff
b46d5de492 Requirements: add CctoolsRequirement
Install it as a dependency unless already satisfied by Xcode.

require cctools_requirement

cctools_requirement should be satisfied by cctools present in opt

add build_env => false to the satify block options in CctoolsRequirement
2015-08-21 10:57:20 -07:00