From 2ad4e22280dc8a2e61613251461e8049129deb4b Mon Sep 17 00:00:00 2001 From: Daniel Azuma Date: Fri, 18 Oct 2019 15:44:22 -0700 Subject: [PATCH] feat: Update Ruby dependency to minimum of 2.4 (#4206) --- .github/CONTRIBUTING.md | 2 +- README.md | 4 +- gcloud/.rubocop.yml | 8 +- gcloud/CONTRIBUTING.md | 2 +- gcloud/README.md | 4 +- gcloud/gcloud.gemspec | 4 +- google-cloud-asset/.rubocop.yml | 9 +- google-cloud-asset/README.md | 4 +- google-cloud-asset/google-cloud-asset.gemspec | 6 +- google-cloud-asset/synth.metadata | 10 +- google-cloud-asset/synth.py | 19 ++-- google-cloud-automl/.rubocop.yml | 8 +- google-cloud-automl/README.md | 4 +- .../google-cloud-automl.gemspec | 6 +- google-cloud-automl/synth.metadata | 10 +- google-cloud-automl/synth.py | 19 ++-- .../.rubocop.yml | 9 +- google-cloud-bigquery-data_transfer/README.md | 4 +- ...oogle-cloud-bigquery-data_transfer.gemspec | 6 +- .../synth.metadata | 10 +- google-cloud-bigquery-data_transfer/synth.py | 19 ++-- google-cloud-bigquery/.rubocop.yml | 45 +++------ google-cloud-bigquery/CONTRIBUTING.md | 2 +- google-cloud-bigquery/README.md | 4 +- .../google-cloud-bigquery.gemspec | 8 +- google-cloud-bigtable/.rubocop.yml | 40 ++++---- google-cloud-bigtable/CONTRIBUTING.md | 2 +- google-cloud-bigtable/README.md | 4 +- .../google-cloud-bigtable.gemspec | 6 +- google-cloud-container/.rubocop.yml | 9 +- google-cloud-container/README.md | 4 +- .../google-cloud-container.gemspec | 6 +- google-cloud-container/synth.metadata | 10 +- google-cloud-container/synth.py | 19 ++-- google-cloud-container_analysis/.rubocop.yml | 8 +- google-cloud-container_analysis/README.md | 4 +- .../google-cloud-container_analysis.gemspec | 6 +- .../synth.metadata | 10 +- google-cloud-container_analysis/synth.py | 12 +-- google-cloud-core/.rubocop.yml | 44 +++------ google-cloud-core/CONTRIBUTING.md | 2 +- google-cloud-core/README.md | 4 +- google-cloud-core/google-cloud-core.gemspec | 4 +- google-cloud-dataproc/.rubocop.yml | 9 +- google-cloud-dataproc/README.md | 4 +- .../google-cloud-dataproc.gemspec | 6 +- google-cloud-dataproc/synth.metadata | 10 +- google-cloud-dataproc/synth.py | 19 ++-- google-cloud-datastore/.rubocop.yml | 39 +++----- google-cloud-datastore/CONTRIBUTING.md | 2 +- google-cloud-datastore/README.md | 4 +- .../google-cloud-datastore.gemspec | 6 +- google-cloud-debugger/.rubocop.yml | 59 +++++------ google-cloud-debugger/CONTRIBUTING.md | 2 +- google-cloud-debugger/README.md | 4 +- .../google-cloud-debugger.gemspec | 6 +- google-cloud-dialogflow/.rubocop.yml | 9 +- google-cloud-dialogflow/README.md | 4 +- .../google-cloud-dialogflow.gemspec | 6 +- google-cloud-dialogflow/synth.metadata | 10 +- google-cloud-dialogflow/synth.py | 19 ++-- google-cloud-dlp/.rubocop.yml | 9 +- google-cloud-dlp/README.md | 4 +- google-cloud-dlp/google-cloud-dlp.gemspec | 6 +- google-cloud-dlp/synth.metadata | 10 +- google-cloud-dlp/synth.py | 19 ++-- google-cloud-dns/.rubocop.yml | 34 +++---- google-cloud-dns/CONTRIBUTING.md | 2 +- google-cloud-dns/README.md | 4 +- google-cloud-dns/google-cloud-dns.gemspec | 8 +- google-cloud-env/.rubocop.yml | 27 +---- google-cloud-env/CONTRIBUTING.md | 2 +- google-cloud-env/README.md | 4 +- google-cloud-env/google-cloud-env.gemspec | 4 +- google-cloud-error_reporting/.rubocop.yml | 49 ++++------ google-cloud-error_reporting/CONTRIBUTING.md | 2 +- google-cloud-error_reporting/README.md | 4 +- .../google-cloud-error_reporting.gemspec | 6 +- .../cloud/error_reporting/error_event.rb | 4 - google-cloud-firestore/.rubocop.yml | 45 +++------ google-cloud-firestore/CONTRIBUTING.md | 2 +- google-cloud-firestore/README.md | 4 +- .../google-cloud-firestore.gemspec | 6 +- google-cloud-irm/.rubocop.yml | 9 +- google-cloud-irm/README.md | 4 +- google-cloud-irm/google-cloud-irm.gemspec | 6 +- google-cloud-irm/synth.metadata | 10 +- google-cloud-irm/synth.py | 19 ++-- google-cloud-kms/.rubocop.yml | 9 +- google-cloud-kms/README.md | 4 +- google-cloud-kms/google-cloud-kms.gemspec | 6 +- google-cloud-kms/synth.metadata | 10 +- google-cloud-kms/synth.py | 19 ++-- google-cloud-language/.rubocop.yml | 9 +- google-cloud-language/README.md | 4 +- .../google-cloud-language.gemspec | 6 +- google-cloud-language/synth.metadata | 10 +- google-cloud-language/synth.py | 19 ++-- google-cloud-logging/.rubocop.yml | 61 +++++------- google-cloud-logging/CONTRIBUTING.md | 2 +- google-cloud-logging/README.md | 4 +- .../google-cloud-logging.gemspec | 6 +- .../lib/google/cloud/logging/project.rb | 5 - google-cloud-monitoring/.rubocop.yml | 9 +- google-cloud-monitoring/README.md | 4 +- .../google-cloud-monitoring.gemspec | 6 +- google-cloud-monitoring/synth.metadata | 10 +- google-cloud-monitoring/synth.py | 19 ++-- google-cloud-os_login/.rubocop.yml | 9 +- google-cloud-os_login/README.md | 4 +- .../google-cloud-os_login.gemspec | 6 +- google-cloud-os_login/synth.metadata | 10 +- google-cloud-os_login/synth.py | 19 ++-- google-cloud-phishing_protection/.rubocop.yml | 9 +- google-cloud-phishing_protection/README.md | 4 +- .../google-cloud-phishing_protection.gemspec | 6 +- .../synth.metadata | 10 +- google-cloud-phishing_protection/synth.py | 19 ++-- google-cloud-pubsub/.rubocop.yml | 43 +++----- google-cloud-pubsub/CONTRIBUTING.md | 2 +- google-cloud-pubsub/README.md | 4 +- .../google-cloud-pubsub.gemspec | 6 +- .../.rubocop.yml | 9 +- google-cloud-recaptcha_enterprise/README.md | 4 +- .../google-cloud-recaptcha_enterprise.gemspec | 6 +- .../synth.metadata | 10 +- google-cloud-recaptcha_enterprise/synth.py | 19 ++-- google-cloud-redis/.rubocop.yml | 9 +- google-cloud-redis/README.md | 4 +- google-cloud-redis/google-cloud-redis.gemspec | 6 +- google-cloud-redis/synth.metadata | 10 +- google-cloud-redis/synth.py | 19 ++-- google-cloud-resource_manager/.rubocop.yml | 35 +++---- google-cloud-resource_manager/CONTRIBUTING.md | 2 +- google-cloud-resource_manager/README.md | 4 +- .../google-cloud-resource_manager.gemspec | 8 +- google-cloud-scheduler/.rubocop.yml | 9 +- google-cloud-scheduler/README.md | 4 +- .../google-cloud-scheduler.gemspec | 6 +- google-cloud-scheduler/synth.metadata | 10 +- google-cloud-scheduler/synth.py | 12 ++- google-cloud-security_center/.rubocop.yml | 9 +- google-cloud-security_center/README.md | 4 +- .../google-cloud-security_center.gemspec | 6 +- google-cloud-security_center/synth.metadata | 10 +- google-cloud-security_center/synth.py | 19 ++-- google-cloud-spanner/.rubocop.yml | 46 ++++----- google-cloud-spanner/CONTRIBUTING.md | 2 +- google-cloud-spanner/README.md | 4 +- .../google-cloud-spanner.gemspec | 6 +- .../lib/google/cloud/spanner/database.rb | 4 - .../lib/google/cloud/spanner/session.rb | 4 - google-cloud-speech/.rubocop.yml | 9 +- google-cloud-speech/README.md | 4 +- .../google-cloud-speech.gemspec | 6 +- google-cloud-speech/synth.metadata | 10 +- google-cloud-speech/synth.py | 19 ++-- google-cloud-storage/.rubocop.yml | 50 ++++------ google-cloud-storage/CONTRIBUTING.md | 2 +- google-cloud-storage/README.md | 4 +- .../google-cloud-storage.gemspec | 8 +- google-cloud-talent/.rubocop.yml | 9 +- google-cloud-talent/README.md | 4 +- .../google-cloud-talent.gemspec | 6 +- google-cloud-talent/synth.metadata | 10 +- google-cloud-talent/synth.py | 19 ++-- google-cloud-tasks/.rubocop.yml | 9 +- google-cloud-tasks/README.md | 4 +- google-cloud-tasks/google-cloud-tasks.gemspec | 6 +- google-cloud-tasks/synth.metadata | 10 +- google-cloud-tasks/synth.py | 19 ++-- google-cloud-text_to_speech/.rubocop.yml | 9 +- google-cloud-text_to_speech/README.md | 4 +- .../google-cloud-text_to_speech.gemspec | 6 +- google-cloud-text_to_speech/synth.metadata | 10 +- google-cloud-text_to_speech/synth.py | 19 ++-- google-cloud-trace/.rubocop.yml | 98 ++++++++++++------- google-cloud-trace/CONTRIBUTING.md | 2 +- google-cloud-trace/README.md | 4 +- google-cloud-trace/google-cloud-trace.gemspec | 8 +- .../lib/google/cloud/trace/service.rb | 4 - .../lib/google/cloud/trace/span.rb | 4 - google-cloud-translate/CONTRIBUTING.md | 2 +- google-cloud-translate/README.md | 4 +- .../google-cloud-translate.gemspec | 4 +- google-cloud-video_intelligence/.rubocop.yml | 9 +- google-cloud-video_intelligence/README.md | 4 +- .../google-cloud-video_intelligence.gemspec | 6 +- .../synth.metadata | 10 +- google-cloud-video_intelligence/synth.py | 19 ++-- google-cloud-vision/.rubocop.yml | 32 +----- google-cloud-vision/README.md | 4 +- .../google-cloud-vision.gemspec | 6 +- google-cloud-vision/synth.metadata | 10 +- google-cloud-vision/synth.py | 17 ++-- google-cloud-webrisk/.rubocop.yml | 9 +- google-cloud-webrisk/README.md | 4 +- .../google-cloud-webrisk.gemspec | 6 +- google-cloud-webrisk/synth.metadata | 10 +- google-cloud-webrisk/synth.py | 18 ++-- google-cloud/.rubocop.yml | 8 +- google-cloud/CONTRIBUTING.md | 2 +- google-cloud/README.md | 4 +- google-cloud/google-cloud.gemspec | 4 +- grafeas-client/.rubocop.yml | 9 +- grafeas-client/README.md | 4 +- grafeas-client/grafeas-client.gemspec | 6 +- grafeas-client/synth.metadata | 10 +- grafeas-client/synth.py | 19 ++-- stackdriver-core/.rubocop.yml | 40 +++----- stackdriver-core/CONTRIBUTING.md | 2 +- stackdriver-core/README.md | 4 +- stackdriver-core/stackdriver-core.gemspec | 4 +- stackdriver/.rubocop.yml | 11 +-- stackdriver/CONTRIBUTING.md | 2 +- stackdriver/README.md | 4 +- stackdriver/stackdriver.gemspec | 4 +- 217 files changed, 1058 insertions(+), 1243 deletions(-) diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 59f7c5cc1c64..e21f7b62e808 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -19,7 +19,7 @@ In order to use the google-cloud-ruby console and run the project's tests, there small amount of setup: 1. Install Ruby. - google-cloud-ruby requires Ruby 2.3+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). + google-cloud-ruby requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). 2. Install [Bundler](http://bundler.io/). diff --git a/README.md b/README.md index bdd808ce8aca..b5a98270f342 100644 --- a/README.md +++ b/README.md @@ -1185,11 +1185,11 @@ $ gem install google-cloud-video_intelligence ## Supported Ruby Versions -These libraries are currently supported on Ruby 2.3+. +These libraries are currently supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/gcloud/.rubocop.yml b/gcloud/.rubocop.yml index d1c122fbbb07..153f7bd2a886 100644 --- a/gcloud/.rubocop.yml +++ b/gcloud/.rubocop.yml @@ -1,9 +1,11 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "gcloud.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false @@ -13,7 +15,3 @@ Layout/EmptyLines: # for the extra line between copyright and code Metrics/LineLength: Exclude: - "Gemfile" -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/gcloud/CONTRIBUTING.md b/gcloud/CONTRIBUTING.md index fe5fae2f741e..a69d010356dd 100644 --- a/gcloud/CONTRIBUTING.md +++ b/gcloud/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/gcloud/README.md b/gcloud/README.md index 77e15cf7a6fb..9d8843d41be5 100644 --- a/gcloud/README.md +++ b/gcloud/README.md @@ -39,11 +39,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/gcloud/gcloud.gemspec b/gcloud/gcloud.gemspec index db9aea904ad5..b60dbea92594 100644 --- a/gcloud/gcloud.gemspec +++ b/gcloud/gcloud.gemspec @@ -16,17 +16,17 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "CONTRIBUTING.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud", "~> 0.23" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-asset/.rubocop.yml b/google-cloud-asset/.rubocop.yml index 8359356b7cf9..7fc6c57518bb 100644 --- a/google-cloud-asset/.rubocop.yml +++ b/google-cloud-asset/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-asset.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-asset/README.md b/google-cloud-asset/README.md index 14ecc72c1928..ec6cfe20a510 100644 --- a/google-cloud-asset/README.md +++ b/google-cloud-asset/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-asset/google-cloud-asset.gemspec b/google-cloud-asset/google-cloud-asset.gemspec index b501fd2f1acb..368e5aefa5f1 100644 --- a/google-cloud-asset/google-cloud-asset.gemspec +++ b/google-cloud-asset/google-cloud-asset.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-asset/synth.metadata b/google-cloud-asset/synth.metadata index 5103860d7471..abe5a1c36b25 100644 --- a/google-cloud-asset/synth.metadata +++ b/google-cloud-asset/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-12T10:40:43.989266Z", + "updateTime": "2019-10-18T20:52:57.030484Z", "sources": [ { "generator": { "name": "artman", - "version": "0.39.0", - "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "af8dd2c1750558b538eaa6bdaa3bc899079533ee", - "internalRef": "274260771" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-asset/synth.py b/google-cloud-asset/synth.py index 5f1a9d61ae46..72d3a628b80b 100644 --- a/google-cloud-asset/synth.py +++ b/google-cloud-asset/synth.py @@ -51,6 +51,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-asset.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -96,7 +106,7 @@ s.replace( 'google-cloud-asset.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9"\n\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9"\n\n') # https://github.com/googleapis/gapic-generator/issues/2232 s.replace( @@ -156,13 +166,6 @@ def escape_braces(match): '# Ruby Client for Cloud Asset API ([Beta](https://github.com/googleapis/google-cloud-ruby#versioning))' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-asset.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - for version in ['v1', 'v1beta1']: # Require the helpers file s.replace( diff --git a/google-cloud-automl/.rubocop.yml b/google-cloud-automl/.rubocop.yml index 5d4fc5cada03..55599904b899 100644 --- a/google-cloud-automl/.rubocop.yml +++ b/google-cloud-automl/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "google-cloud-automl.gemspec" - "lib/google/**/*" @@ -10,10 +12,6 @@ AllCops: Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses Naming/FileName: Exclude: - "lib/google-cloud-automl.rb" diff --git a/google-cloud-automl/README.md b/google-cloud-automl/README.md index 34a1f5bb0bb3..c03c79b54e4e 100644 --- a/google-cloud-automl/README.md +++ b/google-cloud-automl/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-automl/google-cloud-automl.gemspec b/google-cloud-automl/google-cloud-automl.gemspec index 576fa01200a6..e5f740d76238 100644 --- a/google-cloud-automl/google-cloud-automl.gemspec +++ b/google-cloud-automl/google-cloud-automl.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-automl/synth.metadata b/google-cloud-automl/synth.metadata index 4e40dee00069..ada9a1f73b12 100644 --- a/google-cloud-automl/synth.metadata +++ b/google-cloud-automl/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-24T10:37:10.713896Z", + "updateTime": "2019-10-18T20:53:21.254639Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.0", - "dockerImage": "googleapis/artman@sha256:0f66008f69061ea6d41499e2a34da3fc64fc7c9798077e3a37158653a135d801" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "cc332bd19c2dd9640b025e5693e83a1b428d5dff", - "internalRef": "270834186" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-automl/synth.py b/google-cloud-automl/synth.py index 182e28d30cfe..f84f6c565f93 100644 --- a/google-cloud-automl/synth.py +++ b/google-cloud-automl/synth.py @@ -53,6 +53,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-automl.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update file paths in generated files s.replace( [ @@ -143,7 +153,7 @@ s.replace( 'google-cloud-automl.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2242 def escape_braces(match): @@ -188,13 +198,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-automl.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-automl.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-bigquery-data_transfer/.rubocop.yml b/google-cloud-bigquery-data_transfer/.rubocop.yml index d89ab702dd57..475279bf4ae8 100644 --- a/google-cloud-bigquery-data_transfer/.rubocop.yml +++ b/google-cloud-bigquery-data_transfer/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-bigquery-data_transfer.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-bigquery-data_transfer/README.md b/google-cloud-bigquery-data_transfer/README.md index 72faea92ca7f..03fc994b12ba 100644 --- a/google-cloud-bigquery-data_transfer/README.md +++ b/google-cloud-bigquery-data_transfer/README.md @@ -81,11 +81,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-bigquery-data_transfer/google-cloud-bigquery-data_transfer.gemspec b/google-cloud-bigquery-data_transfer/google-cloud-bigquery-data_transfer.gemspec index 4592a2f48201..0fa1a1ef17cd 100644 --- a/google-cloud-bigquery-data_transfer/google-cloud-bigquery-data_transfer.gemspec +++ b/google-cloud-bigquery-data_transfer/google-cloud-bigquery-data_transfer.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-bigquery-data_transfer/synth.metadata b/google-cloud-bigquery-data_transfer/synth.metadata index b351d87a29fd..e1e7db74e90d 100644 --- a/google-cloud-bigquery-data_transfer/synth.metadata +++ b/google-cloud-bigquery-data_transfer/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-27T10:41:08.525106Z", + "updateTime": "2019-10-18T20:53:55.505780Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "cd112d8d255e0099df053643d4bd12c228ef7b1b", - "internalRef": "271468707" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-bigquery-data_transfer/synth.py b/google-cloud-bigquery-data_transfer/synth.py index af2b8a01b85e..dfd6faa1cec6 100644 --- a/google-cloud-bigquery-data_transfer/synth.py +++ b/google-cloud-bigquery-data_transfer/synth.py @@ -42,6 +42,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-bigquery-data_transfer.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -85,7 +95,7 @@ s.replace( 'google-cloud-bigquery-data_transfer.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # PERMANENT: Use custom credentials env variable names s.replace( @@ -149,13 +159,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-bigquery-data_transfer.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-bigquery-data_transfer.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-bigquery/.rubocop.yml b/google-cloud-bigquery/.rubocop.yml index eadc462dd2a7..f507e83354ee 100644 --- a/google-cloud-bigquery/.rubocop.yml +++ b/google-cloud-bigquery/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -6,45 +9,29 @@ AllCops: - "google-cloud-bigquery.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: - Enabled: false -Style/TrivialAccessors: - Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 Metrics/ClassLength: Enabled: false Metrics/MethodLength: Max: 30 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Layout/AlignHash: - EnforcedHashRocketStyle: table - EnforcedColonStyle: table Naming/FileName: Exclude: - "lib/google-cloud-bigquery.rb" Naming/UncommunicativeMethodParamName: + Exclude: + - "lib/google/cloud/bigquery/external.rb" +Style/IfUnlessModifier: + Enabled: false +Style/NumericLiterals: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/SymbolArray: + Enabled: false +Style/WordArray: Enabled: false diff --git a/google-cloud-bigquery/CONTRIBUTING.md b/google-cloud-bigquery/CONTRIBUTING.md index 9eab47816ae1..3fa592004132 100644 --- a/google-cloud-bigquery/CONTRIBUTING.md +++ b/google-cloud-bigquery/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-bigquery console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-bigquery requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-bigquery requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-bigquery/README.md b/google-cloud-bigquery/README.md index b78b23914a43..b2e18a7f73ac 100644 --- a/google-cloud-bigquery/README.md +++ b/google-cloud-bigquery/README.md @@ -67,11 +67,11 @@ Google::Apis.logger = my_logger ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-bigquery/google-cloud-bigquery.gemspec b/google-cloud-bigquery/google-cloud-bigquery.gemspec index 57919ad22c4f..adf076614d8c 100644 --- a/google-cloud-bigquery/google-cloud-bigquery.gemspec +++ b/google-cloud-bigquery/google-cloud-bigquery.gemspec @@ -16,21 +16,21 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-api-client", "~> 0.31" - gem.add_dependency "googleauth", ">= 0.6.2", "< 0.10.0" + gem.add_dependency "google-api-client", "~> 0.33" + gem.add_dependency "googleauth", "~> 0.9" gem.add_dependency "concurrent-ruby", "~> 1.0" gem.add_dependency "mini_mime", "~> 1.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-bigtable/.rubocop.yml b/google-cloud-bigtable/.rubocop.yml index 8d1422eb584b..9acf5235bd37 100644 --- a/google-cloud-bigtable/.rubocop.yml +++ b/google-cloud-bigtable/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-bigtable.gemspec" @@ -13,38 +16,33 @@ AllCops: - "conformance/**/*" - "samples/**/*" - "support/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: true -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: +Layout/AlignHash: Enabled: false -Style/TrivialAccessors: +Metrics/ClassLength: Enabled: false Metrics/LineLength: Max: 80 IgnoredPatterns: ['(\A|\s)#'] -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: - Enabled: false Metrics/MethodLength: Max: 30 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-bigtable.rb" +Style/MethodCallWithArgsParentheses: + Enabled: false +Style/NumericLiterals: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/RedundantFreeze: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/UnpackFirst: + Enabled: false +Style/WordArray: + Enabled: false diff --git a/google-cloud-bigtable/CONTRIBUTING.md b/google-cloud-bigtable/CONTRIBUTING.md index db60cbc64885..b46d82ef6a04 100644 --- a/google-cloud-bigtable/CONTRIBUTING.md +++ b/google-cloud-bigtable/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-bigtable console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-bigtable requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-bigtable requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-bigtable/README.md b/google-cloud-bigtable/README.md index a88dc50e173f..d706ce112074 100644 --- a/google-cloud-bigtable/README.md +++ b/google-cloud-bigtable/README.md @@ -52,11 +52,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-bigtable/google-cloud-bigtable.gemspec b/google-cloud-bigtable/google-cloud-bigtable.gemspec index e50952ded6c0..8754e4bd75e0 100644 --- a/google-cloud-bigtable/google-cloud-bigtable.gemspec +++ b/google-cloud-bigtable/google-cloud-bigtable.gemspec @@ -19,17 +19,17 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "EMULATOR.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_dependency "google-cloud-core", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-container/.rubocop.yml b/google-cloud-container/.rubocop.yml index feb43f92703e..6b57765d6fc1 100644 --- a/google-cloud-container/.rubocop.yml +++ b/google-cloud-container/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-container.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-container/README.md b/google-cloud-container/README.md index ccb1a435fe24..19b717033854 100644 --- a/google-cloud-container/README.md +++ b/google-cloud-container/README.md @@ -70,11 +70,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-container/google-cloud-container.gemspec b/google-cloud-container/google-cloud-container.gemspec index 04ec14927765..139981af8d93 100644 --- a/google-cloud-container/google-cloud-container.gemspec +++ b/google-cloud-container/google-cloud-container.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-container/synth.metadata b/google-cloud-container/synth.metadata index cc953c676e37..1d94b99cb78b 100644 --- a/google-cloud-container/synth.metadata +++ b/google-cloud-container/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-07-17T10:38:16.629069Z", + "updateTime": "2019-10-18T20:54:38.950450Z", "sources": [ { "generator": { "name": "artman", - "version": "0.30.0", - "dockerImage": "googleapis/artman@sha256:a44d9fb6fe826ca0ea7d6f7be23c596346bed82ee513a0043f3c068279717439" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "96d5a05171e99b6a2378eb0a3423f765351878b7", - "internalRef": "258424288" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-container/synth.py b/google-cloud-container/synth.py index 6c7d95c71385..8f47964262ae 100644 --- a/google-cloud-container/synth.py +++ b/google-cloud-container/synth.py @@ -52,6 +52,16 @@ s.copy(v1_library / '.yardopts') s.copy(v1_library / 'google-cloud-container.gemspec', merge=ruby.merge_gemspec) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-container.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -95,7 +105,7 @@ s.replace( 'google-cloud-container.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # Fix for tests that assume protos implement to_hash s.replace( @@ -144,13 +154,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-container.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'lib/google/container/**/*.rb', 'require \'google/iam/v1/.*\n', diff --git a/google-cloud-container_analysis/.rubocop.yml b/google-cloud-container_analysis/.rubocop.yml index 9de7fa9e2964..acbfb7e1f52e 100644 --- a/google-cloud-container_analysis/.rubocop.yml +++ b/google-cloud-container_analysis/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "google-cloud-container_analysis.gemspec" - "lib/google/**/*" @@ -10,10 +12,6 @@ AllCops: Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses Naming/FileName: Exclude: - "lib/google-cloud-container_analysis.rb" diff --git a/google-cloud-container_analysis/README.md b/google-cloud-container_analysis/README.md index b1d04c6e6b5f..908b63d6707b 100644 --- a/google-cloud-container_analysis/README.md +++ b/google-cloud-container_analysis/README.md @@ -71,11 +71,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-container_analysis/google-cloud-container_analysis.gemspec b/google-cloud-container_analysis/google-cloud-container_analysis.gemspec index 14545b362d83..47c82cd0e458 100644 --- a/google-cloud-container_analysis/google-cloud-container_analysis.gemspec +++ b/google-cloud-container_analysis/google-cloud-container_analysis.gemspec @@ -19,15 +19,15 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "grafeas-client", "~> 0.3" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-container_analysis/synth.metadata b/google-cloud-container_analysis/synth.metadata index 679d3e1cf81f..ade299fe7a9a 100644 --- a/google-cloud-container_analysis/synth.metadata +++ b/google-cloud-container_analysis/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-26T10:39:24.238470Z", + "updateTime": "2019-10-17T22:52:50.381108Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.39.0", + "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "4c2ca81a0c976d4d37a8999984b7894d9af22124", - "internalRef": "271130964" + "sha": "a05f640453ac7b4e1361dfceeae15ee6e02317f1", + "internalRef": "275258873" } }, { diff --git a/google-cloud-container_analysis/synth.py b/google-cloud-container_analysis/synth.py index f477c4188f86..9a65e008f8f5 100644 --- a/google-cloud-container_analysis/synth.py +++ b/google-cloud-container_analysis/synth.py @@ -41,6 +41,9 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-container_analysis.gemspec') + # Hack grpc service class name and location s.replace( 'lib/google/devtools/containeranalysis/v1/containeranalysis_services_pb.rb', @@ -101,7 +104,7 @@ s.replace( 'google-cloud-container_analysis.gemspec', '\n\n gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', - '\n\n gem.add_dependency "grafeas-client", "~> 0.3"\n gem.add_dependency "google-gax", "~> 1.7"', + '\n\n gem.add_dependency "grafeas-client", "~> 0.3"\n gem.add_dependency "google-gax", "~> 1.8"', ) s.replace( 'lib/google/cloud/container_analysis.rb', @@ -181,13 +184,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-container_analysis.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-container_analysis.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-core/.rubocop.yml b/google-cloud-core/.rubocop.yml index 67b0f26f2253..fe613cc81713 100644 --- a/google-cloud-core/.rubocop.yml +++ b/google-cloud-core/.rubocop.yml @@ -1,48 +1,36 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-core.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/RescueModifier: +Layout/AlignHash: Exclude: - "lib/google/cloud/credentials.rb" -Style/MutableConstant: +Metrics/ClassLength: + Enabled: false +Naming/FileName: Exclude: - - "lib/google/cloud/credentials.rb" + - "lib/google-cloud-core.rb" Style/CaseEquality: Exclude: - "lib/google/cloud/config.rb" -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: +Style/IfUnlessModifier: Enabled: false -Metrics/MethodLength: - Max: 20 -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Style/MutableConstant: + Exclude: + - "lib/google/cloud/credentials.rb" +Style/SafeNavigation: Enabled: false -Naming/FileName: +Style/SymbolArray: Exclude: - - "lib/google-cloud-core.rb" -Style/RescueStandardError: + - "lib/google/cloud/config.rb" +Style/WordArray: Exclude: - "lib/google/cloud/credentials.rb" diff --git a/google-cloud-core/CONTRIBUTING.md b/google-cloud-core/CONTRIBUTING.md index ee1f2b070d6d..7f395efe1e68 100644 --- a/google-cloud-core/CONTRIBUTING.md +++ b/google-cloud-core/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-core/README.md b/google-cloud-core/README.md index f20807df4494..85c01c390e57 100644 --- a/google-cloud-core/README.md +++ b/google-cloud-core/README.md @@ -9,11 +9,11 @@ information about the individual google-cloud gems. ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-core/google-cloud-core.gemspec b/google-cloud-core/google-cloud-core.gemspec index 680b67df8a13..6acacac0c9db 100644 --- a/google-cloud-core/google-cloud-core.gemspec +++ b/google-cloud-core/google-cloud-core.gemspec @@ -17,17 +17,17 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "CONTRIBUTING.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-env", "~> 1.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-dataproc/.rubocop.yml b/google-cloud-dataproc/.rubocop.yml index ee931ff9f414..d01a8856f580 100644 --- a/google-cloud-dataproc/.rubocop.yml +++ b/google-cloud-dataproc/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-dataproc.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-dataproc/README.md b/google-cloud-dataproc/README.md index d6aa39892ed7..4f2f7e88529d 100644 --- a/google-cloud-dataproc/README.md +++ b/google-cloud-dataproc/README.md @@ -81,11 +81,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-dataproc/google-cloud-dataproc.gemspec b/google-cloud-dataproc/google-cloud-dataproc.gemspec index eab3c96e2651..8ff5264c462b 100644 --- a/google-cloud-dataproc/google-cloud-dataproc.gemspec +++ b/google-cloud-dataproc/google-cloud-dataproc.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-dataproc/synth.metadata b/google-cloud-dataproc/synth.metadata index 8ceede4b61b6..e54ae6247e9a 100644 --- a/google-cloud-dataproc/synth.metadata +++ b/google-cloud-dataproc/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-16T10:38:43.584156Z", + "updateTime": "2019-10-18T21:14:29.495560Z", "sources": [ { "generator": { "name": "artman", - "version": "0.39.0", - "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "c6e62c7e5e61e6dae7fdc3bc3de81f60e6a9445c", - "internalRef": "274798600" + "sha": "0e9a6d15fcb944ed40921ba0aad2082ee1bc7edd", + "internalRef": "275543900" } }, { diff --git a/google-cloud-dataproc/synth.py b/google-cloud-dataproc/synth.py index 76581f8b978f..a7944bcd2a2b 100644 --- a/google-cloud-dataproc/synth.py +++ b/google-cloud-dataproc/synth.py @@ -59,6 +59,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-dataproc.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update Authentication Guide for multi-service clients s.replace( 'AUTHENTICATION.md', @@ -109,7 +119,7 @@ s.replace( 'google-cloud-dataproc.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2242 def escape_braces(match): @@ -154,13 +164,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-dataproc.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - # https://github.com/googleapis/gapic-generator/issues/2492 s.replace( [ diff --git a/google-cloud-datastore/.rubocop.yml b/google-cloud-datastore/.rubocop.yml index 1d0bb8afe141..7a67b304ee5e 100644 --- a/google-cloud-datastore/.rubocop.yml +++ b/google-cloud-datastore/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -7,38 +10,26 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: +Layout/AlignHash: Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Metrics/ClassLength: Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-datastore.rb" +Naming/RescuedExceptionsVariableName: + Enabled: false Naming/UncommunicativeMethodParamName: Enabled: false +Style/ConditionalAssignment: + Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false diff --git a/google-cloud-datastore/CONTRIBUTING.md b/google-cloud-datastore/CONTRIBUTING.md index ad6f4e5eb354..a28203fe465a 100644 --- a/google-cloud-datastore/CONTRIBUTING.md +++ b/google-cloud-datastore/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-datastore console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-datastore requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-datastore requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-datastore/README.md b/google-cloud-datastore/README.md index b04cb8701f55..07c748921f51 100644 --- a/google-cloud-datastore/README.md +++ b/google-cloud-datastore/README.md @@ -71,11 +71,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-datastore/google-cloud-datastore.gemspec b/google-cloud-datastore/google-cloud-datastore.gemspec index 646c8384ef07..1fcaeb4b6af0 100644 --- a/google-cloud-datastore/google-cloud-datastore.gemspec +++ b/google-cloud-datastore/google-cloud-datastore.gemspec @@ -16,19 +16,19 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "EMULATOR.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "google-protobuf", "~> 3.3" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-debugger/.rubocop.yml b/google-cloud-debugger/.rubocop.yml index 5a701295ce73..14f7f231c8e1 100644 --- a/google-cloud-debugger/.rubocop.yml +++ b/google-cloud-debugger/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -11,49 +14,41 @@ AllCops: - "support/**/*" - "test/**/*" - "tmp/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: +Layout/AlignHash: Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 +Layout/SpaceInsideStringInterpolation: + Enabled: false +Lint/UnifiedInteger: + Exclude: + - "lib/google/cloud/debugger/breakpoint/evaluator.rb" +Lint/InheritException: + Exclude: + - "lib/google/cloud/debugger/breakpoint/evaluator.rb" Metrics/BlockLength: Exclude: - "lib/google-cloud-debugger.rb" Metrics/ClassLength: Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: +Naming/FileName: + Exclude: + - "lib/google-cloud-debugger.rb" +Style/ConditionalAssignment: + Enabled: false +Style/EmptyMethod: Enabled: false -Metrics/ModuleLength: +Style/IfUnlessModifier: Enabled: false -Layout/EmptyLineAfterGuardClause: +Style/NumericLiterals: Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/SymbolArray: + Enabled: false +Style/WordArray: Enabled: false -Naming/FileName: - Exclude: - - "lib/google-cloud-debugger.rb" -Lint/UnifiedInteger: - Exclude: - - "lib/google/cloud/debugger/breakpoint/evaluator.rb" -Lint/InheritException: - Exclude: - - "lib/google/cloud/debugger/breakpoint/evaluator.rb" diff --git a/google-cloud-debugger/CONTRIBUTING.md b/google-cloud-debugger/CONTRIBUTING.md index 1d02b1649f79..471c54521a38 100644 --- a/google-cloud-debugger/CONTRIBUTING.md +++ b/google-cloud-debugger/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-debugger console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-debugger requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-debugger requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-debugger/README.md b/google-cloud-debugger/README.md index f7a649a0d27a..6f9c624f5821 100644 --- a/google-cloud-debugger/README.md +++ b/google-cloud-debugger/README.md @@ -246,11 +246,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-debugger/google-cloud-debugger.gemspec b/google-cloud-debugger/google-cloud-debugger.gemspec index 4d9f60b2954f..302752f48a85 100644 --- a/google-cloud-debugger/google-cloud-debugger.gemspec +++ b/google-cloud-debugger/google-cloud-debugger.gemspec @@ -16,24 +16,24 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "INSTRUMENTATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.2.0" + gem.required_ruby_version = ">= 2.4" gem.extensions << "ext/google/cloud/debugger/debugger_c/extconf.rb" gem.add_dependency "binding_of_caller", "~> 0.7" gem.add_dependency "google-cloud-core", "~> 1.2" gem.add_dependency "google-cloud-logging", "~> 1.0" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "stackdriver-core", "~> 1.3" gem.add_dependency "concurrent-ruby", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.8" diff --git a/google-cloud-dialogflow/.rubocop.yml b/google-cloud-dialogflow/.rubocop.yml index 3d3a2c6bbdff..0657dcfeccb7 100644 --- a/google-cloud-dialogflow/.rubocop.yml +++ b/google-cloud-dialogflow/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-dialogflow.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-dialogflow/README.md b/google-cloud-dialogflow/README.md index 19c501b9bea2..6bbc9a6b95b3 100644 --- a/google-cloud-dialogflow/README.md +++ b/google-cloud-dialogflow/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-dialogflow/google-cloud-dialogflow.gemspec b/google-cloud-dialogflow/google-cloud-dialogflow.gemspec index 194b728de0f2..50c365cf9007 100644 --- a/google-cloud-dialogflow/google-cloud-dialogflow.gemspec +++ b/google-cloud-dialogflow/google-cloud-dialogflow.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-dialogflow/synth.metadata b/google-cloud-dialogflow/synth.metadata index da7280400ae5..f8a82c909738 100644 --- a/google-cloud-dialogflow/synth.metadata +++ b/google-cloud-dialogflow/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-04T10:39:01.671903Z", + "updateTime": "2019-10-18T20:56:41.530938Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "d9576d95b44f64fb0e3da4760adfc4a24fa1faab", - "internalRef": "272741510" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-dialogflow/synth.py b/google-cloud-dialogflow/synth.py index 68a52426d2de..912c746255d1 100644 --- a/google-cloud-dialogflow/synth.py +++ b/google-cloud-dialogflow/synth.py @@ -41,6 +41,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-dialogflow.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update Authentication Guide for multi-service clients s.replace( 'AUTHENTICATION.md', @@ -129,18 +139,11 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-dialogflow.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-dialogflow.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-dlp/.rubocop.yml b/google-cloud-dlp/.rubocop.yml index cdff7089d4c1..cadc97022782 100644 --- a/google-cloud-dlp/.rubocop.yml +++ b/google-cloud-dlp/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-dlp.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-dlp/README.md b/google-cloud-dlp/README.md index 705c6b2378e8..9289ab98a1c1 100644 --- a/google-cloud-dlp/README.md +++ b/google-cloud-dlp/README.md @@ -60,11 +60,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-dlp/google-cloud-dlp.gemspec b/google-cloud-dlp/google-cloud-dlp.gemspec index fe3283d3ab9d..5633a592efc0 100644 --- a/google-cloud-dlp/google-cloud-dlp.gemspec +++ b/google-cloud-dlp/google-cloud-dlp.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-dlp/synth.metadata b/google-cloud-dlp/synth.metadata index 0a384f2e2c5a..624f38965c0e 100644 --- a/google-cloud-dlp/synth.metadata +++ b/google-cloud-dlp/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-08-27T10:40:15.617151Z", + "updateTime": "2019-10-18T20:57:03.089537Z", "sources": [ { "generator": { "name": "artman", - "version": "0.35.1", - "dockerImage": "googleapis/artman@sha256:b11c7ea0d0831c54016fb50f4b796d24d1971439b30fbc32a369ba1ac887c384" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "650caad718bb063f189405c23972dc9818886358", - "internalRef": "265565344" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-dlp/synth.py b/google-cloud-dlp/synth.py index 9f23422347d6..00a297cd181f 100644 --- a/google-cloud-dlp/synth.py +++ b/google-cloud-dlp/synth.py @@ -40,6 +40,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-dlp.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -124,18 +134,11 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-dlp.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-dlp.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-dns/.rubocop.yml b/google-cloud-dns/.rubocop.yml index d8674624b81b..9c8cad241171 100644 --- a/google-cloud-dns/.rubocop.yml +++ b/google-cloud-dns/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -5,31 +8,24 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 20 -Metrics/ParameterLists: +Layout/AlignHash: Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Metrics/ClassLength: Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-dns.rb" +Style/IfUnlessModifier: + Enabled: false +Style/MethodCallWithArgsParentheses: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/WordArray: + Enabled: false diff --git a/google-cloud-dns/CONTRIBUTING.md b/google-cloud-dns/CONTRIBUTING.md index b053663d93e4..530fee255071 100644 --- a/google-cloud-dns/CONTRIBUTING.md +++ b/google-cloud-dns/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-dns console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-dns requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-dns requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-dns/README.md b/google-cloud-dns/README.md index b45556a5abf7..d197421ae173 100644 --- a/google-cloud-dns/README.md +++ b/google-cloud-dns/README.md @@ -60,11 +60,11 @@ Google::Apis.logger = my_logger ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-dns/google-cloud-dns.gemspec b/google-cloud-dns/google-cloud-dns.gemspec index 359183b3c117..856a590c9e5a 100644 --- a/google-cloud-dns/google-cloud-dns.gemspec +++ b/google-cloud-dns/google-cloud-dns.gemspec @@ -16,20 +16,20 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-api-client", ">= 0.30.4", "< 1.0" - gem.add_dependency "googleauth", ">= 0.6.2", "< 0.10.0" + gem.add_dependency "google-api-client", "~> 0.33" + gem.add_dependency "googleauth", "~> 0.9" gem.add_dependency "zonefile", "~> 1.04" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-env/.rubocop.yml b/google-cloud-env/.rubocop.yml index 165959d80ddd..3c25065a0766 100644 --- a/google-cloud-env/.rubocop.yml +++ b/google-cloud-env/.rubocop.yml @@ -1,36 +1,19 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-env.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 Metrics/ClassLength: Enabled: false -Metrics/MethodLength: - Max: 20 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-env.rb" +Style/IfUnlessModifier: + Enabled: false diff --git a/google-cloud-env/CONTRIBUTING.md b/google-cloud-env/CONTRIBUTING.md index 103e6321cf7c..3d57cbc3548a 100644 --- a/google-cloud-env/CONTRIBUTING.md +++ b/google-cloud-env/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-env console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-env requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-env requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-env/README.md b/google-cloud-env/README.md index d1fe00818a2e..7deb4e50d6b9 100644 --- a/google-cloud-env/README.md +++ b/google-cloud-env/README.md @@ -7,11 +7,11 @@ apps running on Google Cloud Platform. ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-env/google-cloud-env.gemspec b/google-cloud-env/google-cloud-env.gemspec index a7071d617db2..da4b7788c26c 100644 --- a/google-cloud-env/google-cloud-env.gemspec +++ b/google-cloud-env/google-cloud-env.gemspec @@ -16,17 +16,17 @@ Gem::Specification.new do |gem| ["README.md", "CONTRIBUTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "faraday", "~> 0.11" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-error_reporting/.rubocop.yml b/google-cloud-error_reporting/.rubocop.yml index 8ac256dd620a..5ec895ba7113 100644 --- a/google-cloud-error_reporting/.rubocop.yml +++ b/google-cloud-error_reporting/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -9,49 +12,31 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/ClassVars: +Layout/AlignHash: Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 +Lint/RescueException: + Exclude: + - "lib/google/cloud/error_reporting/middleware.rb" +Lint/AmbiguousOperator: + Exclude: + - "lib/google/cloud/error_reporting/project.rb" Metrics/BlockLength: Exclude: - "lib/google-cloud-error_reporting.rb" Metrics/ClassLength: Enabled: false -Metrics/MethodLength: - Max: 20 +Naming/FileName: Exclude: - - "lib/google/cloud/error_reporting.rb" -Metrics/ParameterLists: + - "lib/google-cloud-error_reporting.rb" +Naming/RescuedExceptionsVariableName: Enabled: false -Layout/EmptyLineAfterGuardClause: +Style/IfUnlessModifier: Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: Enabled: false -Naming/FileName: - Exclude: - - "lib/google-cloud-error_reporting.rb" -Lint/RescueException: - Exclude: - - "lib/google/cloud/error_reporting/middleware.rb" -Lint/AmbiguousOperator: - Exclude: - - "lib/google/cloud/error_reporting/project.rb" diff --git a/google-cloud-error_reporting/CONTRIBUTING.md b/google-cloud-error_reporting/CONTRIBUTING.md index 7b6f0cc8a6f2..ec33a895baad 100644 --- a/google-cloud-error_reporting/CONTRIBUTING.md +++ b/google-cloud-error_reporting/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-error_reporting console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-error_reporting requires Ruby 2.3+. You may choose +1. Install Ruby. google-cloud-error_reporting requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-error_reporting/README.md b/google-cloud-error_reporting/README.md index 1b63d7d66521..bc903c5a0d8a 100644 --- a/google-cloud-error_reporting/README.md +++ b/google-cloud-error_reporting/README.md @@ -214,11 +214,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-error_reporting/google-cloud-error_reporting.gemspec b/google-cloud-error_reporting/google-cloud-error_reporting.gemspec index 12f7716377d6..86d5f0ea862b 100644 --- a/google-cloud-error_reporting/google-cloud-error_reporting.gemspec +++ b/google-cloud-error_reporting/google-cloud-error_reporting.gemspec @@ -18,19 +18,19 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "INSTRUMENTATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" gem.add_dependency "stackdriver-core", "~> 1.3" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "concurrent-ruby", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "railties", "~> 4.0" gem.add_development_dependency "rack", ">= 0.1" gem.add_development_dependency "simplecov", "~> 0.9" diff --git a/google-cloud-error_reporting/lib/google/cloud/error_reporting/error_event.rb b/google-cloud-error_reporting/lib/google/cloud/error_reporting/error_event.rb index a79cdc6a6ff8..1eacee85f408 100644 --- a/google-cloud-error_reporting/lib/google/cloud/error_reporting/error_event.rb +++ b/google-cloud-error_reporting/lib/google/cloud/error_reporting/error_event.rb @@ -271,8 +271,6 @@ def service_context_grpc ) end - # rubocop:disable Metrics/AbcSize - ## # @private Formats the http request context as a # Google::Devtools::Clouderrorreporting::V1beta1::HttpRequestContext @@ -290,8 +288,6 @@ def http_request_grpc ) end - # rubocop:enable Metrics/AbcSize - ## # @private Formats the source location as a # Google::Devtools::Clouderrorreporting::V1beta1::SourceLocation diff --git a/google-cloud-firestore/.rubocop.yml b/google-cloud-firestore/.rubocop.yml index 0752e0656f22..25e5acf83074 100644 --- a/google-cloud-firestore/.rubocop.yml +++ b/google-cloud-firestore/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "benchmark/**/*" @@ -14,48 +17,28 @@ AllCops: - "acceptance/**/*" - "conformance/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/RescueModifier: - Enabled: false -Style/TrivialAccessors: +Metrics/ClassLength: Enabled: false Metrics/CyclomaticComplexity: Max: 15 Metrics/PerceivedComplexity: Max: 15 -Metrics/AbcSize: - Max: 30 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Layout/AlignHash: - EnforcedHashRocketStyle: table - EnforcedColonStyle: table Naming/FileName: Exclude: - "lib/google-cloud-firestore.rb" -Style/RescueStandardError: - Exclude: - - "lib/google/cloud/firestore/client.rb" +Naming/RescuedExceptionsVariableName: + Enabled: false Naming/UncommunicativeMethodParamName: Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/SymbolArray: + Enabled: false diff --git a/google-cloud-firestore/CONTRIBUTING.md b/google-cloud-firestore/CONTRIBUTING.md index c4d13a9e4d86..02e89aee0cfd 100644 --- a/google-cloud-firestore/CONTRIBUTING.md +++ b/google-cloud-firestore/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-firestore console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-firestore requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-firestore requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-firestore/README.md b/google-cloud-firestore/README.md index 7289d4930f36..fa74e7c8126b 100644 --- a/google-cloud-firestore/README.md +++ b/google-cloud-firestore/README.md @@ -50,11 +50,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-firestore/google-cloud-firestore.gemspec b/google-cloud-firestore/google-cloud-firestore.gemspec index 7e31e969e564..e5c4e80e3a64 100644 --- a/google-cloud-firestore/google-cloud-firestore.gemspec +++ b/google-cloud-firestore/google-cloud-firestore.gemspec @@ -17,20 +17,20 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "EMULATOR.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "concurrent-ruby", "~> 1.0" gem.add_dependency "rbtree", "~> 0.4.2" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-irm/.rubocop.yml b/google-cloud-irm/.rubocop.yml index d3275650594f..547c099986de 100644 --- a/google-cloud-irm/.rubocop.yml +++ b/google-cloud-irm/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-irm.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-irm/README.md b/google-cloud-irm/README.md index aff796eff583..6f71a6ff57a6 100644 --- a/google-cloud-irm/README.md +++ b/google-cloud-irm/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-irm/google-cloud-irm.gemspec b/google-cloud-irm/google-cloud-irm.gemspec index 04e495686b1d..0e155e223117 100644 --- a/google-cloud-irm/google-cloud-irm.gemspec +++ b/google-cloud-irm/google-cloud-irm.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-irm/synth.metadata b/google-cloud-irm/synth.metadata index d3760d8aca14..372bb074588c 100644 --- a/google-cloud-irm/synth.metadata +++ b/google-cloud-irm/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-08-27T10:41:12.104396Z", + "updateTime": "2019-10-18T20:57:40.781414Z", "sources": [ { "generator": { "name": "artman", - "version": "0.35.1", - "dockerImage": "googleapis/artman@sha256:b11c7ea0d0831c54016fb50f4b796d24d1971439b30fbc32a369ba1ac887c384" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "650caad718bb063f189405c23972dc9818886358", - "internalRef": "265565344" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-irm/synth.py b/google-cloud-irm/synth.py index 920abf8da27c..05c689343be9 100644 --- a/google-cloud-irm/synth.py +++ b/google-cloud-irm/synth.py @@ -41,6 +41,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-irm.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -84,7 +94,7 @@ s.replace( 'google-cloud-irm.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2243 s.replace( @@ -116,13 +126,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-irm.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - # Require the helpers file s.replace( f'lib/google/cloud/irm/v1alpha2.rb', diff --git a/google-cloud-kms/.rubocop.yml b/google-cloud-kms/.rubocop.yml index 2325ed066fa6..e7ec0ad15aab 100644 --- a/google-cloud-kms/.rubocop.yml +++ b/google-cloud-kms/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-kms.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-kms/README.md b/google-cloud-kms/README.md index 803e02aac3cd..090f153f33aa 100644 --- a/google-cloud-kms/README.md +++ b/google-cloud-kms/README.md @@ -80,11 +80,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-kms/google-cloud-kms.gemspec b/google-cloud-kms/google-cloud-kms.gemspec index b529b09861ab..af127b115049 100644 --- a/google-cloud-kms/google-cloud-kms.gemspec +++ b/google-cloud-kms/google-cloud-kms.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-kms/synth.metadata b/google-cloud-kms/synth.metadata index c3b625719be1..0631e9a6acd4 100644 --- a/google-cloud-kms/synth.metadata +++ b/google-cloud-kms/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-08-27T10:41:29.346426Z", + "updateTime": "2019-10-18T20:58:13.507924Z", "sources": [ { "generator": { "name": "artman", - "version": "0.35.1", - "dockerImage": "googleapis/artman@sha256:b11c7ea0d0831c54016fb50f4b796d24d1971439b30fbc32a369ba1ac887c384" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "650caad718bb063f189405c23972dc9818886358", - "internalRef": "265565344" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-kms/synth.py b/google-cloud-kms/synth.py index 4f9eb78ab5d4..9c4901303e4b 100644 --- a/google-cloud-kms/synth.py +++ b/google-cloud-kms/synth.py @@ -43,6 +43,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-kms.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # PERMANENT: API name for cloudkms s.replace( [ @@ -123,7 +133,7 @@ s.replace( 'google-cloud-kms.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2242 def escape_braces(match): @@ -168,13 +178,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-kms.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - # Require the helpers file s.replace( f'lib/google/cloud/kms/v1.rb', diff --git a/google-cloud-language/.rubocop.yml b/google-cloud-language/.rubocop.yml index b27b959e75ae..479e3cf32168 100644 --- a/google-cloud-language/.rubocop.yml +++ b/google-cloud-language/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-language.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-language/README.md b/google-cloud-language/README.md index ab9bef092285..73d4748df065 100644 --- a/google-cloud-language/README.md +++ b/google-cloud-language/README.md @@ -60,11 +60,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-language/google-cloud-language.gemspec b/google-cloud-language/google-cloud-language.gemspec index 7c5ab4201c25..2ec579222cc6 100644 --- a/google-cloud-language/google-cloud-language.gemspec +++ b/google-cloud-language/google-cloud-language.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-language/synth.metadata b/google-cloud-language/synth.metadata index 59a493a31cef..bccabbe2b13c 100644 --- a/google-cloud-language/synth.metadata +++ b/google-cloud-language/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-01T10:39:40.223178Z", + "updateTime": "2019-10-18T20:58:39.798138Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "ce3c574d1266026cebea3a893247790bd68191c2", - "internalRef": "272147209" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-language/synth.py b/google-cloud-language/synth.py index e9d087298925..e50d3dfab941 100644 --- a/google-cloud-language/synth.py +++ b/google-cloud-language/synth.py @@ -54,6 +54,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-language.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -136,13 +146,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-language.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'lib/google/cloud/language/**/credentials.rb', '\n'.join([ @@ -156,7 +159,7 @@ 'google-cloud-language.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-logging/.rubocop.yml b/google-cloud-logging/.rubocop.yml index 52a4ea020cbe..9719abdbf9b8 100644 --- a/google-cloud-logging/.rubocop.yml +++ b/google-cloud-logging/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -9,50 +12,40 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: - Enabled: false -Style/CaseEquality: +Lint/RescueException: Exclude: - - "lib/google/cloud/logging/middleware.rb" -Metrics/CyclomaticComplexity: - Max: 12 -Metrics/PerceivedComplexity: - Max: 12 -Metrics/AbcSize: - Max: 28 + - "lib/google/cloud/logging/rails.rb" Metrics/BlockLength: Exclude: - "lib/google-cloud-logging.rb" Metrics/ClassLength: Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Layout/AlignHash: - EnforcedHashRocketStyle: table - EnforcedColonStyle: table +Metrics/CyclomaticComplexity: + Max: 15 +Metrics/PerceivedComplexity: + Max: 15 Naming/FileName: Exclude: - "lib/google-cloud-logging.rb" -Lint/RescueException: - Exclude: - - "lib/google/cloud/logging/rails.rb" +Style/CaseEquality: + Enabled: false +Style/ConditionalAssignment: + Enabled: false +Style/EmptyMethod: + Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/MultilineWhenThen: + Enabled: false +Style/NumericLiterals: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/SymbolArray: + Enabled: false diff --git a/google-cloud-logging/CONTRIBUTING.md b/google-cloud-logging/CONTRIBUTING.md index e3ee9d3ba85f..32e450919229 100644 --- a/google-cloud-logging/CONTRIBUTING.md +++ b/google-cloud-logging/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-logging console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-logging requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-logging requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-logging/README.md b/google-cloud-logging/README.md index 6960d0b83fa7..c34dcc755d74 100644 --- a/google-cloud-logging/README.md +++ b/google-cloud-logging/README.md @@ -180,11 +180,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-logging/google-cloud-logging.gemspec b/google-cloud-logging/google-cloud-logging.gemspec index 2cb938a0ce9e..ed00890eb6e9 100644 --- a/google-cloud-logging/google-cloud-logging.gemspec +++ b/google-cloud-logging/google-cloud-logging.gemspec @@ -16,21 +16,21 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "INSTRUMENTATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" gem.add_dependency "stackdriver-core", "~> 1.3" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos-types", ">= 1.0.2" gem.add_dependency "concurrent-ruby", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-logging/lib/google/cloud/logging/project.rb b/google-cloud-logging/lib/google/cloud/logging/project.rb index 2125cc871837..a589438f6630 100644 --- a/google-cloud-logging/lib/google/cloud/logging/project.rb +++ b/google-cloud-logging/lib/google/cloud/logging/project.rb @@ -615,9 +615,6 @@ def sinks token: nil, max: nil end alias find_sinks sinks - # rubocop:disable Metrics/LineLength - # overload is too long... - ## # Creates a new project sink. When you create a sink, only new log # entries that match the sink's filter are exported. Stackdriver Logging @@ -701,8 +698,6 @@ def create_sink name, destination, filter: nil, end alias new_sink create_sink - # rubocop:enable Metrics/LineLength - ## # Retrieves a sink by name. # diff --git a/google-cloud-monitoring/.rubocop.yml b/google-cloud-monitoring/.rubocop.yml index 94a46d326268..c43a859b9744 100644 --- a/google-cloud-monitoring/.rubocop.yml +++ b/google-cloud-monitoring/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-monitoring.gemspec" @@ -5,16 +8,10 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses - Naming/FileName: Exclude: - "lib/google-cloud-monitoring.rb" diff --git a/google-cloud-monitoring/README.md b/google-cloud-monitoring/README.md index df3105e36754..5cf622dcc632 100644 --- a/google-cloud-monitoring/README.md +++ b/google-cloud-monitoring/README.md @@ -82,11 +82,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-monitoring/google-cloud-monitoring.gemspec b/google-cloud-monitoring/google-cloud-monitoring.gemspec index 61ad7efe8999..319e6a546c86 100644 --- a/google-cloud-monitoring/google-cloud-monitoring.gemspec +++ b/google-cloud-monitoring/google-cloud-monitoring.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos-types", ">= 1.0.2" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-monitoring/synth.metadata b/google-cloud-monitoring/synth.metadata index 63750925f816..fa098a1f0252 100644 --- a/google-cloud-monitoring/synth.metadata +++ b/google-cloud-monitoring/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-12T10:44:08.567973Z", + "updateTime": "2019-10-18T20:59:15.480372Z", "sources": [ { "generator": { "name": "artman", - "version": "0.39.0", - "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "af8dd2c1750558b538eaa6bdaa3bc899079533ee", - "internalRef": "274260771" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-monitoring/synth.py b/google-cloud-monitoring/synth.py index a7d25751e87b..038728143c02 100644 --- a/google-cloud-monitoring/synth.py +++ b/google-cloud-monitoring/synth.py @@ -43,6 +43,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-monitoring.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update Authentication Guide for multi-service clients s.replace( 'AUTHENTICATION.md', @@ -95,7 +105,7 @@ s.replace( 'google-cloud-monitoring.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', - '\n gem.add_dependency "google-gax", "~> 1.7"\n gem.add_dependency "googleapis-common-protos-types", ">= 1.0.2"') + '\n gem.add_dependency "google-gax", "~> 1.8"\n gem.add_dependency "googleapis-common-protos-types", ">= 1.0.2"') # https://github.com/googleapis/gapic-generator/issues/2242 def escape_braces(match): @@ -140,13 +150,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-monitoring.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-monitoring.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-os_login/.rubocop.yml b/google-cloud-os_login/.rubocop.yml index 040d31f51902..bc91158043f2 100644 --- a/google-cloud-os_login/.rubocop.yml +++ b/google-cloud-os_login/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-os_login.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-os_login/README.md b/google-cloud-os_login/README.md index 2a5fe0c6376b..36c22a9348d9 100644 --- a/google-cloud-os_login/README.md +++ b/google-cloud-os_login/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-os_login/google-cloud-os_login.gemspec b/google-cloud-os_login/google-cloud-os_login.gemspec index 5245a4e04dab..caca84b0d81a 100644 --- a/google-cloud-os_login/google-cloud-os_login.gemspec +++ b/google-cloud-os_login/google-cloud-os_login.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-os_login/synth.metadata b/google-cloud-os_login/synth.metadata index 78dc5ff92630..3f8931c41101 100644 --- a/google-cloud-os_login/synth.metadata +++ b/google-cloud-os_login/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-09T10:43:05.529744Z", + "updateTime": "2019-10-18T20:59:55.712866Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "2dec8f98383214ad4fafa7680eb0cc46d6531976", - "internalRef": "273619851" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-os_login/synth.py b/google-cloud-os_login/synth.py index 70f6c92a1c24..7f645ef356f6 100644 --- a/google-cloud-os_login/synth.py +++ b/google-cloud-os_login/synth.py @@ -56,6 +56,16 @@ s.copy(v1beta_library / 'lib/google/cloud/oslogin/v1beta') s.copy(v1beta_library / 'test/google/cloud/os_login/v1beta') +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-os_login.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # PERMANENT: API name for oslogin s.replace( [ @@ -109,7 +119,7 @@ s.replace( 'google-cloud-os_login.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2196 s.replace( @@ -165,13 +175,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-os_login.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-os_login.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-phishing_protection/.rubocop.yml b/google-cloud-phishing_protection/.rubocop.yml index 33b4d7be14fe..125845bd6166 100644 --- a/google-cloud-phishing_protection/.rubocop.yml +++ b/google-cloud-phishing_protection/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "google-cloud-phishing_protection.gemspec" - "lib/google/**/*" @@ -9,8 +11,3 @@ AllCops: Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-phishing_protection/README.md b/google-cloud-phishing_protection/README.md index 843bf2dc4789..55aa65e0fcee 100644 --- a/google-cloud-phishing_protection/README.md +++ b/google-cloud-phishing_protection/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-phishing_protection/google-cloud-phishing_protection.gemspec b/google-cloud-phishing_protection/google-cloud-phishing_protection.gemspec index 4135c6c6d3d5..1adac4d213c2 100644 --- a/google-cloud-phishing_protection/google-cloud-phishing_protection.gemspec +++ b/google-cloud-phishing_protection/google-cloud-phishing_protection.gemspec @@ -19,15 +19,15 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-phishing_protection/synth.metadata b/google-cloud-phishing_protection/synth.metadata index 5625ca2b87c6..64f30f018932 100644 --- a/google-cloud-phishing_protection/synth.metadata +++ b/google-cloud-phishing_protection/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-26T10:42:04.247542Z", + "updateTime": "2019-10-18T21:00:32.496659Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "4c2ca81a0c976d4d37a8999984b7894d9af22124", - "internalRef": "271130964" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-phishing_protection/synth.py b/google-cloud-phishing_protection/synth.py index c070a856be41..47375d8c80f8 100644 --- a/google-cloud-phishing_protection/synth.py +++ b/google-cloud-phishing_protection/synth.py @@ -44,6 +44,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-phishing_protection.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -128,19 +138,12 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-phishing_protection.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - # https://github.com/googleapis/gapic-generator/issues/2180 s.replace( 'google-cloud-phishing_protection.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"', ' gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9"' ]) diff --git a/google-cloud-pubsub/.rubocop.yml b/google-cloud-pubsub/.rubocop.yml index f7c7f126dec1..4c568495ca01 100644 --- a/google-cloud-pubsub/.rubocop.yml +++ b/google-cloud-pubsub/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -9,45 +12,25 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: - Enabled: false -Style/TrivialAccessors: - Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 Metrics/ClassLength: Enabled: false Metrics/MethodLength: - Max: 25 Exclude: - "lib/google/cloud/pubsub.rb" -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Layout/AlignHash: - EnforcedHashRocketStyle: table - EnforcedColonStyle: table Naming/FileName: Exclude: - "lib/google-cloud-pubsub.rb" +Naming/RescuedExceptionsVariableName: + Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/NumericLiterals: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false diff --git a/google-cloud-pubsub/CONTRIBUTING.md b/google-cloud-pubsub/CONTRIBUTING.md index 7ff8ddf34470..5cf4fb88ac36 100644 --- a/google-cloud-pubsub/CONTRIBUTING.md +++ b/google-cloud-pubsub/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-pubsub console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-pubsub requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-pubsub requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-pubsub/README.md b/google-cloud-pubsub/README.md index 5d9b4b8ca536..476c3b68c0c2 100644 --- a/google-cloud-pubsub/README.md +++ b/google-cloud-pubsub/README.md @@ -74,11 +74,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-pubsub/google-cloud-pubsub.gemspec b/google-cloud-pubsub/google-cloud-pubsub.gemspec index 44cfd7cea2b1..963363bd1036 100644 --- a/google-cloud-pubsub/google-cloud-pubsub.gemspec +++ b/google-cloud-pubsub/google-cloud-pubsub.gemspec @@ -16,21 +16,21 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "EMULATOR.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_dependency "concurrent-ruby", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-recaptcha_enterprise/.rubocop.yml b/google-cloud-recaptcha_enterprise/.rubocop.yml index 4ea1d3c6a12c..a2daaaa6dd89 100644 --- a/google-cloud-recaptcha_enterprise/.rubocop.yml +++ b/google-cloud-recaptcha_enterprise/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "google-cloud-recaptcha_enterprise.gemspec" - "lib/google/**/*" @@ -9,8 +11,3 @@ AllCops: Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-recaptcha_enterprise/README.md b/google-cloud-recaptcha_enterprise/README.md index 5077b28f953d..36e77ada1612 100644 --- a/google-cloud-recaptcha_enterprise/README.md +++ b/google-cloud-recaptcha_enterprise/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-recaptcha_enterprise/google-cloud-recaptcha_enterprise.gemspec b/google-cloud-recaptcha_enterprise/google-cloud-recaptcha_enterprise.gemspec index c6cfbcca297d..2c82e57a2c3d 100644 --- a/google-cloud-recaptcha_enterprise/google-cloud-recaptcha_enterprise.gemspec +++ b/google-cloud-recaptcha_enterprise/google-cloud-recaptcha_enterprise.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-recaptcha_enterprise/synth.metadata b/google-cloud-recaptcha_enterprise/synth.metadata index b84e31215f4a..65c17f431052 100644 --- a/google-cloud-recaptcha_enterprise/synth.metadata +++ b/google-cloud-recaptcha_enterprise/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-25T10:41:14.650537Z", + "updateTime": "2019-10-18T21:00:57.092055Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "662bfb2666b4310027475928234f1355dcf8a935", - "internalRef": "270960038" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-recaptcha_enterprise/synth.py b/google-cloud-recaptcha_enterprise/synth.py index c9b88b5014c2..4a105f9a8494 100644 --- a/google-cloud-recaptcha_enterprise/synth.py +++ b/google-cloud-recaptcha_enterprise/synth.py @@ -43,6 +43,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-recaptcha_enterprise.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -88,7 +98,7 @@ s.replace( 'google-cloud-recaptcha_enterprise.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9"\n\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9"\n\n') # https://github.com/googleapis/gapic-generator/issues/2242 def escape_braces(match): @@ -133,13 +143,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-recaptcha_enterprise.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - os.rename( 'lib/google/cloud/recaptcha_enterprise/v1beta1/recaptcha_enterprise_service_v1_beta1_client_config.json', 'lib/google/cloud/recaptcha_enterprise/v1beta1/recaptcha_enterprise_client_config.json' diff --git a/google-cloud-redis/.rubocop.yml b/google-cloud-redis/.rubocop.yml index b64bd7d5a373..449fa43b5f73 100644 --- a/google-cloud-redis/.rubocop.yml +++ b/google-cloud-redis/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-redis.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-redis/README.md b/google-cloud-redis/README.md index bc53b9b7b5f4..f5739d8175d2 100644 --- a/google-cloud-redis/README.md +++ b/google-cloud-redis/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-redis/google-cloud-redis.gemspec b/google-cloud-redis/google-cloud-redis.gemspec index c391992b0a35..8f253b54df90 100644 --- a/google-cloud-redis/google-cloud-redis.gemspec +++ b/google-cloud-redis/google-cloud-redis.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-redis/synth.metadata b/google-cloud-redis/synth.metadata index 0f2779fc2654..cd84c3d8c61e 100644 --- a/google-cloud-redis/synth.metadata +++ b/google-cloud-redis/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-08T10:41:12.422857Z", + "updateTime": "2019-10-18T21:01:29.331829Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "122bdbf877ad87439f8dd9d1474a8e5dde188087", - "internalRef": "273381131" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-redis/synth.py b/google-cloud-redis/synth.py index 21c6db54c15e..ab919a366953 100644 --- a/google-cloud-redis/synth.py +++ b/google-cloud-redis/synth.py @@ -51,6 +51,16 @@ s.copy(v1beta1_library / 'lib/google/cloud/redis/v1beta1.rb') s.copy(v1beta1_library / 'test/google/cloud/redis/v1beta1') +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-redis.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -155,18 +165,11 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-redis.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-redis.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-resource_manager/.rubocop.yml b/google-cloud-resource_manager/.rubocop.yml index bde7abb17c26..d9e92223bb9a 100644 --- a/google-cloud-resource_manager/.rubocop.yml +++ b/google-cloud-resource_manager/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -7,36 +10,20 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 20 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: +Layout/AlignHash: Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Metrics/ClassLength: Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-resource_manager.rb" +Style/IfUnlessModifier: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/WordArray: + Enabled: false diff --git a/google-cloud-resource_manager/CONTRIBUTING.md b/google-cloud-resource_manager/CONTRIBUTING.md index 18467462dc90..b03c707fd307 100644 --- a/google-cloud-resource_manager/CONTRIBUTING.md +++ b/google-cloud-resource_manager/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-resource_manager console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-resource_manager requires Ruby 2.3+. You may +1. Install Ruby. google-cloud-resource_manager requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-resource_manager/README.md b/google-cloud-resource_manager/README.md index d41a50456b1e..27822b282ef2 100644 --- a/google-cloud-resource_manager/README.md +++ b/google-cloud-resource_manager/README.md @@ -80,11 +80,11 @@ Google::Apis.logger = my_logger ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-resource_manager/google-cloud-resource_manager.gemspec b/google-cloud-resource_manager/google-cloud-resource_manager.gemspec index fcdb6ca73da8..f2818dda4efb 100644 --- a/google-cloud-resource_manager/google-cloud-resource_manager.gemspec +++ b/google-cloud-resource_manager/google-cloud-resource_manager.gemspec @@ -16,19 +16,19 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-api-client", "~> 0.23" - gem.add_dependency "googleauth", ">= 0.6.2", "< 0.10.0" + gem.add_dependency "google-api-client", "~> 0.33" + gem.add_dependency "googleauth", "~> 0.9" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-scheduler/.rubocop.yml b/google-cloud-scheduler/.rubocop.yml index dacbf74065fe..9b8394a988af 100644 --- a/google-cloud-scheduler/.rubocop.yml +++ b/google-cloud-scheduler/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-scheduler.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-scheduler/README.md b/google-cloud-scheduler/README.md index c667fab93310..e082ac0eb2a2 100644 --- a/google-cloud-scheduler/README.md +++ b/google-cloud-scheduler/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-scheduler/google-cloud-scheduler.gemspec b/google-cloud-scheduler/google-cloud-scheduler.gemspec index 21e35519fc1c..8e0842c60d6c 100644 --- a/google-cloud-scheduler/google-cloud-scheduler.gemspec +++ b/google-cloud-scheduler/google-cloud-scheduler.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.50.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-scheduler/synth.metadata b/google-cloud-scheduler/synth.metadata index 75f13fdb0f8f..a2cd3c094795 100644 --- a/google-cloud-scheduler/synth.metadata +++ b/google-cloud-scheduler/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-12T10:45:32.906080Z", + "updateTime": "2019-10-18T21:01:57.539949Z", "sources": [ { "generator": { "name": "artman", - "version": "0.39.0", - "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "af8dd2c1750558b538eaa6bdaa3bc899079533ee", - "internalRef": "274260771" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-scheduler/synth.py b/google-cloud-scheduler/synth.py index 813e61ea002f..82ccd6d001f6 100644 --- a/google-cloud-scheduler/synth.py +++ b/google-cloud-scheduler/synth.py @@ -59,6 +59,16 @@ s.copy(v1_library / '.yardopts') s.copy(v1_library / 'google-cloud-scheduler.gemspec', merge=ruby.merge_gemspec) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-scheduler.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -140,7 +150,7 @@ 'google-cloud-scheduler.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-security_center/.rubocop.yml b/google-cloud-security_center/.rubocop.yml index 66dd8d481011..c99263c2b05e 100644 --- a/google-cloud-security_center/.rubocop.yml +++ b/google-cloud-security_center/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-security_center.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-security_center/README.md b/google-cloud-security_center/README.md index 1ef84afb73d4..aff348192194 100644 --- a/google-cloud-security_center/README.md +++ b/google-cloud-security_center/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-security_center/google-cloud-security_center.gemspec b/google-cloud-security_center/google-cloud-security_center.gemspec index 50850e4c3dcf..c8d3d2bb4ca8 100644 --- a/google-cloud-security_center/google-cloud-security_center.gemspec +++ b/google-cloud-security_center/google-cloud-security_center.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-security_center/synth.metadata b/google-cloud-security_center/synth.metadata index dc58d30c1061..9c7963d6dc0b 100644 --- a/google-cloud-security_center/synth.metadata +++ b/google-cloud-security_center/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-26T10:42:54.838990Z", + "updateTime": "2019-10-18T21:02:51.166528Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "4c2ca81a0c976d4d37a8999984b7894d9af22124", - "internalRef": "271130964" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-security_center/synth.py b/google-cloud-security_center/synth.py index adc3aa03e031..84c4cad5e545 100644 --- a/google-cloud-security_center/synth.py +++ b/google-cloud-security_center/synth.py @@ -50,6 +50,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-security_center.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Permanent: rename securitycenter file paths to security_center s.replace( [ @@ -111,7 +121,7 @@ s.replace( 'google-cloud-security_center.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2196 s.replace( @@ -153,13 +163,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-security_center.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'lib/**/credentials.rb', 'SECURITYCENTER_', diff --git a/google-cloud-spanner/.rubocop.yml b/google-cloud-spanner/.rubocop.yml index 64223e4794f2..6609d51c49e5 100644 --- a/google-cloud-spanner/.rubocop.yml +++ b/google-cloud-spanner/.rubocop.yml @@ -1,3 +1,5 @@ +inherit_gem: + google-style: google-style.yml AllCops: Exclude: @@ -10,44 +12,30 @@ AllCops: - "lib/google/spanner/**/*" - "lib/google/cloud/spanner/v1/**/*" - "lib/google/cloud/spanner/admin/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/NumericLiterals: - Enabled: false -Style/TrivialAccessors: +Layout/AlignHash: Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 30 Metrics/ClassLength: Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: - Enabled: false -Lint/HandleExceptions: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-spanner.rb" +Naming/RescuedExceptionsVariableName: + Enabled: false Naming/UncommunicativeMethodParamName: Enabled: false +Style/EmptyMethod: + Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/NumericLiterals: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SymbolArray: + Enabled: false +Style/WordArray: + Enabled: false diff --git a/google-cloud-spanner/CONTRIBUTING.md b/google-cloud-spanner/CONTRIBUTING.md index f54e80d48b2a..c4dd3b7b5466 100644 --- a/google-cloud-spanner/CONTRIBUTING.md +++ b/google-cloud-spanner/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-spanner console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-spanner requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-spanner requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-spanner/README.md b/google-cloud-spanner/README.md index 608be4d1a0b7..186d3a19134d 100644 --- a/google-cloud-spanner/README.md +++ b/google-cloud-spanner/README.md @@ -60,11 +60,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-spanner/google-cloud-spanner.gemspec b/google-cloud-spanner/google-cloud-spanner.gemspec index d001f02cac6b..bb04e8bb67aa 100644 --- a/google-cloud-spanner/google-cloud-spanner.gemspec +++ b/google-cloud-spanner/google-cloud-spanner.gemspec @@ -16,20 +16,20 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_dependency "concurrent-ruby", "~> 1.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-spanner/lib/google/cloud/spanner/database.rb b/google-cloud-spanner/lib/google/cloud/spanner/database.rb index 5fd40f026e96..9ccae67c4478 100644 --- a/google-cloud-spanner/lib/google/cloud/spanner/database.rb +++ b/google-cloud-spanner/lib/google/cloud/spanner/database.rb @@ -83,8 +83,6 @@ def database_id @grpc.name.split("/")[5] end - # rubocop:disable LineLength - ## # The full path for the database resource. Values are of the form # `projects//instances//databases/`. @@ -93,8 +91,6 @@ def path @grpc.name end - # rubocop:enable LineLength - ## # The current database state. Possible values are `:CREATING` and # `:READY`. diff --git a/google-cloud-spanner/lib/google/cloud/spanner/session.rb b/google-cloud-spanner/lib/google/cloud/spanner/session.rb index b2fe5e3e44c3..62233e69b70d 100644 --- a/google-cloud-spanner/lib/google/cloud/spanner/session.rb +++ b/google-cloud-spanner/lib/google/cloud/spanner/session.rb @@ -79,8 +79,6 @@ def session_id @grpc.name.split("/")[7] end - # rubocop:disable LineLength - ## # The full path for the session resource. Values are of the form # `projects//instances//databases//sessions/`. @@ -89,8 +87,6 @@ def path @grpc.name end - # rubocop:enable LineLength - ## # Executes a SQL query. # diff --git a/google-cloud-speech/.rubocop.yml b/google-cloud-speech/.rubocop.yml index 71f886643b78..5cea8ae433dd 100644 --- a/google-cloud-speech/.rubocop.yml +++ b/google-cloud-speech/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-speech.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-speech/README.md b/google-cloud-speech/README.md index 7cbc1e6f078b..da04ed61e67a 100644 --- a/google-cloud-speech/README.md +++ b/google-cloud-speech/README.md @@ -84,11 +84,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-speech/google-cloud-speech.gemspec b/google-cloud-speech/google-cloud-speech.gemspec index acc6b106745f..f9c00dc033cd 100644 --- a/google-cloud-speech/google-cloud-speech.gemspec +++ b/google-cloud-speech/google-cloud-speech.gemspec @@ -25,13 +25,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-speech/synth.metadata b/google-cloud-speech/synth.metadata index d0b47b36bf5f..f64c97594529 100644 --- a/google-cloud-speech/synth.metadata +++ b/google-cloud-speech/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-26T10:43:13.922162Z", + "updateTime": "2019-10-18T21:03:17.009507Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "4c2ca81a0c976d4d37a8999984b7894d9af22124", - "internalRef": "271130964" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-speech/synth.py b/google-cloud-speech/synth.py index 7fc09490671f..74e80fe000c7 100644 --- a/google-cloud-speech/synth.py +++ b/google-cloud-speech/synth.py @@ -53,6 +53,16 @@ s.copy(v1p1beta1_library / 'lib/google/cloud/speech/v1p1beta1') s.copy(v1p1beta1_library / 'test/google/cloud/speech/v1p1beta1') +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-speech.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # PERMANENT: Install partial gapics s.replace( 'lib/google/cloud/speech/v1.rb', @@ -164,7 +174,7 @@ s.replace( 'google-cloud-speech.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2122 s.replace( @@ -226,13 +236,6 @@ 'README.md\nAUTHENTICATION.md\nLICENSE\n' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-speech.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - # https://github.com/googleapis/google-cloud-ruby/issues/3058 s.replace( 'google-cloud-speech.gemspec', diff --git a/google-cloud-storage/.rubocop.yml b/google-cloud-storage/.rubocop.yml index b475dc08ebd9..ccaaaf159d80 100644 --- a/google-cloud-storage/.rubocop.yml +++ b/google-cloud-storage/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -6,45 +9,28 @@ AllCops: - "Rakefile" - "test/**/*" - "support/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodCallWithArgsParentheses: - Enabled: true - EnforcedStyle: omit_parentheses - AllowParenthesesInMultilineCall: true - AllowParenthesesInCamelCaseMethod: true -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/RescueModifier: - Enabled: false -Style/TrivialAccessors: - Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 30 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 25 -Metrics/ParameterLists: +Layout/AlignHash: Enabled: false -Layout/EmptyLineAfterGuardClause: +Layout/SpaceAroundOperators: Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Naming/VariableNumber: +Metrics/ClassLength: Enabled: false Naming/FileName: Exclude: - "lib/google-cloud-storage.rb" -Style/RescueStandardError: - Exclude: - - "lib/google/cloud/storage/policy.rb" +Style/IfUnlessModifier: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false +Style/SymbolArray: + Enabled: false +Style/UnpackFirst: + Enabled: false +Style/WordArray: + Enabled: false diff --git a/google-cloud-storage/CONTRIBUTING.md b/google-cloud-storage/CONTRIBUTING.md index 1c3cccf03f81..776d1f983c72 100644 --- a/google-cloud-storage/CONTRIBUTING.md +++ b/google-cloud-storage/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-storage console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-storage requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-storage requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-storage/README.md b/google-cloud-storage/README.md index 5c12cf424c99..3da78feb7c3a 100644 --- a/google-cloud-storage/README.md +++ b/google-cloud-storage/README.md @@ -60,11 +60,11 @@ Google::Apis.logger = my_logger ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-storage/google-cloud-storage.gemspec b/google-cloud-storage/google-cloud-storage.gemspec index faed2c0fd919..254f4a46460b 100644 --- a/google-cloud-storage/google-cloud-storage.gemspec +++ b/google-cloud-storage/google-cloud-storage.gemspec @@ -16,22 +16,22 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" - gem.add_dependency "google-api-client", "~> 0.26" - gem.add_dependency "googleauth", ">= 0.6.2", "< 0.10.0" + gem.add_dependency "google-api-client", "~> 0.33" + gem.add_dependency "googleauth", "~> 0.9" gem.add_dependency "digest-crc", "~> 0.4" gem.add_dependency "addressable", "~> 2.5" gem.add_dependency "mini_mime", "~> 1.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/google-cloud-talent/.rubocop.yml b/google-cloud-talent/.rubocop.yml index 25d6d639accd..8901d0d1e4f3 100644 --- a/google-cloud-talent/.rubocop.yml +++ b/google-cloud-talent/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-talent.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-talent/README.md b/google-cloud-talent/README.md index 99cac3211805..4b7afd9cc6cc 100644 --- a/google-cloud-talent/README.md +++ b/google-cloud-talent/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-talent/google-cloud-talent.gemspec b/google-cloud-talent/google-cloud-talent.gemspec index c9113838230c..2995cf153cdb 100644 --- a/google-cloud-talent/google-cloud-talent.gemspec +++ b/google-cloud-talent/google-cloud-talent.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-talent/synth.metadata b/google-cloud-talent/synth.metadata index b2b332a7acf1..fdc39ddb0396 100644 --- a/google-cloud-talent/synth.metadata +++ b/google-cloud-talent/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-09T10:45:07.741570Z", + "updateTime": "2019-10-18T21:03:40.355010Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "2dec8f98383214ad4fafa7680eb0cc46d6531976", - "internalRef": "273619851" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-talent/synth.py b/google-cloud-talent/synth.py index ecbab3ff72dc..fcaaa12d22cf 100644 --- a/google-cloud-talent/synth.py +++ b/google-cloud-talent/synth.py @@ -43,6 +43,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-talent.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update Authentication Guide for multi-service clients s.replace( 'AUTHENTICATION.md', @@ -95,7 +105,7 @@ s.replace( 'google-cloud-talent.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"\n\n' + '\n gem.add_dependency "google-gax", "~> 1.8"\n gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"\n\n' ) # https://github.com/googleapis/gapic-generator/issues/2243 @@ -128,13 +138,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-talent.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - services = ['Application', 'Company', 'Job', 'Profile', 'Tenant'] # https://github.com/googleapis/gapic-generator/issues/2492 for service in services: diff --git a/google-cloud-tasks/.rubocop.yml b/google-cloud-tasks/.rubocop.yml index 3458e5a08830..147c90075c37 100644 --- a/google-cloud-tasks/.rubocop.yml +++ b/google-cloud-tasks/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-tasks.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-tasks/README.md b/google-cloud-tasks/README.md index 9dd6e95b3402..58805341435c 100644 --- a/google-cloud-tasks/README.md +++ b/google-cloud-tasks/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-tasks/google-cloud-tasks.gemspec b/google-cloud-tasks/google-cloud-tasks.gemspec index 3b742edf6576..a4d24ea232f2 100644 --- a/google-cloud-tasks/google-cloud-tasks.gemspec +++ b/google-cloud-tasks/google-cloud-tasks.gemspec @@ -19,15 +19,15 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-tasks/synth.metadata b/google-cloud-tasks/synth.metadata index e4bd94b1f342..3989600a8cf5 100644 --- a/google-cloud-tasks/synth.metadata +++ b/google-cloud-tasks/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-26T10:43:40.690832Z", + "updateTime": "2019-10-18T21:04:13.411559Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "4c2ca81a0c976d4d37a8999984b7894d9af22124", - "internalRef": "271130964" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-tasks/synth.py b/google-cloud-tasks/synth.py index 0a497eef08ef..e36ec1722daa 100644 --- a/google-cloud-tasks/synth.py +++ b/google-cloud-tasks/synth.py @@ -60,6 +60,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-tasks.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -144,13 +154,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-tasks.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'lib/google/cloud/tasks/v2/*.rb', "require 'google/api/resource_pb'\n", @@ -173,7 +176,7 @@ def escape_braces(match): 'google-cloud-tasks.gemspec', 'gem.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"', "\n".join([ - 'gem.add_dependency "google-gax", "~> 1.7"', + 'gem.add_dependency "google-gax", "~> 1.8"', ' gem.add_dependency "googleapis-common-protos", ">= 1.3.9", "< 2.0"' ]) ) diff --git a/google-cloud-text_to_speech/.rubocop.yml b/google-cloud-text_to_speech/.rubocop.yml index 2861c39b0f58..b60332277c1b 100644 --- a/google-cloud-text_to_speech/.rubocop.yml +++ b/google-cloud-text_to_speech/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-text_to_speech.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-text_to_speech/README.md b/google-cloud-text_to_speech/README.md index 96d77582ecff..45c55bd60fc8 100644 --- a/google-cloud-text_to_speech/README.md +++ b/google-cloud-text_to_speech/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-text_to_speech/google-cloud-text_to_speech.gemspec b/google-cloud-text_to_speech/google-cloud-text_to_speech.gemspec index 2a6e1f7338c0..71b38b8cc7c2 100644 --- a/google-cloud-text_to_speech/google-cloud-text_to_speech.gemspec +++ b/google-cloud-text_to_speech/google-cloud-text_to_speech.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-text_to_speech/synth.metadata b/google-cloud-text_to_speech/synth.metadata index 5757f08ff000..76c51f5a35e4 100644 --- a/google-cloud-text_to_speech/synth.metadata +++ b/google-cloud-text_to_speech/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-09-28T10:41:16.488393Z", + "updateTime": "2019-10-18T21:05:05.020375Z", "sources": [ { "generator": { "name": "artman", - "version": "0.37.1", - "dockerImage": "googleapis/artman@sha256:6068f67900a3f0bdece596b97bda8fc70406ca0e137a941f4c81d3217c994a80" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "fcdec366bb4076be75649031706548128a01fc02", - "internalRef": "271635926" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-text_to_speech/synth.py b/google-cloud-text_to_speech/synth.py index d5cd333586e8..932b5624983d 100644 --- a/google-cloud-text_to_speech/synth.py +++ b/google-cloud-text_to_speech/synth.py @@ -49,6 +49,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-text_to_speech.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -92,7 +102,7 @@ s.replace( 'google-cloud-text_to_speech.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2243 s.replace( @@ -124,13 +134,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-text_to_speech.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-text_to_speech.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-trace/.rubocop.yml b/google-cloud-trace/.rubocop.yml index 3b80ebd04e38..c66a98d8ef8d 100644 --- a/google-cloud-trace/.rubocop.yml +++ b/google-cloud-trace/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -11,52 +14,79 @@ AllCops: - "Rakefile" - "support/**/*" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/HashSyntax: - Exclude: - - "lib/google/cloud/trace/v1/**/*" -Style/NumericLiterals: +Layout/AlignHash: Enabled: false -Style/ClassVars: +Lint/RescueException: + Exclude: + - "lib/google/cloud/trace/rails.rb" +Metrics/ClassLength: Enabled: false -Style/TrivialAccessors: +Naming/FileName: + Exclude: + - "lib/google-cloud-trace.rb" +Naming/RescuedExceptionsVariableName: Enabled: false Style/CaseEquality: Enabled: false +Style/ClassVars: + Enabled: false Style/GuardClause: Enabled: false -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: +Style/IfUnlessModifier: Enabled: false -Metrics/MethodLength: - Max: 20 - Exclude: - - "lib/google/cloud/trace/v1/**/*" -Metrics/LineLength: - Exclude: - - "lib/google/cloud/trace/v1/**/*" -Metrics/ParameterLists: +Style/MethodCallWithArgsParentheses: Enabled: false -Lint/RescueException: - Exclude: - - "lib/google/cloud/trace/rails.rb" -Layout/EmptyLineAfterGuardClause: +Style/NumericLiterals: Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Style/NumericPredicate: Enabled: false -Naming/FileName: - Exclude: - - "lib/google-cloud-trace.rb" +Style/SafeNavigation: + Enabled: false +Style/WhileUntilModifier: + Enabled: false + +# Style/StringLiterals: +# EnforcedStyle: double_quotes +# Style/MethodDefParentheses: +# EnforcedStyle: require_no_parentheses +# Style/HashSyntax: +# Exclude: +# - "lib/google/cloud/trace/v1/**/*" +# Style/NumericLiterals: +# Enabled: false +# Style/ClassVars: +# Enabled: false +# Style/TrivialAccessors: +# Enabled: false +# Style/CaseEquality: +# Enabled: false +# Style/GuardClause: +# Enabled: false +# Metrics/CyclomaticComplexity: +# Max: 10 +# Metrics/PerceivedComplexity: +# Max: 10 +# Metrics/AbcSize: +# Max: 25 +# Metrics/ClassLength: +# Enabled: false +# Metrics/MethodLength: +# Max: 20 +# Exclude: +# - "lib/google/cloud/trace/v1/**/*" +# Metrics/LineLength: +# Exclude: +# - "lib/google/cloud/trace/v1/**/*" +# Metrics/ParameterLists: +# Enabled: false +# Lint/RescueException: +# Exclude: +# - "lib/google/cloud/trace/rails.rb" +# Layout/EmptyLineAfterGuardClause: +# Enabled: false +# Layout/EmptyLines: # for the extra line between copyright and code +# Enabled: false diff --git a/google-cloud-trace/CONTRIBUTING.md b/google-cloud-trace/CONTRIBUTING.md index 2377118dbd1b..f44223ba9733 100644 --- a/google-cloud-trace/CONTRIBUTING.md +++ b/google-cloud-trace/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-trace console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-trace requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-trace requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-trace/README.md b/google-cloud-trace/README.md index 3d8695a9d373..1f5fbbc6d14c 100644 --- a/google-cloud-trace/README.md +++ b/google-cloud-trace/README.md @@ -207,11 +207,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-trace/google-cloud-trace.gemspec b/google-cloud-trace/google-cloud-trace.gemspec index f70ab00964de..a21f7a2b2a59 100644 --- a/google-cloud-trace/google-cloud-trace.gemspec +++ b/google-cloud-trace/google-cloud-trace.gemspec @@ -18,22 +18,22 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "INSTRUMENTATION.md", "LOGGING.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" gem.add_dependency "stackdriver-core", "~> 1.3" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "concurrent-ruby", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "faraday", "~> 0.8" - gem.add_development_dependency "railties", "~> 4.0" + gem.add_development_dependency "railties", ">= 4.0" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest" #, "~> 0.1.6" diff --git a/google-cloud-trace/lib/google/cloud/trace/service.rb b/google-cloud-trace/lib/google/cloud/trace/service.rb index c83ffe1a23d3..a2d8811c83b3 100644 --- a/google-cloud-trace/lib/google/cloud/trace/service.rb +++ b/google-cloud-trace/lib/google/cloud/trace/service.rb @@ -86,8 +86,6 @@ def get_trace trace_id Google::Cloud::Trace::TraceRecord.from_grpc trace_proto end - # rubocop:disable Metrics/MethodLength - ## # Searches for traces matching the given criteria. # @@ -125,8 +123,6 @@ def list_traces project_id, start_time, end_time, page_token: page_token end - # rubocop:enable Metrics/MethodLength - # @private def inspect "#{self.class}(#{@project})" diff --git a/google-cloud-trace/lib/google/cloud/trace/span.rb b/google-cloud-trace/lib/google/cloud/trace/span.rb index e4c27c03312e..c633a016a1da 100644 --- a/google-cloud-trace/lib/google/cloud/trace/span.rb +++ b/google-cloud-trace/lib/google/cloud/trace/span.rb @@ -116,8 +116,6 @@ def initialize trace, id, parent_span_id, parent, name, kind, @labels = labels end - # rubocop:disable Metrics/AbcSize - ## # Standard value equality check for this object. # @@ -138,8 +136,6 @@ def eql? other end alias == eql? - # rubocop:enable Metrics/AbcSize - ## # Create a new Span object from a TraceSpan protobuf and insert it # into the given trace. diff --git a/google-cloud-translate/CONTRIBUTING.md b/google-cloud-translate/CONTRIBUTING.md index beb6bf62a06f..521cf628898b 100644 --- a/google-cloud-translate/CONTRIBUTING.md +++ b/google-cloud-translate/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud-translate console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud-translate requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud-translate requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud-translate/README.md b/google-cloud-translate/README.md index 1c7c54bddefe..5f9cdd8d683a 100644 --- a/google-cloud-translate/README.md +++ b/google-cloud-translate/README.md @@ -64,11 +64,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-translate/google-cloud-translate.gemspec b/google-cloud-translate/google-cloud-translate.gemspec index c6eaea6758e0..bc337e55a382 100644 --- a/google-cloud-translate/google-cloud-translate.gemspec +++ b/google-cloud-translate/google-cloud-translate.gemspec @@ -16,11 +16,11 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "AUTHENTICATION.md", "CONTRIBUTING.md", "TROUBLESHOOTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" gem.add_dependency "faraday", "~> 0.13" - gem.add_dependency "googleauth", ">= 0.6.2", "< 0.10.0" + gem.add_dependency "googleauth", "~> 0.9" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "google-style", "~> 0.3" diff --git a/google-cloud-video_intelligence/.rubocop.yml b/google-cloud-video_intelligence/.rubocop.yml index 09fc1995d4b5..15c899182616 100644 --- a/google-cloud-video_intelligence/.rubocop.yml +++ b/google-cloud-video_intelligence/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud-video_intelligence.gemspec" @@ -5,12 +8,6 @@ AllCops: - "Rakefile" - "test/**/*" - "acceptance/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-video_intelligence/README.md b/google-cloud-video_intelligence/README.md index 1286672ef5ab..f9c789a91732 100644 --- a/google-cloud-video_intelligence/README.md +++ b/google-cloud-video_intelligence/README.md @@ -98,11 +98,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-video_intelligence/google-cloud-video_intelligence.gemspec b/google-cloud-video_intelligence/google-cloud-video_intelligence.gemspec index fd0b915db7c5..e36bc759c8b5 100644 --- a/google-cloud-video_intelligence/google-cloud-video_intelligence.gemspec +++ b/google-cloud-video_intelligence/google-cloud-video_intelligence.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-video_intelligence/synth.metadata b/google-cloud-video_intelligence/synth.metadata index c19ea91c3178..f8585c14ff75 100644 --- a/google-cloud-video_intelligence/synth.metadata +++ b/google-cloud-video_intelligence/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-12T10:47:46.385242Z", + "updateTime": "2019-10-18T21:05:45.998824Z", "sources": [ { "generator": { "name": "artman", - "version": "0.39.0", - "dockerImage": "googleapis/artman@sha256:72554d0b3bdc0b4ac7d6726a6a606c00c14b454339037ed86be94574fb05d9f3" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "af8dd2c1750558b538eaa6bdaa3bc899079533ee", - "internalRef": "274260771" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-video_intelligence/synth.py b/google-cloud-video_intelligence/synth.py index 56502f33ef0e..aa6a1629cbeb 100644 --- a/google-cloud-video_intelligence/synth.py +++ b/google-cloud-video_intelligence/synth.py @@ -74,6 +74,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-video_intelligence.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -117,7 +127,7 @@ s.replace( 'google-cloud-video_intelligence.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # PERMANENT: API name for videointelligence s.replace( @@ -172,13 +182,6 @@ 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'google-cloud-video_intelligence.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'google-cloud-video_intelligence.gemspec', '"README.md", "LICENSE"', diff --git a/google-cloud-vision/.rubocop.yml b/google-cloud-vision/.rubocop.yml index 2c93c66d10f5..c9055b0d73f3 100644 --- a/google-cloud-vision/.rubocop.yml +++ b/google-cloud-vision/.rubocop.yml @@ -1,3 +1,6 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "acceptance/**/*" @@ -10,35 +13,6 @@ AllCops: - "lib/google/cloud/vision/v1p3beta1.rb" - "lib/google/cloud/vision/v1p3beta1/**/*" - "test/**/*" - TargetRubyVersion: 2.2 - Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/TrivialAccessors: - Enabled: false -Style/FormatStringToken: # we have many uses of this, we don't want to change - Enabled: false -Metrics/CyclomaticComplexity: - Max: 15 -Metrics/PerceivedComplexity: - Max: 15 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: - Enabled: false -Metrics/MethodLength: - Max: 26 -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false -Naming/UncommunicativeMethodParamName: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false diff --git a/google-cloud-vision/README.md b/google-cloud-vision/README.md index 7abaa0a4eca2..74b659d8ba27 100644 --- a/google-cloud-vision/README.md +++ b/google-cloud-vision/README.md @@ -84,11 +84,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-vision/google-cloud-vision.gemspec b/google-cloud-vision/google-cloud-vision.gemspec index 2949ff63edf4..ac10977e9a52 100644 --- a/google-cloud-vision/google-cloud-vision.gemspec +++ b/google-cloud-vision/google-cloud-vision.gemspec @@ -25,13 +25,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-vision/synth.metadata b/google-cloud-vision/synth.metadata index 81983ed67da3..339368fd98af 100644 --- a/google-cloud-vision/synth.metadata +++ b/google-cloud-vision/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-10T10:45:14.340019Z", + "updateTime": "2019-10-18T21:06:39.867033Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "10f91fa12f70e8e0209a45fc10807ed1f77c7e4e", - "internalRef": "273826591" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-vision/synth.py b/google-cloud-vision/synth.py index b9c5afbc4a79..57ba31a00d6a 100644 --- a/google-cloud-vision/synth.py +++ b/google-cloud-vision/synth.py @@ -52,6 +52,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-vision.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Update Authentication Guide for multi-service clients s.replace( 'AUTHENTICATION.md', @@ -102,7 +112,7 @@ s.replace( 'google-cloud-vision.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # PERMANENT: Add migration guide to docs s.replace( @@ -189,11 +199,6 @@ 'https://googlecloudplatform\\.github\\.io/google-cloud-ruby', 'https://googleapis.github.io/google-cloud-ruby' ) -s.replace( - 'google-cloud-vision.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) s.replace( 'google-cloud-vision.gemspec', diff --git a/google-cloud-webrisk/.rubocop.yml b/google-cloud-webrisk/.rubocop.yml index b06f898b46ed..b7594dad9f2d 100644 --- a/google-cloud-webrisk/.rubocop.yml +++ b/google-cloud-webrisk/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "google-cloud-webrisk.gemspec" - "lib/google/**/*" @@ -9,8 +11,3 @@ AllCops: Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud-webrisk/README.md b/google-cloud-webrisk/README.md index 1d45ed2a1d78..4e14c2e17f3c 100644 --- a/google-cloud-webrisk/README.md +++ b/google-cloud-webrisk/README.md @@ -58,11 +58,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud-webrisk/google-cloud-webrisk.gemspec b/google-cloud-webrisk/google-cloud-webrisk.gemspec index a43a012d09c1..f0afe3ae5fa0 100644 --- a/google-cloud-webrisk/google-cloud-webrisk.gemspec +++ b/google-cloud-webrisk/google-cloud-webrisk.gemspec @@ -19,13 +19,13 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/google-cloud-webrisk/synth.metadata b/google-cloud-webrisk/synth.metadata index 8dd09d7e1727..66639455c3d4 100644 --- a/google-cloud-webrisk/synth.metadata +++ b/google-cloud-webrisk/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-10-09T10:46:38.983137Z", + "updateTime": "2019-10-18T20:46:43.983890Z", "sources": [ { "generator": { "name": "artman", - "version": "0.38.0", - "dockerImage": "googleapis/artman@sha256:0d2f8d429110aeb8d82df6550ef4ede59d40df9062d260a1580fce688b0512bf" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "2dec8f98383214ad4fafa7680eb0cc46d6531976", - "internalRef": "273619851" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/google-cloud-webrisk/synth.py b/google-cloud-webrisk/synth.py index 1fe4590b3b48..b76932cfd43c 100644 --- a/google-cloud-webrisk/synth.py +++ b/google-cloud-webrisk/synth.py @@ -40,6 +40,16 @@ templates = gcp.CommonTemplates().ruby_library() s.copy(templates) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('google-cloud-webrisk.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Support for service_address s.replace( [ @@ -83,7 +93,7 @@ s.replace( 'google-cloud-webrisk.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # https://github.com/googleapis/gapic-generator/issues/2243 s.replace( @@ -108,11 +118,7 @@ 'https://googlecloudplatform\\.github\\.io/google-cloud-ruby', 'https://googleapis.github.io/google-cloud-ruby' ) -s.replace( - 'google-cloud-webrisk.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) + # Fix product documentation links s.replace( ['README.md', 'lib/**/*.rb'], diff --git a/google-cloud/.rubocop.yml b/google-cloud/.rubocop.yml index 5e9c3e0229ca..49a3ffe3a135 100644 --- a/google-cloud/.rubocop.yml +++ b/google-cloud/.rubocop.yml @@ -1,9 +1,11 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "google-cloud.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false @@ -16,7 +18,3 @@ Metrics/LineLength: Naming/FileName: Exclude: - "lib/google-cloud.rb" -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/google-cloud/CONTRIBUTING.md b/google-cloud/CONTRIBUTING.md index acf9503bd575..ac7af2e5d2f1 100644 --- a/google-cloud/CONTRIBUTING.md +++ b/google-cloud/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the google-cloud console and run the project's tests, there is a small amount of setup: -1. Install Ruby. google-cloud requires Ruby 2.3+. You may choose to +1. Install Ruby. google-cloud requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/google-cloud/README.md b/google-cloud/README.md index 5bacb59bdcc8..94641ae6232f 100644 --- a/google-cloud/README.md +++ b/google-cloud/README.md @@ -82,11 +82,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/google-cloud/google-cloud.gemspec b/google-cloud/google-cloud.gemspec index 72858e7a640c..505cd9b1dc4f 100644 --- a/google-cloud/google-cloud.gemspec +++ b/google-cloud/google-cloud.gemspec @@ -16,7 +16,7 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "CONTRIBUTING.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-asset", "~> 0.1" @@ -55,12 +55,12 @@ Gem::Specification.new do |gem| gem.add_dependency "google-cloud-vision", "~> 0.28" gem.add_development_dependency "autotest-suffix", "~> 1.1" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.13" diff --git a/grafeas-client/.rubocop.yml b/grafeas-client/.rubocop.yml index 5216ca5cfc76..387678056669 100644 --- a/grafeas-client/.rubocop.yml +++ b/grafeas-client/.rubocop.yml @@ -1,5 +1,7 @@ +inherit_gem: + google-style: google-style.yml + AllCops: - TargetRubyVersion: 2.2 Exclude: - "grafeas-client.gemspec" - "lib/**/*" @@ -9,8 +11,3 @@ AllCops: Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses diff --git a/grafeas-client/README.md b/grafeas-client/README.md index 38eaa7799999..def8e4607581 100644 --- a/grafeas-client/README.md +++ b/grafeas-client/README.md @@ -59,11 +59,11 @@ end ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Currently, this means Ruby 2.3 +in security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/grafeas-client/grafeas-client.gemspec b/grafeas-client/grafeas-client.gemspec index 30cb559b5516..da01b2690917 100644 --- a/grafeas-client/grafeas-client.gemspec +++ b/grafeas-client/grafeas-client.gemspec @@ -19,14 +19,14 @@ Gem::Specification.new do |gem| ["README.md", "AUTHENTICATION.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" - gem.add_dependency "google-gax", "~> 1.7" + gem.add_dependency "google-gax", "~> 1.8" gem.add_dependency "grpc-google-iam-v1", "~> 0.6.9" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" end diff --git a/grafeas-client/synth.metadata b/grafeas-client/synth.metadata index 16e81e032fff..a3100ea8e965 100644 --- a/grafeas-client/synth.metadata +++ b/grafeas-client/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-08-27T10:47:25.176961Z", + "updateTime": "2019-10-18T20:45:55.386633Z", "sources": [ { "generator": { "name": "artman", - "version": "0.35.1", - "dockerImage": "googleapis/artman@sha256:b11c7ea0d0831c54016fb50f4b796d24d1971439b30fbc32a369ba1ac887c384" + "version": "0.40.0", + "dockerImage": "googleapis/artman@sha256:fd2b49cce3d652929cc80157ec2d91bebe993f7cd4e89afaad80f9c785f8bf36" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "650caad718bb063f189405c23972dc9818886358", - "internalRef": "265565344" + "sha": "906335b5a958557e1070fc6f275171dc8a42b1ec", + "internalRef": "275374583" } }, { diff --git a/grafeas-client/synth.py b/grafeas-client/synth.py index 25b872849eff..274734798e47 100644 --- a/grafeas-client/synth.py +++ b/grafeas-client/synth.py @@ -69,6 +69,16 @@ 'gem install grafeas-client\n' ) +# Update gemspec to reflect Ruby 2.4 +ruby.update_gemspec('grafeas-client.gemspec') + +# Update README to reflect Ruby 2.4 +s.replace( + 'README.md', + 'Ruby 2.3', + 'Ruby 2.4' +) + # Hack AUTHENTICATION.md to fix nonstandard name. s.replace( 'AUTHENTICATION.md', @@ -139,7 +149,7 @@ s.replace( 'grafeas-client.gemspec', '\n gem\\.add_dependency "google-gax", "~> 1\\.[\\d\\.]+"\n', - '\n gem.add_dependency "google-gax", "~> 1.7"\n') + '\n gem.add_dependency "google-gax", "~> 1.8"\n') # Fix for tests that assume protos implement to_hash s.replace( @@ -201,13 +211,6 @@ def escape_braces(match): 'https://googleapis.github.io/google-cloud-ruby' ) -# https://github.com/googleapis/gapic-generator/issues/2393 -s.replace( - 'grafeas-client.gemspec', - 'gem.add_development_dependency "rubocop".*$', - 'gem.add_development_dependency "rubocop", "~> 0.64.0"' -) - s.replace( 'grafeas-client.gemspec', '"README.md", "LICENSE"', diff --git a/stackdriver-core/.rubocop.yml b/stackdriver-core/.rubocop.yml index 9dfc9387a47b..b0c6febb269d 100644 --- a/stackdriver-core/.rubocop.yml +++ b/stackdriver-core/.rubocop.yml @@ -1,41 +1,33 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "stackdriver-core.gemspec" - "Rakefile" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Style/ClassVars: - Exclude: - - "lib/google/cloud/configuration.rb" -Metrics/CyclomaticComplexity: - Max: 10 -Metrics/PerceivedComplexity: - Max: 10 -Metrics/AbcSize: - Max: 25 -Metrics/ClassLength: +Layout/AlignHash: Enabled: false -Metrics/MethodLength: - Max: 20 Metrics/ModuleLength: Enabled: false -Metrics/ParameterLists: - Enabled: false -Layout/EmptyLineAfterGuardClause: - Enabled: false -Layout/EmptyLines: # for the extra line between copyright and code +Metrics/ClassLength: Enabled: false Naming/AccessorMethodName: - Exclude: - - "lib/stackdriver/core/async_actor.rb" + Enabled: false Naming/FileName: Exclude: - "lib/stackdriver-core.rb" +Style/EmptyMethod: + Enabled: false +Style/IfUnlessModifier: + Enabled: false +Style/MethodCallWithArgsParentheses: + Enabled: false +Style/NumericPredicate: + Enabled: false +Style/SafeNavigation: + Enabled: false diff --git a/stackdriver-core/CONTRIBUTING.md b/stackdriver-core/CONTRIBUTING.md index b065c3fe9995..701eecf3421f 100644 --- a/stackdriver-core/CONTRIBUTING.md +++ b/stackdriver-core/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the stackdriver console and run the project's tests, there is a small amount of setup: -1. Install Ruby. stackdriver requires Ruby 2.3+. You may choose to +1. Install Ruby. stackdriver requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/stackdriver-core/README.md b/stackdriver-core/README.md index a651eb69d0a9..096c7d10d2b5 100644 --- a/stackdriver-core/README.md +++ b/stackdriver-core/README.md @@ -9,11 +9,11 @@ information about the individual google-cloud gems. ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/stackdriver-core/stackdriver-core.gemspec b/stackdriver-core/stackdriver-core.gemspec index 31b20641c286..bed1b462031b 100644 --- a/stackdriver-core/stackdriver-core.gemspec +++ b/stackdriver-core/stackdriver-core.gemspec @@ -16,16 +16,16 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "CONTRIBUTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.0.0" + gem.required_ruby_version = ">= 2.4" gem.add_dependency "google-cloud-core", "~> 1.2" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "redcarpet", "~> 3.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" diff --git a/stackdriver/.rubocop.yml b/stackdriver/.rubocop.yml index fec1ca69175f..c5aa6d7cf0cd 100644 --- a/stackdriver/.rubocop.yml +++ b/stackdriver/.rubocop.yml @@ -1,17 +1,12 @@ +inherit_gem: + google-style: google-style.yml + AllCops: Exclude: - "*.gemspec" - "Rakefile" - "lib/legacy_stackdriver.rb" - "test/**/*" - TargetRubyVersion: 2.2 Documentation: Enabled: false - -Style/StringLiterals: - EnforcedStyle: double_quotes -Style/MethodDefParentheses: - EnforcedStyle: require_no_parentheses -Layout/EmptyLines: # for the extra line between copyright and code - Enabled: false diff --git a/stackdriver/CONTRIBUTING.md b/stackdriver/CONTRIBUTING.md index c0325c7ad6cf..15a001ccdf89 100644 --- a/stackdriver/CONTRIBUTING.md +++ b/stackdriver/CONTRIBUTING.md @@ -24,7 +24,7 @@ be able to accept your pull requests. In order to use the stackdriver console and run the project's tests, there is a small amount of setup: -1. Install Ruby. stackdriver requires Ruby 2.3+. You may choose to +1. Install Ruby. stackdriver requires Ruby 2.4+. You may choose to manage your Ruby and gem installations with [RVM](https://rvm.io/), [rbenv](https://github.com/rbenv/rbenv), or [chruby](https://github.com/postmodern/chruby). diff --git a/stackdriver/README.md b/stackdriver/README.md index b003a8202134..b278d2b0adae 100644 --- a/stackdriver/README.md +++ b/stackdriver/README.md @@ -108,11 +108,11 @@ See the gem documentation for each individual gem for more information. ## Supported Ruby Versions -This library is supported on Ruby 2.3+. +This library is supported on Ruby 2.4+. Google provides official support for Ruby versions that are actively supported by Ruby Core—that is, Ruby versions that are either in normal maintenance or in -security maintenance, and not end of life. Currently, this means Ruby 2.3 and +security maintenance, and not end of life. Currently, this means Ruby 2.4 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule. diff --git a/stackdriver/stackdriver.gemspec b/stackdriver/stackdriver.gemspec index 66c30059313b..350170d453cc 100644 --- a/stackdriver/stackdriver.gemspec +++ b/stackdriver/stackdriver.gemspec @@ -16,20 +16,20 @@ Gem::Specification.new do |gem| ["OVERVIEW.md", "INSTRUMENTATION_CONFIGURATION.md", "CONTRIBUTING.md", "CHANGELOG.md", "CODE_OF_CONDUCT.md", "LICENSE", ".yardopts"] gem.require_paths = ["lib"] - gem.required_ruby_version = ">= 2.2.0" + gem.required_ruby_version = ">= 2.4" gem.add_runtime_dependency "google-cloud-debugger", "~> 0.32" gem.add_runtime_dependency "google-cloud-error_reporting", "~> 0.30" gem.add_runtime_dependency "google-cloud-logging", "~> 1.5" gem.add_runtime_dependency "google-cloud-trace", "~> 0.33" + gem.add_development_dependency "google-style", "~> 1.24.0" gem.add_development_dependency "minitest", "~> 5.10" gem.add_development_dependency "minitest-autotest", "~> 1.0" gem.add_development_dependency "minitest-focus", "~> 1.1" gem.add_development_dependency "minitest-rg", "~> 5.2" gem.add_development_dependency "autotest-suffix", "~> 1.1" gem.add_development_dependency "redcarpet", "~> 3.0" - gem.add_development_dependency "rubocop", "~> 0.64.0" gem.add_development_dependency "simplecov", "~> 0.9" gem.add_development_dependency "yard", "~> 0.9" gem.add_development_dependency "yard-doctest", "~> 0.1.6"