aboutsummaryrefslogtreecommitdiffstats
path: root/Library
AgeCommit message (Collapse)Author
2016-04-18XQuartz: add Tiger's versionMisty De Meo
2016-04-18XQuartz: support Tiger's prefixMisty De Meo
2016-04-18test-bot: purge non-core taps at start/end of job (#109)Dominyk Tiller
https://github.com/Homebrew/brew/commit/e70a3552d3faddd0afd2535a03c31b8c50be901a seems to have exacerbated the problem where taps stick around and then `brew uses` gets executed on a whole host of taps, which is currently breaking almost every PR for formulae that would be used cross-tap, as well as causing lengthier CI builds. Examples from the last week or so include sqlite, V8, protobuf, and so on. Whilst it may be true that cross-tap formulae failing can show problems that need looking at, a lot of the time the failures are unrelated to the build in question and just leave contributors confused on what needs to be done, or why their PR is failing for something that seems entirely unrelated. You can see the taps failing to vanish locally by doing something like: ``` brew tap homebrew/fuse brew tap homebrew/versions cd $(brew --prefix) && git clean -ffdx --exclude=/Library/Taps/ brew tap ... homebrew/core homebrew/fuse homebrew/versions ``` This is a very simple proposal to handle the problem, but there's no real reason I couldn't write this functionality into untap itself and then we call that in test-bot. Just didn't necessarily want to jump immediately to expanding the untap command to solve what is more-or-less a CI problem.
2016-04-18brew test, install, update-test: add --keep-tmp optionAndrew Janke
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-18brew.sh: error out if no Ruby found.Mike McQuaid
This is a nicer error message than the `exec` failing at a later stage.
2016-04-18brew.rb: don't show help for 'brew <command> help'Martin Afanasjew
Showing help makes sense for `brew help <command>`, but showing it for `brew <command> help` is undesirable and prevents all commands from accepting a named argument `help` (formula, tap, file name, etc.). All other help flags are still detected before *and* after the command. Closes #103. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-18ARGV: remove unused 'usage' methodMartin Afanasjew
Also remove related helper method `Homebrew.help_s`.
2016-04-18help: handle help output (move from 'brew.rb')Martin Afanasjew
Keep the footprint of `brew.rb` small. Handle fetching/displaying an appropriate help text (taking into account various external conditions) in the `help` command.
2016-04-17tests: test FormulaClassUnavailableErrorMartin Afanasjew
Closes #101. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-17install: handle FormulaClassUnavailableErrorMartin Afanasjew
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-17formulary: use FormulaClassUnavailableErrorMartin Afanasjew
Present a more helpful error message if a formula file was loaded, but the class(es) therein didn't match the expected formula class name.
2016-04-17exceptions: add FormulaClassUnavailableErrorMartin Afanasjew
2016-04-17manpages: add editing instructions to ERB templateMartin Afanasjew
Closes #102. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-17man: replace split header/footer with ERB templateMartin Afanasjew
2016-04-17manpages: remove no longer needed 'brew.1.md'Martin Afanasjew
Changes to the man page are made in `header.1.md`, `footer.1.md`, or the documentation comment block in the respective command file. Remove old Markdown file to reduce confusion, now that it is no longer needed (and not even used by `brew man`).
2016-04-17man: pipe markup to 'ronn' to avoid temporary fileMartin Afanasjew
2016-04-17man: refactor and fix code styleMartin Afanasjew
Split monolithic method into more manageable chunks and fix code style.
2016-04-17list: exclude zsh completions from unbrewedMartin Afanasjew
Since edf000e4cd30c3626ccc28c52ed32f2d84a200dd `zsh` completions are in `share/zsh/site-functions/_brew`, making this path a part of Homebrew. Hide it from `brew list --unbrewed` to reduce confusion/noise.
2016-04-16tests: ensure desc prints short name only if there are conflictsJosh Hagins
Fixes #70. Signed-off-by: Baptiste Fontaine <batifon@yahoo.fr>
2016-04-16audit.rb: Base desc length check on short nameCory Donnelly
Currently, brew audit --strict includes the name of the tap when calculating the length of a formula's description. This makes it difficult to pass the audit for formulas in taps with lengthy names. In #47033 @jawshooah called out head-only or devel-only taps specifically, but this is an issue elsewhere. For example: homebrew/versions/elasticsearch20: Distributed search & analytics engine (72) This commit updates audit.rb to use formula.name rather than formula.full_name. Closes #47033 -- Audit shouldn't include tap name in description length
2016-04-16desc: print short name unless multiple formulae have the same nameJosh Hagins
2016-04-16test-bot: update for new deps/uses optionsXu Cheng
Closes #92. Signed-off-by: Xu Cheng <xucheng@me.com>
2016-04-16update manpage for deps/usesXu Cheng
2016-04-16uses/deps: default to skip optional/build deps.Xu Cheng
Also add options to include optional/build deps and an option to skip recommended deps. Closes Homebrew/legacy-homebrew#50066.
2016-04-16analytics: add more documentation, Linuxbrew ID. (#98)Mike McQuaid
2016-04-14style: use rubocop 0.39Dominyk Tiller
(#85)
2016-04-13superenv: fix formula prefix path to consider revisionsAndrew Janke
Old logic doesn't include revision. This fixes that, and passes the whole formula prefix path to avoid duplicating the path-construction logic. Closes #80. Signed-off-by: Andrew Janke <andrew@apjanke.net>
2016-04-13superenv: allow paths under self's kegAndrew Janke
Fixes build error in Homebrew/homebrew-core#100. Closes #63. Signed-off-by: Andrew Janke <andrew@apjanke.net>
2016-04-12Document disabling of opt-in Homebrew analytics. (#79)Mike McQuaid
2016-04-12tap: various improvements (#77)Xu Cheng
* make `read_or_set_private_config` private * add doc * add test
2016-04-12update: use official GitHub SHA API. (#75)Mike McQuaid
This is coming out of preview shortly so use the new API content-type.
2016-04-12Homebrew (opt-in) Analytics tweaks. (#57)Mike McQuaid
- add `HOMEBREW_PRODUCT` global variable - only differentiate between `/usr/local` and `non-/usr/local` Homebrew prefixes to avoid sharing sensitive user information - note if e.g. build errors are occurring under CI - Add `HOMEBREW_NO_ANALYTICS` variable (this will be how people opt-out when this is enabled for everyone) - Add `HOMEBREW_ANALYTICS_DEBUG` variable to output all the analytics that are sent - Move Bash analytics code to `Library/Homebrew/utils/analytics.sh` - Add documentation for our analytics and why/what/when/how and opt-out - Only official Homebrew commands are reported - Ruby analytics are now reported in a forked, background process
2016-04-12Cache `Tap#private?` checks.Mike McQuaid
Use both an in-class and a `.git/config` cache for this so we can ensure that the `Tap#private?` check is fast. Also, make sure this cache value is set both when initially installing and updating a tap. Thanks to @xu-cheng for most of the implementation here.
2016-04-12help: support highlighted outputXu Cheng
Closes #68. Signed-off-by: Xu Cheng <xucheng@me.com>
2016-04-12help: handle aliasXu Cheng
Before this fix ``` $ brew --help ls Error: Unknown command: ls ``` After this fix ``` $ brew --help ls brew list, ls <snip> ```
2016-04-11Auto-update when running `brew install`/`upgrade`.Mike McQuaid
Also, slightly tweak the behavior of `brew update` in this case so that it doesn't print annoying output and still allows the `brew edit` flow for people with `HOMEBREW_DEVELOPER` set.
2016-04-10brew.rb: adjust behavior for undocumented commandsMartin Afanasjew
Don't exit with a non-zero status code just because an internal command happens to be undocumented. Also print the generic help in these cases to provide some help (including a reference to the man page).
2016-04-10Fix documentation errorMax Nordlund
Closes #10. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-10Generate the new man pageMax Nordlund
2016-04-10Add all the top level commentsMax Nordlund
2016-04-10Implement the `brew help` commandMax Nordlund
This is also used by `brew <cmd> --help`. The basic idea is to have the documentation as a top level comment in each command file. To find these comments, they have to be like this `#:`. This is also used by the `brew man` command to keep the documentation DRY, and for that there are now a header and footer for the man page.
2016-04-10xcode: expect 7.3 on 10.11Dominyk Tiller
xcode: expect 7.3 on 10.11
2016-04-09diagnostic: fix style of previously skipped methodMartin Afanasjew
Fix style of previously omitted `check_for_bad_install_name_tool` method to be in line with changes made in #49. Closes #56. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-09Revert "diagnostic: improve check for 'install_name_tool'"Martin Afanasjew
This reverts commit 9f79c05656a44f926898774c6029025002bcd621. Restore check to continue to inspect `/usr/bin/install_name_tool`. See Homebrew/legacy-homebrew#50091 and Homebrew/legacy-homebrew#50509 for the full context and more details.
2016-04-08diagnostic: prefer guard clauses for readabilityMartin Afanasjew
Guard clauses instead of if/unless blocks make the checks easier to understand and reduce nesting, thus improving overall readability. This includes the following additional minor changes: - Make indentation of commands consistent inside diagnostic messages. - Fix minor typos and inconsistent punctuation in diagnostic messages. - Fix here documents to always start with `<<-EOS.undent` on a new line, followed by the message (indented once), followed by `EOS` (at the same level like `<<-EOS.undent`). - Always separate the check logic (and guard clauses) from the following message by a single empty line (for consistency and readability). - Standardize on `message` as the variable name when diagnostic messages need to be constructed from multiple parts. - Where easily possible, adapt check logic to stay within 80-column limit, use more expressive variable names, and break down long expressions into multiple statements with intermediate results. Closes #49. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-08brew.sh: make sure to always use system 'awk'Martin Afanasjew
This should prevent issues like #47 and make us more resilient.
2016-04-08scm/git: prevent exec bomb with 'env :userpaths'Martin Afanasjew
Using `git` from `Formula#install` can cause an exec bomb if used in a formula with `env :userpaths` because that causes both `Library/ENV/4.3` and `Library/ENV/scm` to be in PATH, both of which contain a `git` binary that is the same SCM wrapper. Those will mutually exec each other indefinitely as they fail to detect that they are the same wrapper. Extend the exec-bomb protection to check the paths after all symbolic links have been expanded to prevent this situation. Fixes #43. Fixes Homebrew/homebrew-core#133. Fixed Homebrew/homebrew-core#143. Closes #46. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-04-07remove legacy Aliases/Formula symlink from LibraryMartin Afanasjew
2016-04-07curl: fall back to /usr/bin/curl when HOMEBREW_CURL doesn't existXu Cheng
This can happen when `HOMEBREW_CURL` is set to brewed curl, but during `brew resinstall curl`, brewed curl's symlink is temporary unlinked. So let's fallback to /usr/bin/curl in this case.
2016-04-07brew.sh: tweak HOMEBREW_PROCESSOR on LinuxMartin Afanasjew
`uname -p` seems to be less useful on Linux (Debian 8 yields `unknown`), thus prefer `uname -m` on those systems to determine the processor type. Closes #35. Signed-off-by: Martin Afanasjew <martin@afanasjew.de>