my-local-putio 4.4.0 → 4.4.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0645c62fc7702d0675aea5789b127e6a64e1b97daa7c56a79356db63994bec72
4
- data.tar.gz: c2d94609c5bee2a49befdb947b4631b0e33464efdc871ed23edf97ccce7a2260
3
+ metadata.gz: 9b97f8142ada24f92bd2ba81ad1a698bf75b730ecb98f7878a10ddf84bfc6968
4
+ data.tar.gz: b1616b5139f17b2528fa61637df6082be9d330980d13ac515bdbe398a2effc4a
5
5
  SHA512:
6
- metadata.gz: ec4015fbe7793a523bb37b430e38f0012c2e582ceee93f3a2f53b9f6de219a7b042070e1975583f384511cfb9f1870b11f5fc15741285a821aa25a3797f72fe8
7
- data.tar.gz: aceb70d9770dc59bb0f71b9e0e0b0e2944ec9d8d1e7d3949bcfb4f55ef7d2c4c214bfd9af18590cf016973dd8c4531f2109001f5661be46fc489128961c3e669
6
+ metadata.gz: 6c6b14174288fea62fe55b7b92b10afad8a0a8d2149c1bb2cebc73864b89caf7c45b6129ae658a2c03ef1a2420769ed877e1a6a3235f941a110500a8fac763e0
7
+ data.tar.gz: 60c701b5765e86541188bf4a43bd2b4c9fe69cc81809edfab416f657c640314bcf4a96d6ab1b2f9ea6ca57d13199c86b0e5f1289689efd76b535fa552c55fd51
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.6.3
1
+ 3.1.0
data/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ # v4.4.2
2
+
3
+ - Package updates
4
+
5
+ # v4.4.1
6
+
7
+ - Bugfix: Checking if folder is empty before removing it, due to per page limit
8
+ - Bugfix: Downloader creating folder dir when downloading a single file
9
+
1
10
  # v4.4.0
2
11
 
3
12
  - Introducing --detailed-progress
data/Gemfile.lock CHANGED
@@ -1,22 +1,22 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- my-local-putio (4.4.0)
4
+ my-local-putio (4.4.2)
5
5
  socksify (= 1.7.1)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- rake (13.0.1)
10
+ rake (13.0.6)
11
11
  socksify (1.7.1)
12
12
 
13
13
  PLATFORMS
14
14
  ruby
15
15
 
16
16
  DEPENDENCIES
17
- bundler (~> 2.0)
17
+ bundler (~> 2.3)
18
18
  my-local-putio!
19
19
  rake (~> 13.0)
20
20
 
21
21
  BUNDLED WITH
22
- 2.0.2
22
+ 2.3.17
data/Rakefile CHANGED
@@ -1,2 +1,3 @@
1
1
  require "bundler/gem_tasks"
2
+ require "fileutils"
2
3
  task :default => :spec
@@ -37,7 +37,7 @@ module MyLocalPutio
37
37
  end
38
38
 
39
39
  def download_command(url, path)
40
- temp_destination = File.join(configuration.temp_destination, path)
40
+ temp_destination = File.join(configuration.temp_destination, File.dirname(path))
41
41
 
42
42
  command = [
43
43
  "curl", "--create-dirs", "-L", "--retry", "5", "-S", "-C", "-", "-o", temp_destination, url.to_s
@@ -29,14 +29,20 @@ module MyLocalPutio
29
29
  def process_file(file, path)
30
30
  file_path = File.join(path, file.name)
31
31
  if file.content_type == "application/x-directory"
32
- fetch_files(id: file.id, path: file_path)
32
+ while !directory_empty?(file)
33
+ fetch_files(id: file.id, path: file_path)
34
+ end
33
35
  else
34
36
  url = cli.get_download_url(file.id)["url"]
35
37
  disk_manager.check_for_available_space_on_destinations!(file.size/1024/1024)
36
38
  Downloader.new(@configuration).download(url, file_path) unless file_exists?(file_path, file)
37
39
  SubtitlesManager.new(configuration).fetch(file, path)
38
40
  end
39
- delete_file(file_path, file)
41
+ delete_file(file_path, file)
42
+ end
43
+
44
+ def directory_empty?(file)
45
+ cli.get_files(file.id)["files"].count < 1
40
46
  end
41
47
 
42
48
  def delete_file(file_path, file)
@@ -1,3 +1,3 @@
1
1
  module MyLocalPutio
2
- VERSION = "4.4.0"
2
+ VERSION = "4.4.2"
3
3
  end
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
24
24
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
25
25
  spec.require_paths = ["lib"]
26
26
 
27
- spec.add_development_dependency "bundler", "~> 2.0"
27
+ spec.add_development_dependency "bundler", "~> 2.3"
28
28
  spec.add_development_dependency "rake", "~> 13.0"
29
29
  spec.add_dependency "socksify", "1.7.1"
30
30
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: my-local-putio
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.4.0
4
+ version: 4.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rafael Biriba
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-11 00:00:00.000000000 Z
11
+ date: 2022-07-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.0'
19
+ version: '2.3'
20
20
  type: :development
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: '2.0'
26
+ version: '2.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -85,7 +85,7 @@ metadata:
85
85
  homepage_uri: https://github.com/rafaelbiriba/my-local-putio
86
86
  source_code_uri: https://github.com/rafaelbiriba/my-local-putio
87
87
  changelog_uri: https://github.com/rafaelbiriba/my-local-putio/blob/master/CHANGELOG.md
88
- post_install_message:
88
+ post_install_message:
89
89
  rdoc_options: []
90
90
  require_paths:
91
91
  - lib
@@ -100,8 +100,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
100
100
  - !ruby/object:Gem::Version
101
101
  version: '0'
102
102
  requirements: []
103
- rubygems_version: 3.0.3
104
- signing_key:
103
+ rubygems_version: 3.3.3
104
+ signing_key:
105
105
  specification_version: 4
106
106
  summary: The easiest script to synchronise all your put.io files locally.
107
107
  test_files: []