bfs-gs 0.6.3 → 0.7.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/bfs-gs.gemspec +1 -1
  3. data/lib/bfs/bucket/gs.rb +10 -7
  4. metadata +6 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d983acad48732ac1b9aefe1c9e24d38e69555a16d5888ab44628e3961af8248
4
- data.tar.gz: 5b2c07919f56f3063fa2dd2f6f7446305dca58fb0686e3c3a035812580a25735
3
+ metadata.gz: afb6b88566a06b714276613bb998fb3d4d02dd8534ba2210a57b2a215d567c14
4
+ data.tar.gz: 26b4631d61959bd3d02c45fcd7a02e9c5d64e4aadfdce9f9beee6051185097f4
5
5
  SHA512:
6
- metadata.gz: 22f44daf6914f672d9c214e0a2f048cdd413a977ba180ed08010cf5c6bef55f7bba85d792fc16f0389ea0027277ef83cc47573edf9d0482791d598438c36b7ad
7
- data.tar.gz: 213fa8a1545fbae970c01d54cb0665967a2b10db6c1f07603836d83a505125fe04870d3304a1688e6ec783eeee37a1f74e702333291a512a5ecfe096a90c1023
6
+ metadata.gz: 37352e78eec850efe6aa791e25597bf17fec5efec0088826736865320ba99d1a6ae24e8c818df45ffe0fd10abe8111258603cb272c5116e9bec3d0b0792671fe
7
+ data.tar.gz: 1e3e729c4c231821a09e045d94f9e38f10b530de567e8bad1eacccb2ecc6abe79c4736dd6031a8e306adfe26d5565bb1b967c4dcfffb04f826aff3c3335ee890
@@ -15,7 +15,7 @@ Gem::Specification.new do |s|
15
15
  s.files = `git ls-files`.split("\n")
16
16
  s.test_files = `git ls-files -- spec/*`.split("\n")
17
17
  s.require_paths = ['lib']
18
- s.required_ruby_version = '>= 2.5.0'
18
+ s.required_ruby_version = '>= 2.6.0'
19
19
 
20
20
  s.add_dependency 'bfs', s.version
21
21
  s.add_dependency 'google-cloud-storage', '~> 1.18'
@@ -33,7 +33,7 @@ module BFS
33
33
 
34
34
  # Lists the contents of a bucket using a glob pattern
35
35
  def ls(pattern = '**/*', **opts)
36
- prefix = pattern[%r{^[^\*\?\{\}\[\]]+/}]
36
+ prefix = pattern[%r{^[^*?\{\}\[\]]+/}]
37
37
  prefix = File.join(*[@prefix, prefix].compact) if @prefix
38
38
  opts = opts.merge(prefix: prefix) if prefix
39
39
 
@@ -105,12 +105,15 @@ module BFS
105
105
  end
106
106
  end
107
107
 
108
- BFS.register('gs') do |url, opts|
108
+ BFS.register('gs') do |url, opts, block|
109
109
  prefix = BFS.norm_path(opts.key?(:prefix) ? opts[:prefix] : url.path)
110
110
  prefix = nil if prefix.empty?
111
-
112
- BFS::Bucket::GS.new url.host, **opts.slice(:project_id, :credentials, :acl),
113
- prefix: prefix,
114
- timeout: opts.key?(:timeout) ? opts[:timeout].to_i : nil,
115
- retries: opts.key?(:retries) ? opts[:retries].to_i : nil
111
+ opts = opts.slice(:project_id, :credentials, :acl)
112
+ extra = {
113
+ prefix: prefix,
114
+ timeout: opts.key?(:timeout) ? opts[:timeout].to_i : nil,
115
+ retries: opts.key?(:retries) ? opts[:retries].to_i : nil,
116
+ }
117
+
118
+ BFS::Bucket::GS.open url.host, **opts, **extra, &block
116
119
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bfs-gs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.3
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dimitrij Denissenko
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-02-13 00:00:00.000000000 Z
11
+ date: 2020-07-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bfs
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 0.6.3
19
+ version: 0.7.2
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 0.6.3
26
+ version: 0.7.2
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: google-cloud-storage
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -60,14 +60,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
60
60
  requirements:
61
61
  - - ">="
62
62
  - !ruby/object:Gem::Version
63
- version: 2.5.0
63
+ version: 2.6.0
64
64
  required_rubygems_version: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  requirements: []
70
- rubygems_version: 3.1.2
70
+ rubygems_version: 3.1.4
71
71
  signing_key:
72
72
  specification_version: 4
73
73
  summary: GS bucket adapter for bfs