- Change name of rubocop warning
- Disable linting on remaining offending lines
- Add todos to move lines with disabled linting
checks to extend/os in the future
- This was another thing that I should have done in PR 3411 in 2017,
tested that the regex for autocorrecting `desc` stanzas ending in full
stops actually worked. At least I'm getting to it now.
- This was funny (and embarrassing), I was looking at my first contributions to
Homebrew since someone asked me how long I'd been involved.
- Turns out that in 2017 I improved the formula description RuboCop rule to
allow descriptions to end with `etc.` in
https://github.com/Homebrew/brew/pull/3411. Apparently I didn't have time
back then to write a test for it. So now I will remedy this 5 years later.
This currently no longer applies, because we might sometimes need an
older `setuptools` than the one shipped with a Python formula.
This is needed for Homebrew/homebrew-core#93964.
When building Rust packages that provide libraries but no executable
binaries, `cargo install` doesn't do anything; you need to use `cargo
build` and install any libraries manually. See e.g.
rust-lang/cargo#8294.
Unfortunately, Homebrew's Rubocop "use cargo install *std_cargo_args"
rule, as currently written, blocks all invocations of `cargo build`.
This commit changes that rule to exclude invocations of `cargo build`
that use the `--lib` argument (`--lib` specifies to Cargo that a
package's library targets should be built). This will enable library
packages to be built while retaining the "use cargo install
*std_cargo_args" message for the more common case when a Rust package
provides executable binaries.
Recommend the use of `on_macos` and `on_linux` unless we're in
`def install`, `def post_install` or `test do` in which case recommend
`OS.mac?` and `OS.linux?` instead.
Only `.diff` URLs return output comparable to the diffs from
`git diff --full-index`. While the extra metadata from `.patch` is
nice, the instability of the patch contents is undesirable.
Co-Authored-By: Carlo Cabrera <30379873+carlocab@users.noreply.github.com>
- For some of these I changed `context` to `describe` as it fit better
rather than contriving a "when", "with" or "without", or massively
restructuring the tests.