Rylan Polster
01cf98e526
Remove style exceptions for ProvidedByMacos and UsesFromMacos
2020-12-03 14:30:34 -05:00
Rylan Polster
629ad219aa
Migrate MAKE_CHECK_ALLOWLIST
2020-11-30 18:18:50 -05:00
Mike McQuaid
0793644f62
Merge pull request #9052 from jonchang/deprecate-requirements-in-core
...
audit: deprecate requirements in core
2020-11-06 15:16:18 +00:00
EricFromCanada
3768b7a6e9
apidoc: update comment wording, punctuation, formatting
2020-11-06 00:21:02 -05:00
Jonathan Chang
1b95059c2b
Restrict audit to homebrew/core
...
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2020-11-06 00:49:48 +11:00
Jonathan Chang
777dc10aa8
audit: deprecate requirements in core
...
This strict audit ensures that new formulae that depend on Requirements
like :x11, :java, and :osxfuse are not introduced into homebrew/core.
2020-11-06 00:20:34 +11:00
Markus Reiter
bf7fe45e89
Merge pull request #8896 from reitermarkus/sorbet-inline
...
Inline type annotations.
2020-10-13 10:40:53 +02:00
Rylan Polster
3b944434cf
style: allow python versions with two digits
2020-10-11 09:46:14 -04:00
Rylan Polster
40e4b38d05
style: python versions must match python dependency
2020-10-10 13:59:20 -04:00
Markus Reiter
24ae318a3d
Move type annotations into files.
2020-10-10 14:59:39 +02:00
Rylan Polster
38cedb9013
style: allow license exceptions to be on one line
2020-10-05 16:23:52 -04:00
Markus Reiter
52efa13222
Document rubocops/lines
cops.
2020-08-26 03:13:59 +02:00
Rylan Polster
97b1b75dc5
style: forbid one line nested license expressions
2020-08-20 11:20:04 -04:00
Rylan Polster
ef447a38c6
style: convert from license array to license hash
2020-08-20 10:58:36 -04:00
Mike McQuaid
3a91c37e66
Fix RuboCop checks.
2020-08-19 17:12:32 +01:00
Markus Reiter
5d3881e1ab
Don't skip RuboCop on non-existent ARGV
methods.
2020-08-06 16:28:07 +02:00
Rylan Polster
55246d720e
improve style in pattern matcher
2020-07-12 14:20:05 -04:00
Rylan Polster
8c0c713d6b
style: don't use build.with? for dependencies
2020-07-12 12:12:36 -04:00
Rylan Polster
69e89d7a01
add TODOs for future refactoring
2020-07-10 15:08:20 -04:00
Rylan Polster
e0b5c2093a
style: refactor OptionDeclarations cop
2020-07-10 11:17:37 -04:00
Rylan Polster
ae0d37e911
Transfer to FormulaAuditStrict
2020-07-05 13:57:49 -04:00
Rylan Polster
0786003fe9
Add tests for autocorrect
2020-07-05 12:12:36 -04:00
Rylan Polster
35a8c33690
Update shell metacharacter list
2020-06-30 10:18:49 -04:00
Rylan Polster
d921e94a2b
rubocop: separate args for shell commands
...
Use `system "foo", "bar"` instead of `system "foo bar"`. Also applies to
`Utils.popen_read` and `Utils.popen_write` commands. RuboCop can
automatically fix these problems.
2020-06-29 13:26:58 -04:00
Rylan Polster
e82084583a
style: set shell variables in hash
...
When running Utils.popen (or similar popen command), having a line like
"SHELL=bash ..." doesn't work properly. Instead, use:
`Utils.popen({ "SHELL" => "bash" }, "...")`
2020-06-26 16:39:39 -04:00
Rylan Polster
0faf17b1e6
use safe_popen_read instead of popen_read
...
RuboCop requires using Utils.safe_popen_read and Utils.safe_popen_write
instead of Utils.popen_read and Utils.popen_write respectively.
Using the "safe" version means that an error will be shown if the
command fails. Previously, when using `popen_read`, a failed command can
go unnoticed and have negative consequences that go undetected (as
happened for pipend in
https://github.com/Homebrew/homebrew-core/pull/55682 )
RuboCop does not require Utils.safe_popen_read in a test do block
because there can be some legitimate uses for Utils.popen_read in these
cases.
2020-06-23 13:57:33 -04:00
Issy Long
0041ea21f5
Change occurrences of "whitelist" to "allowlist"
2020-06-06 22:38:32 +01:00
Mike McQuaid
aa81982aba
brew style --fix
2020-06-02 09:49:23 +01:00
Mike McQuaid
3b9a8cb8c1
rubocops/lines: fix rule.
...
This stops stuff like `clang=1` from being matched incorrectly.
2020-04-14 11:59:41 +01:00
Mike McQuaid
ea77fce409
rubocops/lines: move strict cop.
2020-04-13 16:01:25 +01:00
Mike McQuaid
20998ed6e3
rubocop/lines: extract whitelist to constant.
2020-04-12 14:17:05 +01:00
Sean Molenaar
84181f2068
Audit: allow make check for nettle
2020-04-08 19:08:15 +02:00
Sam Ford
486a557cf5
rubocop/lines: add protobuf to whitelist
2020-02-16 09:34:09 -05:00
Mike McQuaid
6bc72cf18a
rubocop/lines: add whitelist.
...
Let's only allow cryto or libraries.
2020-01-29 12:17:21 +00:00
Jonathan Chang
cf66c05d87
audit: avoid build-time checks in core
...
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-01-11 09:48:54 -08:00
Jonathan Chang
9634041f82
audit: unnecessary comments from external taps
...
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-01-11 09:44:20 -08:00
Jonathan Chang
7239b3099a
audit: check for build.with? in core
...
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-01-11 09:37:10 -08:00
Jonathan Chang
779304df68
audit: add "homebrew/core" for relevant checks
2020-01-08 15:38:48 -05:00
Issy Long
1f6168fe8a
Change regexp.match?(string) to string.match?(regexp) everywhere
...
- Only try to call `.match?` on strings that aren't nil.
2019-10-13 23:22:51 +01:00
Issy Long
b78028b9c2
Auto-fix Performance/RegexpMatch offenses
2019-10-13 16:04:26 +01:00
Izaak Beekman
ffe30058ab
Add MPICH cop and test
...
- Split off from PR Homebrew/brew#6209
- Create stand alone class for cop w/ auto-correct
2019-06-06 16:28:54 -04:00
Mike McQuaid
36dbad3922
Add frozen_string_literal to all files.
2019-04-20 13:27:36 +09:00
Mike McQuaid
d64429a736
rubocop: enable Style/IfUnlessModifier.
2019-02-21 12:55:49 +00:00
Mike McQuaid
1aa8ad09e2
Deprecate macOS versions below Mavericks
...
And remove all dead/unneeded code.
2019-01-27 12:27:47 +00:00
Mike McQuaid
170c5493a4
Update deprecations
...
- Add some `odeprecated`
- Make some `odeprecated` now `odisabled`
- Remove `odisabled` code.
- Remove old update migrations
- Remove GCC 4.0 compiler
- Remove Tiger-only code
- Remove 32-bit-only code
- Remove use of LD64
- Remove GCC 4.3 - 4.8 support.
2019-01-08 19:13:46 +00:00
Shaun Jackman
8461cf24f1
rubocop: Use include? rather than match
2018-12-10 10:23:39 -08:00
Shaun Jackman
f62955688f
audit: Disable "Don't use OS.mac?" for Linuxbrew
2018-11-26 11:55:28 -08:00
Mike McQuaid
376eac2b8d
rubocops: rename files for consistency.
...
Make the filenames consistent with the class names.
2018-11-08 14:42:55 +00:00