-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
110 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
AllCops: | ||
Exclude: | ||
- '**/**/*.pb.rb' | ||
- "vendor/**/*" | ||
DisplayCopNames: true | ||
TargetRubyVersion: 2.4 | ||
|
||
Style/AndOr: | ||
EnforcedStyle: conditionals | ||
|
||
Style/AsciiComments: | ||
Enabled: false | ||
|
||
Style/Documentation: | ||
Enabled: false | ||
|
||
Style/DoubleNegation: | ||
Enabled: false | ||
|
||
Style/EmptyElse: | ||
EnforcedStyle: empty | ||
|
||
Style/FormatString: | ||
EnforcedStyle: percent | ||
|
||
Style/IfUnlessModifier: | ||
Enabled: false | ||
|
||
|
||
Style/PredicateName: | ||
NamePrefixBlacklist: | ||
- "is_" | ||
- "have_" | ||
NamePrefix: | ||
- "is_" | ||
- "have_" | ||
|
||
Style/SignalException: | ||
EnforcedStyle: only_raise | ||
|
||
Style/SingleLineBlockParams: | ||
Enabled: false | ||
|
||
Lint/UnderscorePrefixedVariableName: | ||
Enabled: false | ||
|
||
##################### Metrics ################################## | ||
|
||
Metrics/AbcSize: | ||
Max: 30 | ||
|
||
Metrics/CyclomaticComplexity: | ||
Max: 10 | ||
|
||
Metrics/LineLength: | ||
Max: 160 | ||
|
||
Metrics/MethodLength: | ||
Max: 20 | ||
|
||
Metrics/PerceivedComplexity: | ||
Max: 8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
source "https://rubygems.org" | ||
# frozen_string_literal: true | ||
|
||
git_source(:github) {|repo_name| "https://github.com/#{repo_name}" } | ||
source 'https://rubygems.org' | ||
|
||
git_source(:github) { |repo_name| "https://github.com/#{repo_name}" } | ||
|
||
# Specify your gem's dependencies in grpc_kit.gemspec | ||
gemspec |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
require "bundler/gem_tasks" | ||
require "rspec/core/rake_task" | ||
# frozen_string_literal: true | ||
|
||
require 'bundler/gem_tasks' | ||
require 'rspec/core/rake_task' | ||
|
||
RSpec::Core::RakeTask.new(:spec) | ||
|
||
task :default => :spec | ||
task default: :spec |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,38 @@ | ||
# frozen_string_literal: true | ||
|
||
lib = File.expand_path("../lib", __FILE__) | ||
lib = File.expand_path('lib', __dir__) | ||
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) | ||
require "grpc_kit/version" | ||
require 'grpc_kit/version' | ||
|
||
Gem::Specification.new do |spec| | ||
spec.name = "grpc_kit" | ||
spec.name = 'grpc_kit' | ||
spec.version = GrpcKit::VERSION | ||
spec.authors = ["ganmacs"] | ||
spec.email = ["ganmacs@gmail.com"] | ||
spec.authors = ['ganmacs'] | ||
spec.email = ['ganmacs@gmail.com'] | ||
|
||
spec.summary = "..." | ||
spec.description = "..." | ||
spec.homepage = "https://github.com/ganmacs/grpc_kit" | ||
spec.license = "MIT" | ||
spec.summary = '...' | ||
spec.description = '...' | ||
spec.homepage = 'https://github.com/ganmacs/grpc_kit' | ||
spec.license = 'MIT' | ||
|
||
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host' | ||
# to allow pushing to a single host or delete this section to allow pushing to any host. | ||
if spec.respond_to?(:metadata) | ||
spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'" | ||
spec.metadata['allowed_push_host'] = "TODO: Set to 'http://mygemserver.com'" | ||
else | ||
raise "RubyGems 2.0 or newer is required to protect against " \ | ||
"public gem pushes." | ||
raise 'RubyGems 2.0 or newer is required to protect against ' \ | ||
'public gem pushes.' | ||
end | ||
|
||
spec.files = `git ls-files -z`.split("\x0").reject do |f| | ||
spec.files = `git ls-files -z`.split("\x0").reject do |f| | ||
f.match(%r{^(test|spec|features)/}) | ||
end | ||
spec.bindir = "exe" | ||
spec.bindir = 'exe' | ||
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) } | ||
spec.require_paths = ["lib"] | ||
spec.require_paths = ['lib'] | ||
|
||
spec.add_development_dependency "bundler", "~> 1.16" | ||
spec.add_development_dependency "rake", "~> 10.0" | ||
spec.add_development_dependency "rspec", "~> 3.0" | ||
spec.add_development_dependency 'bundler', '~> 1.16' | ||
spec.add_development_dependency 'rake', '~> 10.0' | ||
spec.add_development_dependency 'rspec', '~> 3.0' | ||
spec.add_development_dependency 'rubocop' | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
module GrpcKit | ||
VERSION = "0.1.0" | ||
VERSION = '0.1.0' | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
# frozen_string_literal: true | ||
|
||
RSpec.describe GrpcKit do | ||
it "has a version number" do | ||
it 'has a version number' do | ||
expect(GrpcKit::VERSION).not_to be nil | ||
end | ||
|
||
it "does something useful" do | ||
it 'does something useful' do | ||
expect(false).to eq(true) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters