Adjust the rules based on the current codebase. Remove various enable,
disables and default values that are unnecessary. Add more comments
explaining why. Make minor changes needed to enable a few more rules.
These specify that they are needed by the test block. This can be
combined with `:build` to ensure that this formula isn't uninstalled
by `brew test-bot` when running `test do` blocks on our CI.
This has been a nightmare in terms of the complexity to our dependency
system and the whack-a-mole required on bugs. If a Requirement resolves
to a Formula it should just use `depends_on "formula"` instead. This
matches the effective behaviour all users of bottles (the vast majority
of users and installs) and what we're doing in Homebrew/homebrew-core.
For example, `brew deps libass --skip-recommended` shouldn't print
harfbuzz because, even though libass builds with harfbuzz when harfbuzz
is not skipped, we asked to skip recommended, of which harfbuzz is one.
The corresponding change is made for `brew uses` as well.
Thanks to Xu Cheng for contributing the code. Any errors are mine.
Closes#129.
Signed-off-by: ilovezfs <ilovezfs@icloud.com>
`brew deps` has three different modes of operation that were not easy to
infer from the existing documentation. Split the help text into three
parts to make this clearer. This also improves on the confusion when
options were silently ignored because they don't apply to a certain mode
of operation. Those are:
1. List the shared dependencies (either intersection or union) of
explicitly named formulae with options for traversal depth/order.
2. Output separate trees of explicitly listed or all installed formulae.
3. List all available/installed formulae and their direct dependencies
with one line per formula formatted as `<formula>: <dependencies>`.
Closes#137.
Closes#179.
Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
Until we figure out how to allow --tree to show optional dependencies in
a way that fits on a normal screen, this helps to explain the
discrepancy between `brew deps` and `brew deps --tree`.
ClosesHomebrew/homebrew#41841.
ClosesHomebrew/homebrew#41947.
The default behavior of `brew deps foo bar` is to return the
intersection of the deps of foo and bar. This option returns the union.
ClosesHomebrew/homebrew#27480.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>