88 Commits

Author SHA1 Message Date
Chongyu Zhu
2181ea76c6
python_virtualenv_constants: upgrade virtualenv to 16.2.0 2019-01-01 18:21:23 +08:00
Shaun Jackman
e8b22690a0 Fix Language::Java::java_home_env for Linux
/usr/libexec/java_home is specific to macOS.
Language::Java::java_home_cmd is not implemented on Linux and raises
NotImplementedError.

Add private Language::Java::java_home_shell and use it instead of java_home_cmd.
Add public Language::Java::java_home for use by formulae.
2018-11-29 12:50:31 -08:00
Chongyu Zhu
77daf29c47
python_virtualenv_constants: upgrade virtualenv to 16.1.0 2018-11-01 00:47:47 +08:00
EricFromCanada
20167e5f1b Adjust comments to tidy API docs output. 2018-10-18 21:42:43 -04:00
Markus Reiter
c4d418e126 Use ActiveSupport’s #second. 2018-10-07 23:10:56 +02:00
Jonathan Chang
0fe273be5f language/python: support pypy 2018-09-24 16:24:30 -04:00
commitay
eb9f9f5e36 language/haskell: use v1 commands 2018-09-21 13:23:39 +10:00
Markus Reiter
e9b9ea49a1 Update to RuboCop 0.59.1. 2018-09-17 03:45:59 +02:00
Mike McQuaid
bcb1ec5499
Improve Homebrew/brew line length.
Use 124 max line length everywhere. Also, reduce tap max line length to
189 as Homebrew/homebrew-core has that as a maximum now. In future
Homebrew/homebrew-core will also be reduced to 124 maximum line length.
2018-09-02 16:15:09 +01:00
Markus Reiter
7762ce32aa Use more descriptive heredoc names. 2018-07-11 18:15:30 +02:00
commitay
e3ec061a3a language/python: python 3.7 2018-07-05 10:16:04 +10:00
commitay
db56b1add5 python_virtualenv_constants: update virtualenv to 16.0.0 2018-05-18 12:05:55 +10:00
Mike McQuaid
9fca172d03 Fix HOMEBREW_RUBY_WARNINGS="-w"
Fix various circular requirements, method redefinitions, etc.
2018-04-07 20:28:56 +01:00
ilovezfs
7eaaaf6fa2 python_virtualenv_constants: update virtualenv to 15.2.0 2018-04-02 01:58:17 -07:00
ilovezfs
776fec7f6b virtualenv_install_with_resources: invoke python with versioned name.
The unversioned python executable no longer refers to python3.
2018-03-09 14:01:52 -08:00
ilovezfs
34bd99af8d language/python: expect @ in python@2 Cellar paths
The realpath of the python@2 Cellar contains "python@2" not "python2" so
check for "python@2" when doing Cellar->opt robustifications.
2018-03-08 08:10:48 -08:00
Mike McQuaid
bc3389bdae
Merge pull request #3863 from MikeMcQuaid/python3-changes
Adjust docs and more internal code for Python 3.
2018-03-03 18:17:04 +00:00
Mike McQuaid
70253f0009 Adjust docs and more internal code for Python 3.
Now we have `python` for Python 3 and `python@2` for Python 2 some more
adjustments need to be made.
2018-03-03 09:42:25 +00:00
Steven Peters
0d5ae6cf0b
language/python: version 3.6 in site_packages 2018-03-02 09:05:41 -08:00
ilovezfs
04cec369c7 language/python: handle python@* in each_python 2018-02-28 03:20:14 -08:00
ilovezfs
5496a04dd9 language/python: handle python@* in virtualenv_install_with_resources 2017-12-30 15:11:14 -08:00
Mike McQuaid
4b849dacd2
Merge pull request #3573 from DomT4/python_dead_code
python: remove package_available? logic
2017-12-13 08:50:05 +00:00
Dominyk Tiller
5a018f8650
python: remove package_available? logic
It was added in https://github.com/Homebrew/legacy-homebrew/pull/37345 for
a use case discussed in https://github.com/Homebrew/legacy-homebrew/pull/37340
that never seems to have actually emerged. I can find no reference of it
ever having been used, despite it existing for 2+ years here.
2017-12-13 06:16:02 +00:00
Dominyk Tiller
d6ebdf1e62
python: handle env filtering on pth check
Since ENV filtering became the default this has been chucking
erroneous warnings from both `brew doctor` and things like `brew install pygobject`
about needing to run:
```
echo 'import site; site.addsitedir("/usr/local/lib/python2.7/site-packages")' >> /Users/xyz/Library/Python/2.7/lib/python/site-packages/homebrew.pth
```
even though I had Homebrew's `python` installed.
2017-12-13 06:09:37 +00:00
Markus Reiter
526299913f Remove usless comments. 2017-10-24 19:39:40 +02:00
Markus Reiter
9bee9ca575 Use “squiggly” heredocs. 2017-10-18 14:39:09 +02:00
Mike McQuaid
01e9ec9a9f Rubocop: automatic rule fixes. 2017-09-24 21:23:59 +01:00
JCount
66f1b17942 python_virtualenv_constants: update virtualenv to 15.1.0
This release adds support for Python 3.6, the current python3
version in homebrew/core.
2017-07-11 14:20:49 -04:00
Mike McQuaid
9f6762d958 language/node: general cleanup.
- Avoid using a temporary variable where not necessary
- Use fewer, better stubs in the tests to avoid warnings and better
  test the implemented functionality.
2017-07-07 15:11:41 +01:00
Christian Moritz
5e00c277ce partly revert log verbose npm pack output commit
to fix issues with shwoing npm debug output even on non-verbose install runs.
2017-06-30 00:55:34 +02:00
Christian Moritz
6baea2543a language/node: set cache config via argument
instead of writing a .npmrc file, which simplifies the code.
npm_cache_config is still preserved for backwarts compatiblility and
usage int he kibana@n formulas in core.
2017-06-29 20:29:25 +02:00
Christian Moritz
466fe9841a language/node: npm pack ignore prepublish scripts
This tells npm pack to don't run prepublish scripts at all.
I think this is the best default because:
* most modules don't have a prepublish script at all and aren't affected
  by this change
* most prepublish scripts are calling devDeps, which would fail in our
  case, because (dev)Deps aren't installed at npm pack time until #2820
  gets resolved
* we favor npm registry tarball for formula downloads, which are already
  prepublished, so we would in the best case needlessly run prepublish
  a second time and in the worst case it would fail (because a clean
  step is required before running prepublish a second time in a row)
* This change does the right thing for >99% of all the packages and
  would only affect packages with prepublish scripts downloaded from a
  non-npm registry tarball (like github tarballs) and with a prepublish
  script wich does no't require any devDep (unlike for cross platform)
2017-06-29 20:29:25 +02:00
Christian Moritz
fe39dbb78c language/node: log verbose npm pack output
This makes npm pack to log verbose debug output to the console to
simplify debugging npm pack failures.
Refs: https://github.com/Homebrew/brew/pull/2820#discussion_r123890729
Prevously Utils.popen_read swallowed all debug output.
2017-06-29 20:29:25 +02:00
Christian Moritz
495520a1f9 language/node: make packname detection more robust
This fixes some edge cases where verbose output from a prepublish script
could break our npm pack package name detection code by only using the
last line of the output printed by npm itself containing the desired
package name.
2017-06-29 20:29:25 +02:00
Christian Moritz
02113e2714 language/node: build native addons from source
By telling node-pre-gyp and prebuild to don't pull prebuild binaries and
instead build them from source. This still may not work for some custom
third party scripts for pulling prebuild binaries.
2017-06-29 20:29:25 +02:00
Christian Moritz
7d8124f339 language/node: set npm loglevel to max -ddd
to match the loglevel used in npm_debug.log (previous --verbose loglevel
would match -dd)
2017-06-29 20:29:25 +02:00
mansimarkaur
f8f239686d Added rescue FormulaUnavailableError to setup_npm_environment 2017-06-23 03:40:03 +05:30
Mike McQuaid
021cef4b2b Autocorrect Rubocop Style/SpecialGlobalVars. 2017-06-12 09:11:42 +01:00
Dominyk Tiller
b6d81359f0
language/node: adjustments for npm 5.0.x
Goes with: https://github.com/Homebrew/homebrew-core/pull/14085
2017-06-01 21:45:26 +01:00
Mike McQuaid
7a38bab333 Fixup all RuboCop warnings. 2017-05-29 18:43:18 +01:00
Mike McQuaid
ba3c46d24f More deprecations.
Deprecate more methods. Internal APIs have been verified to be unused
elsewhere and removed. External APIs have had deprecation methods added.
Existing deprecations have been either upgraded to produce warnings or
no longer deprecated and the reasoning documented.
2017-04-22 16:28:07 +01:00
Tim D. Smith
47d57ca995 Immortalize virtualenvs better
virtualenvs remember the prefix of the python that created them and do
magic to load packages from them; help them remember a more durable
path.
2016-10-04 22:57:08 -07:00
ilovezfs
23a38e0ff6 virtualenv_install_with_resources: select correct python
`virtualenv_install_with_resources` will now attempt to guess the
desired Python based on the active build options and based on the
dependencies and requirements. When the situation is ambiguous (e.g.,
`depends_on :python3` and `build.with? "python"` is true) raise
`FormulaAmbiguousPythonError` unless `:using => "python"` or
`:using => "python3"` has been passed to resolve the ambiguity.

In most cases, this will allow

```
    virtualenv_create(libexec, "python3")
    virtualenv_install_with_resources
```

to be changed to just

```
    virtualenv_install_with_resources
```
2016-10-02 18:08:56 -07:00
Markus Reiter
fe2d51e0b9 Fix Style/IfUnlessModifier. 2016-09-23 15:30:07 +02:00
Mike McQuaid
3982950e61 rubocop --auto-correct all hash-rocket usage. 2016-09-17 16:14:13 +01:00
Mike McQuaid
ba85244413 language/python_virtualenv_constants: fix Rubocop warnings. 2016-09-10 10:40:08 +01:00
Mike McQuaid
16be0f105e language/python: fix Rubocop warnings. 2016-09-10 10:40:02 +01:00
Mike McQuaid
bde8d69d6e language/node: fix Rubocop warnings. 2016-09-10 10:39:59 +01:00
Mike McQuaid
78603a24f6 language/haskell: fix Rubocop warnings. 2016-09-10 10:38:47 +01:00
Xu Cheng
a8566c9848 various: eliminate the usage of any? (#638)
`any?` is not the opposite of `empty?`. Besides the case that
`[false, nil].any?` will return false, `any?`(O(n)) has much worse
performance than `empty?`(O(1)).
2016-08-05 22:01:32 +08:00