285 Commits

Author SHA1 Message Date
Gautham Goli
ed387572ec cli_parser: Add class method to make options declaration more readable 2018-03-25 18:02:29 +05:30
Mike McQuaid
8040c82e9e
Merge pull request #3610 from GauthamGoli/arg-parser
cli : Add basic arg parser and use it for parsing `brew audit` args
2018-03-21 08:56:38 +00:00
Mike McQuaid
d2c23bde6d Audit use of :run dependencies.
These are a no-op so let's remove them.
2018-03-19 10:11:08 +00:00
Mike McQuaid
cb6828dbe6
Merge pull request #3925 from maxim-belkin/git_remote_exists_bool
append ? to git_remote_exists
2018-03-15 08:20:14 +00:00
Maxim Belkin
c99cfd1591
add ? to svn_remote_exist 2018-03-14 16:55:45 -05:00
Maxim Belkin
f984701c29
append ? to git_remote_exist 2018-03-14 16:30:45 -05:00
Gautham Goli
5743f22209 cli : Implement Parser and use it for parsing audit command args 2018-03-09 02:44:50 +05:30
William Woodruff
b4443e1cc0
Merge branch 'audit-deny-binary-looking-urls' 2018-02-07 11:20:19 -05:00
William Woodruff
3f43f60a2a
audit: Warn on new formulae containing binary URLs 2018-02-06 08:44:56 -05:00
Mike McQuaid
3ac2f81f3c
Merge pull request #3757 from EricFromCanada/master
docs: add more option descriptions
2018-02-05 10:31:57 +01:00
William Woodruff
7fffccba05
audit: Remove FILEUTILS_METHODS constant
This constant hasn't been used since there was an `audit_line`
method, and as such is vestigial.
2018-02-04 22:44:46 -05:00
EricFromCanada
1d2b4ed321 docs: add more missing option descriptions
and improve wording or formatting where necessary.
2018-02-01 16:06:17 -05:00
Mike McQuaid
50a84f2535 audit: allow env :std in custom taps.
This is a nicer experience than writing `Requirement`s by hand.
2018-01-09 15:26:54 +00:00
commitay
8a419b4742 audit: pass explicit sort to handle APFS 2018-01-07 13:36:16 +10:00
Mike McQuaid
d54e670a64 requirements: move more to compat. 2017-12-30 20:56:55 +00:00
Mike McQuaid
7f54c83911 audit: remove unneeded mercurial check. 2017-12-29 19:53:04 +00:00
Martin Schimandl
0db069602e Refactor: Move FormulaAudit.check_http_content to utils/curl 2017-12-03 14:02:55 +01:00
Gautham Goli
7b2fab8ec5 Merge branch 'master' into audit_line_rubocop_part_4_rebase_attempt_1 2017-10-21 13:53:44 +05:30
Markus Reiter
9bee9ca575 Use “squiggly” heredocs. 2017-10-18 14:39:09 +02:00
Gautham Goli
7fa51f71f1 Merge branch 'master' into audit_line_rubocop_part_4_rebase_attempt_1 2017-10-13 19:50:46 +05:30
Dominyk Tiller
0865ab0d1b audit: nudge to use predicate for 'executable?' as well 2017-10-10 15:45:41 +01:00
Dominyk Tiller
a0f4861934
audit: broaden refute_predicate nudge 2017-10-09 16:46:01 +01:00
Mike McQuaid
56458f03fc Merge pull request #3277 from sjackman/audit-notable
audit: Silence not notable on non-Homebrew taps
2017-10-08 13:41:15 -07:00
Shaun Jackman
53dd0e3f28 audit: Silence not notable on non-Homebrew taps
Silence "GitHub repository not notable" on non-Homebrew taps.
2017-10-08 10:35:53 -07:00
Markus Reiter
175ca909ee Clean up code style and remove .rubocop_todo.yml. 2017-10-08 16:10:37 +02:00
Dominyk Tiller
2a25825a12
audit: tweak assert/refute_predicate audit
Addresses some of the issues I raised in https://github.com/Homebrew/homebrew-core/pull/19127#issue-263566817.
Would still like to work out a way to check `File.exist?`-style language
inside the `test do` block exclusively but for now it's better to be
too conservative on the audit than to be overly-zealous and flag too
much.
2017-10-08 06:54:49 +01:00
Dominyk Tiller
4e957165d1
audit: prefer assert/refute_predicate over File.exist? 2017-10-05 02:52:21 +01:00
Mike McQuaid
134bd00d10 audit: don't care about shadowing official taps.
We're trying to import all of these formulae anyway.
2017-09-29 16:23:02 +01:00
Mike McQuaid
cf5fdeef1d Rubocop: manual rule fixes. 2017-09-24 21:23:59 +01:00
Mike McQuaid
01e9ec9a9f Rubocop: automatic rule fixes. 2017-09-24 21:23:59 +01:00
ilovezfs
28c7838450 audit: also skip homebrew/science duplicates found by search_taps
Follow-up to #3202.
2017-09-24 00:29:34 -07:00
ilovezfs
e984623214 audit: don't check for homebrew/science duplicates
It's just noise to turn the migration PRs red over expected duplicates.
2017-09-23 23:00:29 -07:00
Mike McQuaid
56ab1ef5a8 audit: hack around El Capitan audit failure. 2017-09-23 21:10:25 +01:00
Mike McQuaid
ffdda0eb9f Tweaks for older Mac OS X versions.
- `brew update` should try to install `curl` before `git` on older
  versions of Mac OS X where it is needed for accessing modern SSL
  certificates.
- We don't need an HTTP mirror for `git` because `curl` will already be
  installed before it is downloaded.
- Don't recommend GCC on Mac OS X versions where it can't be built with
  the default system compiler.
- Start using the Homebrew `curl` on Mac OS X versions where it is
  needed as soon as it is installed.
2017-09-16 12:41:08 +01:00
Mike McQuaid
2e43d95498 audit: fix check_http_content args. 2017-09-15 10:17:40 +01:00
Mike McQuaid
03ace9b110 Require more HTTP mirrors for old OS X versions.
This allows the bootstrap of `curl` and `git` on versions of Mac OS X
that cannot reliably download from HTTPS servers any longer. Once these
are both installed users are able to update Homebrew and download files
securely.

Also, as we're doing this, don't point 10.5 users to Tigerbrew as they
are already given caveats for using Homebrew itself.
2017-09-14 19:58:37 +01:00
Mike McQuaid
ef60688704 Merge pull request #3126 from DomT4/curl_audit
audit: stop demanding a HTTP HEAD mirror for curl
2017-09-12 15:48:11 +01:00
Mike McQuaid
bf0ab938e7 Merge pull request #3091 from GauthamGoli/audit_line_rubocop_part_3
audit: Port line_problems to rubocop and add tests part 3
2017-09-05 18:10:02 +01:00
Dominyk Tiller
9562cceef1
audit: stop demanding a HTTP HEAD mirror for curl
Not sure if this is how you want to handle it but having a HEAD mirror
for `curl` is just silliness.

Ref: e36b95849a
2017-09-05 03:35:44 +01:00
Gautham Goli
d45ff9c0fd audit: Add a global flag to silent warning when auditing 2017-09-04 23:57:09 +05:30
Gautham Goli
4ec26aea40 audit: Port audit_class to rubocop, add tests and autocorrect 2017-09-04 23:43:42 +05:30
Gautham Goli
267def28fa audit: Port rules from line_problems to rubocop part 3 2017-09-04 15:05:43 +05:30
Mike McQuaid
73cd2a1db8 Merge pull request #3119 from MikeMcQuaid/audit-subversion-url-fix
audit: fix subversion remote check logic.
2017-09-04 01:54:28 +01:00
Mike McQuaid
37293c6f01 Merge pull request #3096 from vszakats/urlchk1
audit: Add some heuristics to https upgrade checks
2017-09-03 21:50:53 +01:00
Mike McQuaid
bbf71921eb audit: fix subversion remote check logic.
Stop flagging invalid URLs as valid and vice-versa.

Fixes #3118.
2017-09-03 21:42:46 +01:00
Viktor Szakats
42e2c71dbc cleanup range check 2017-09-01 16:47:31 +00:00
Dominyk Tiller
f301e5c4f4
audit: add a nudge to remove ENV.java_cache 2017-08-31 21:33:09 +01:00
Viktor Szakats
18f5b43d90 fix length ratio range 2017-08-29 17:02:27 +00:00
Viktor Szakats
56ccf10efa limit some heuristics to strict mode 2017-08-29 12:53:45 +00:00
Viktor Szakats
c30b941358 review follow-up #1 2017-08-29 12:31:07 +00:00