122 Commits

Author SHA1 Message Date
Markus Reiter
4465a1f6fb
Merge pull request #8455 from reitermarkus/document-svn
Refactor and document `Svn`.
2020-08-24 00:03:21 +02:00
Markus Reiter
3118fedab9 Refactor and document Git. 2020-08-23 06:40:07 +02:00
Markus Reiter
8b26e380a2 Refactor and document Svn. 2020-08-23 06:33:58 +02:00
Dawid Dziurla
59ce122e90
dependency_collector: make resource dep available at test-time too
There are formulae that use resource blocks for stuff that is needed in
test blocks. If a resource is a `.zip` archive, one needs `unzip`
utility in `PATH` to extract it, but its only available at build-time,
so one observes an error like that for example:

```
==> brew test psftools --verbose
Testing psftools
==> Downloading https://www.zone38.net/font/pc8x8.zip
Already downloaded: /github/home/.cache/Homebrew/downloads/ea5f6a485687368ff5bc99e4cc43a49b06e081baa51a97ee6ddcd8d1b82d7963--pc8x8.zip
==> Verifying ea5f6a485687368ff5bc99e4cc43a49b06e081baa51a97ee6ddcd8d1b82d7963--pc8x8.zip checksum
unzip -o /github/home/.cache/Homebrew/downloads/ea5f6a485687368ff5bc99e4cc43a49b06e081baa51a97ee6ddcd8d1b82d7963--pc8x8.zip -d /tmp/d20200304-21389-ui0wr0
Error: psftools: failed
undefined method `shelljoin' for nil:NilClass
```

Of course this issue affects Linux the most, because of higher
probability that the system lacks `unzip` for example.

With this commit, all resource guessed dependencies should be available
at build and test time.
2020-03-04 22:49:54 +01: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
Markus Reiter
78aee4fed3 Merge MaximumMacOSRequirement into MacOSRequirement. 2019-08-21 06:57:21 +02:00
Mike McQuaid
c4f72312ce
Fixup brew style failures. 2019-04-30 09:19:18 +01: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
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
d2dba5fc4a DependencyCollector: Add java_dep_if_needed [Linux]
Use the openjdk formula if it's installed.
Use the host's Java if it's sufficient.
Otherwise install the openjdk formula.
2018-11-11 10:18:24 -08:00
Mike McQuaid
0c0275771d
Cleanup Requirements
- remove unused NonBinaryOsxfuseRequirement
- import CodeSignRequirement from Homebrew/homebrew-core
- remove unused UnsignedKextRequirement
- don’t allow custom name for X11Requirement
2018-10-19 16:38:41 +01:00
Markus Reiter
e9b9ea49a1 Update to RuboCop 0.59.1. 2018-09-17 03:45:59 +02:00
Mike McQuaid
9fca172d03 Fix HOMEBREW_RUBY_WARNINGS="-w"
Fix various circular requirements, method redefinitions, etc.
2018-04-07 20:28:56 +01:00
Shaun Jackman
5500c3b25e unzip_dep_if_needed: Needs unzip not zip [Linux] (#632) 2018-03-05 11:51:08 -08:00
Maxim Belkin
f8874004c2 Make 'xz' and 'cvs' dependencies conditional 2018-02-21 14:11:35 +00:00
Maxim Belkin
306c19061e Code refactoring v2.0 2018-02-19 09:58:30 +00:00
Maxim Belkin
d25fc5ce50 Code refactoring 2018-02-19 09:54:36 +00:00
Maxim Belkin
b084a2581f Making zip and bzip2 dependecies conditional
Here, we are adding `unless which("zip")` and `unless which("bzip2")`
and, thus, make `zip` and `bzip2` dependencies conditional.
2018-02-19 07:21:34 +00:00
Maxim Belkin
3dabebbd16 Refactoring based on suggestions
Defaulting zip_dep_if_needed(tags) and bzip2_dep_if_needed(tags)
methods to those on Linux and overriding them on macOS.
2018-02-19 06:49:42 +00:00
Maxim Belkin
5a92976120
Fixing brew-style offenses 2018-02-16 10:49:43 -06:00
Maxim Belkin
444b292df9
zip and bzip2 dependencies when needed
On some systems identified as Linux, zip and bzip2 might
not be available. Therefore, on such platforms we add them
unconditionally as dependencies when required. On Mac, these
dependencies are always satisfied.
2018-02-16 10:41:14 -06:00
Mike McQuaid
27be33b245 Deprecate Git, Subversion requirements.
These rely on `default_formula` to be useful and are better following
the `*_dep_if_needed` pattern.
2018-01-10 13:19:50 +00:00
Shaun Jackman
5d9149a4b9 LD64Dependency is needed on macOS only
Move ld64_dependency.rb to os/mac/.
2018-01-03 10:52:12 -08:00
Mike McQuaid
d54e670a64 requirements: move more to compat. 2017-12-30 20:56:55 +00:00
Mike McQuaid
05329fc08d dependency_collector: don't use hg alias. 2017-12-29 17:51:02 +00:00
Mike McQuaid
38ce994007 Deprecate more requirements.
These are ones that were either already deprecated due to audit rules
or are just a simple `which` with a `default_formula` so should just
be a dependency.
2017-12-23 16:53:25 +00:00
Mike McQuaid
5b178c2892 dependency_collector: cleanup optional system deps 2017-12-23 16:36:33 +00:00
Shaun Jackman
baa3d187d6 Add CVSRequirement and SubversionRequirement
Use these two requirements in DependencyCollector.
Remove the unused function MacOS::Xcode.provides_cvs?
2017-11-25 09:45:08 -08:00
Shaun Jackman
230c87aff0 Rename MinimumMacOSRequirement to MacOSRequirement
Move MinimumMacOSRequirement to compat.
2017-10-17 16:16:44 -07:00
Shaun Jackman
95e144a1c8 Add depends_on :linux and :macos 2017-10-17 16:16:12 -07:00
Markus Reiter
175ca909ee Clean up code style and remove .rubocop_todo.yml. 2017-10-08 16:10:37 +02:00
Bob W. Hogg
227e69048a dependency_collector: Make ant_dep and xz_dep public
They were already public on macOS, but they were made
private by mistake on all other platforms.
DependencyCollector.tar_needs_xz_dependency? depends
on xz_dep being public, so there's no turning back now :(
2016-11-28 03:09:34 +00:00
Mike McQuaid
b1a16deb19 Use BSD tar's libarchive LZMA support if available
Avoid using an unnecessary `xz` dependency when it's not needed.
2016-10-15 13:10:37 +01:00
Mike McQuaid
26e4899fde Deprecate apr requirement.
It's not used on enough configurations now that there's little point in
keeping it around. See e.g. `:autoconf` for prior art.
2016-10-12 15:37:33 +01:00
Markus Reiter
58e36c7319 Fix Style/GuardClause. 2016-09-24 12:24:35 +02:00
Markus Reiter
42efb44e7d Fix Lint/EndAlignment. 2016-09-23 15:30:06 +02:00
Markus Reiter
52ff988530 Fix RuboCop CaseEquality. 2016-09-23 15:30:06 +02:00
Bob W. Hogg
1de9f3baf3 make linux behaviour the default. override only for macos 2016-09-22 17:47:50 -04:00
Bob W. Hogg
01b93117cd move os checks to extend/os 2016-09-22 08:31:50 -04:00
Bob W. Hogg
f65217f61e Oops, forgot to rename it in-code 2016-09-22 08:31:50 -04:00
Bob W. Hogg
0a4bc8494d switch to using extend pattern 2016-09-22 08:31:50 -04:00
Bob W. Hogg
54a086e2fe dependency_collector: Fix ant_dep for Linux.
Signed-off-by: Bob W. Hogg <rwhogg@linux.com>
2016-09-22 08:31:50 -04:00
Mike McQuaid
6693915399 rubocop --auto-correct all remaining files.
But remove some manual `.freeze`s on constants that shouldn't be
constants.
2016-09-17 16:14:13 +01:00
Dominyk Tiller
e02ad2242a
gpg_requirement: rename to gpg2_requirement 2016-08-13 03:33:33 +01:00
Dominyk Tiller
7d57119837 dependency_collector: add perl
Closes #184.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
2016-05-03 18:52:40 +01:00
Misty De Meo
2f7721f1b4 Add :expat special dependency
This will be expanded to a full expat dependency on Tiger alone.

Fixes mistydemeo/tigerbrew#30.
2016-04-22 22:37:21 -07:00
Dominyk Tiller
c9097b40f9 dependency_collector: add rbenv
Closes Homebrew/homebrew#47897.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
2016-01-09 15:53:05 +00:00
Misty De Meo
c6f45a9e06 DependencyCollector: add lua51 language module 2016-01-01 20:10:34 -04:00