pbio 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +2 -1
- data/Gemfile.lock +15 -15
- data/lib/pbio/delimited.rb +5 -0
- data/pbio.gemspec +1 -1
- data/spec/lib/pbio/delimited_spec.rb +1 -0
- metadata +2 -3
- data/.rubocop-https---gitlab-com-bsm-misc-raw-master-rubocop-default-yml +0 -78
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 919f9fe64d447b8c2ad514fca83e55ab1783380d0b00674f195ce7aeff621e14
|
4
|
+
data.tar.gz: 900091eb54c3faced8e19b66605665f22b5a963ec640d3381fe0716684b80c1d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d7dbc3610dc8c15bfed2bb8f100f2941c9a414a98413404fd64c9cf7e3011920eb6f4af19278018b6783fb2bf36fa78992f3389fc9b58ed38475825f5eacdf1
|
7
|
+
data.tar.gz: 2c97c15cd2fdc7755851aba197eb7bb4b228410ceae3d17ca61af153acbcc2eff75249dbcfead577971826bae77e9142cd96efc644cee85bb96cf5267b278bee
|
data/.gitignore
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
pbio (0.2.
|
4
|
+
pbio (0.2.1)
|
5
5
|
google-protobuf
|
6
6
|
|
7
7
|
GEM
|
@@ -9,37 +9,37 @@ GEM
|
|
9
9
|
specs:
|
10
10
|
ast (2.4.0)
|
11
11
|
diff-lcs (1.3)
|
12
|
-
google-protobuf (3.
|
13
|
-
jaro_winkler (1.5.
|
14
|
-
parallel (1.
|
15
|
-
parser (2.
|
12
|
+
google-protobuf (3.11.2-x86_64-linux)
|
13
|
+
jaro_winkler (1.5.4)
|
14
|
+
parallel (1.19.1)
|
15
|
+
parser (2.7.0.2)
|
16
16
|
ast (~> 2.4.0)
|
17
17
|
rainbow (3.0.0)
|
18
|
-
rake (13.0.
|
18
|
+
rake (13.0.1)
|
19
19
|
rspec (3.9.0)
|
20
20
|
rspec-core (~> 3.9.0)
|
21
21
|
rspec-expectations (~> 3.9.0)
|
22
22
|
rspec-mocks (~> 3.9.0)
|
23
|
-
rspec-core (3.9.
|
24
|
-
rspec-support (~> 3.9.
|
23
|
+
rspec-core (3.9.1)
|
24
|
+
rspec-support (~> 3.9.1)
|
25
25
|
rspec-expectations (3.9.0)
|
26
26
|
diff-lcs (>= 1.2.0, < 2.0)
|
27
27
|
rspec-support (~> 3.9.0)
|
28
|
-
rspec-mocks (3.9.
|
28
|
+
rspec-mocks (3.9.1)
|
29
29
|
diff-lcs (>= 1.2.0, < 2.0)
|
30
30
|
rspec-support (~> 3.9.0)
|
31
|
-
rspec-support (3.9.
|
32
|
-
rubocop (0.
|
31
|
+
rspec-support (3.9.2)
|
32
|
+
rubocop (0.79.0)
|
33
33
|
jaro_winkler (~> 1.5.1)
|
34
34
|
parallel (~> 1.10)
|
35
|
-
parser (>= 2.
|
35
|
+
parser (>= 2.7.0.1)
|
36
36
|
rainbow (>= 2.2.2, < 4.0)
|
37
37
|
ruby-progressbar (~> 1.7)
|
38
38
|
unicode-display_width (>= 1.4.0, < 1.7)
|
39
|
-
rubocop-performance (1.5.
|
39
|
+
rubocop-performance (1.5.2)
|
40
40
|
rubocop (>= 0.71.0)
|
41
41
|
ruby-progressbar (1.10.1)
|
42
|
-
unicode-display_width (1.6.
|
42
|
+
unicode-display_width (1.6.1)
|
43
43
|
|
44
44
|
PLATFORMS
|
45
45
|
ruby
|
@@ -53,4 +53,4 @@ DEPENDENCIES
|
|
53
53
|
rubocop-performance
|
54
54
|
|
55
55
|
BUNDLED WITH
|
56
|
-
1.
|
56
|
+
2.1.2
|
data/lib/pbio/delimited.rb
CHANGED
@@ -36,6 +36,11 @@ module PBIO
|
|
36
36
|
# @param [IO] io object
|
37
37
|
def initialize(io)
|
38
38
|
@io = io
|
39
|
+
if @io.respond_to?(:binmode)
|
40
|
+
@io.binmode
|
41
|
+
elsif @io.respond_to?(:set_encoding)
|
42
|
+
@io.set_encoding(Encoding::BINARY)
|
43
|
+
end
|
39
44
|
end
|
40
45
|
|
41
46
|
# Writes a message to the IO stream.
|
data/pbio.gemspec
CHANGED
@@ -12,6 +12,7 @@ describe PBIO::Delimited do
|
|
12
12
|
expect(subject.write(msg1)).to eq(9)
|
13
13
|
expect(subject.write(msg2)).to eq(9)
|
14
14
|
expect(io.size).to eq(18)
|
15
|
+
expect(io.string.encoding).to eq(Encoding::BINARY)
|
15
16
|
|
16
17
|
expect(subject.write(msg3)).to eq(32_007)
|
17
18
|
expect(io.size).to eq(32_025)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pbio
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dimitrij Denissenko
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: google-protobuf
|
@@ -102,7 +102,6 @@ extensions: []
|
|
102
102
|
extra_rdoc_files: []
|
103
103
|
files:
|
104
104
|
- ".gitignore"
|
105
|
-
- ".rubocop-https---gitlab-com-bsm-misc-raw-master-rubocop-default-yml"
|
106
105
|
- ".rubocop.yml"
|
107
106
|
- ".travis.yml"
|
108
107
|
- Gemfile
|
@@ -1,78 +0,0 @@
|
|
1
|
-
AllCops:
|
2
|
-
Exclude:
|
3
|
-
- "db/schema.rb"
|
4
|
-
- "vendor/**/*"
|
5
|
-
- "**/*_pb.rb"
|
6
|
-
|
7
|
-
Metrics/AbcSize:
|
8
|
-
Enabled: false
|
9
|
-
Metrics/BlockLength:
|
10
|
-
Exclude:
|
11
|
-
- "**/*.rake"
|
12
|
-
- "db/**/*.rb"
|
13
|
-
- "**/spec/**/*.rb"
|
14
|
-
- "**/*.gemspec"
|
15
|
-
Metrics/ClassLength:
|
16
|
-
Max: 1500
|
17
|
-
Metrics/CyclomaticComplexity:
|
18
|
-
Max: 20
|
19
|
-
Metrics/LineLength:
|
20
|
-
Max: 160
|
21
|
-
Metrics/MethodLength:
|
22
|
-
Max: 20
|
23
|
-
Exclude:
|
24
|
-
- "db/**/*.rb"
|
25
|
-
Metrics/ModuleLength:
|
26
|
-
Exclude:
|
27
|
-
- "**/*_spec.rb"
|
28
|
-
Metrics/PerceivedComplexity:
|
29
|
-
Max: 20
|
30
|
-
|
31
|
-
Layout/AlignArguments:
|
32
|
-
EnforcedStyle: with_fixed_indentation
|
33
|
-
Layout/AlignHash:
|
34
|
-
EnforcedHashRocketStyle: table
|
35
|
-
Layout/AlignParameters:
|
36
|
-
EnforcedStyle: with_fixed_indentation
|
37
|
-
Layout/EmptyLinesAroundBlockBody:
|
38
|
-
Exclude:
|
39
|
-
- "db/**/*.rb"
|
40
|
-
- "**/*.rake"
|
41
|
-
- "**/*_spec.rb"
|
42
|
-
Layout/EmptyLinesAroundClassBody:
|
43
|
-
Enabled: false
|
44
|
-
Layout/IndentFirstArrayElement:
|
45
|
-
EnforcedStyle: consistent
|
46
|
-
Layout/MultilineOperationIndentation:
|
47
|
-
Enabled: false
|
48
|
-
Layout/SpaceAroundEqualsInParameterDefault:
|
49
|
-
EnforcedStyle: no_space
|
50
|
-
Layout/SpaceInsideBlockBraces:
|
51
|
-
SpaceBeforeBlockParameters: false
|
52
|
-
|
53
|
-
Lint/AmbiguousBlockAssociation:
|
54
|
-
Exclude:
|
55
|
-
- "spec/**/*_spec.rb"
|
56
|
-
|
57
|
-
Style/ClassAndModuleChildren:
|
58
|
-
Enabled: false
|
59
|
-
Style/Documentation:
|
60
|
-
Enabled: false
|
61
|
-
Style/FrozenStringLiteralComment:
|
62
|
-
Enabled: false
|
63
|
-
Style/HashSyntax:
|
64
|
-
EnforcedStyle: ruby19_no_mixed_keys
|
65
|
-
Style/MultilineIfModifier:
|
66
|
-
Enabled: false
|
67
|
-
Style/NumericLiterals:
|
68
|
-
Enabled: false
|
69
|
-
Style/Semicolon:
|
70
|
-
AllowAsExpressionSeparator: true
|
71
|
-
Style/SingleLineBlockParams:
|
72
|
-
Enabled: false
|
73
|
-
Style/TrailingCommaInArguments:
|
74
|
-
EnforcedStyleForMultiline: consistent_comma
|
75
|
-
Style/TrailingCommaInArrayLiteral:
|
76
|
-
EnforcedStyleForMultiline: consistent_comma
|
77
|
-
Style/TrailingCommaInHashLiteral:
|
78
|
-
EnforcedStyleForMultiline: consistent_comma
|