fiverr_copy 0.0.14 → 0.0.15

Sign up to get free protection for your applications and to get access to all the features.
@@ -56,7 +56,7 @@ class FiverrCopy::Client
56
56
  end
57
57
 
58
58
  temp_file = Tempfile.new("fiverr_copy_#{Time.now.to_i}.tgz")
59
- Tempfile.open(temp_file) do |f|
59
+ File.new(filename, "w+") do |f|
60
60
  Thread.start do
61
61
  while (stream = session.read(chunk)) do
62
62
 
@@ -72,6 +72,5 @@ class FiverrCopy::Client
72
72
  end #end thread conversation
73
73
  end
74
74
  puts "Done."
75
- FileUtils.mv(temp_file.path, "#{Dir.pwd}/#{filename}")
76
75
  end
77
76
  end
@@ -65,7 +65,7 @@ class FiverrCopy::Server
65
65
  File.open("#{compressed_file_name}") do |transmitted_file|
66
66
  client_session.puts "FILENAME:#{"#{compressed_file_name}"}"
67
67
  puts "Transmitting #{transmitted_file.to_s} (#{File.size(transmitted_file)})"
68
- while !(client_session.closed?) && (client_response = client_session.gets) && (buffer = transmitted_file.read(self.recipe.chunk_size)) do
68
+ while !(client_session.closed?) && (buffer = transmitted_file.read(self.recipe.chunk_size)) do
69
69
  puts "Sending #{buffer.size}B"
70
70
  client_session.puts buffer
71
71
  end
@@ -1,3 +1,3 @@
1
1
  module FiverrCopy
2
- VERSION = "0.0.14"
2
+ VERSION = "0.0.15"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fiverr_copy
3
3
  version: !ruby/object:Gem::Version
4
- hash: 3
4
+ hash: 1
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 14
10
- version: 0.0.14
9
+ - 15
10
+ version: 0.0.15
11
11
  platform: ruby
12
12
  authors:
13
13
  - Elad Meidar