bfs-ftp 0.7.4 → 0.7.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/bfs/bucket/ftp.rb +2 -9
  3. metadata +4 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a5820d3e120364beff252e9be4627e000b78ada20644d8bd5c84ad4eb44eb3e1
4
- data.tar.gz: bac8723f260ec70508c558b8e6ca777741f91794efd4ee2ef31334c328076d28
3
+ metadata.gz: e82797725ebe072d7a7d384baaf2409ad28c14a12e01e5dcf93fc43f611db082
4
+ data.tar.gz: fa949c1d80de980559ac17cd05d103a7b226e02b650a64b81a949fc7bc83fbad
5
5
  SHA512:
6
- metadata.gz: 45921227dd24fe1a7114b8933bdf0beebe12ff85a2e3e6dfb98a1b8c011a446e60e5f48f5a7861d3c0a29a9a5cf34dc21a0fe2e7bd0623cea7ec0d7898dfffd4
7
- data.tar.gz: f4c815dfaeb5f3c553dc629627af46857a3a38dbf49381fde8a65a66de94a903b6ed752f7d3e37344958b85fec79cc018a7ba818eee4f28f964b75aa1f53ec7e
6
+ metadata.gz: 07a83b8967eb478a2b81a13bf369e6be61b8c921baa1a773e2a4132a0e73968ec2c21be07be0acce6d7cf04c1140ba9ca00e0073de9823faebb3c7a0ab074d5b
7
+ data.tar.gz: fe4f046c10dcf18e2f657d1b6b780e555b99e9fc6db252bd158547ca6fb43f490180184a729d25365d8df769ad7c63d090b9c590a38f9c9609e5934b6e2d75fa
@@ -52,17 +52,10 @@ module BFS
52
52
  # Creates a new file and opens it for writing
53
53
  def create(path, encoding: self.encoding, perm: self.perm, **_opts, &block)
54
54
  path = norm_path(path)
55
- temp = BFS::TempWriter.new(path, encoding: encoding, perm: perm) do |t|
55
+ BFS::TempWriter.new(path, encoding: encoding, perm: perm) do |t|
56
56
  mkdir_p File.dirname(path)
57
57
  @client.put(t, path)
58
- end
59
- return temp unless block
60
-
61
- begin
62
- yield temp
63
- ensure
64
- temp.close
65
- end
58
+ end.perform(&block)
66
59
  end
67
60
 
68
61
  # Opens an existing file for reading
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bfs-ftp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.4
4
+ version: 0.7.5
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-10-26 00:00:00.000000000 Z
11
+ date: 2020-11-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.7.4
19
+ version: 0.7.5
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.7.4
26
+ version: 0.7.5
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: net-ftp-list
29
29
  requirement: !ruby/object:Gem::Requirement