googledrive-easy 0.0.5 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/googledrive-easy.rb +2 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f2e510a7a4388feec9cbfffcbf6095e2b90f73cd882b81558014b9bc9147d4ed
|
4
|
+
data.tar.gz: 5940d24cf857bd29da87277dfcf0135a47890b3d37b087eddc5cbeb19084c464
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f934c27d0bc9014b1f8f514e036bcfe2e22355a3e4125a11aaa287cfbec935fdef49eae7372ef18e11f76765dbb22e7b95ac466e2f432647459b7d0e8441bae
|
7
|
+
data.tar.gz: b5bf2997933c7e475e8f5d254a49ed029c52ec910b9653042f59661dccd6516bb4419962a35582b466b646da1aad4c4cea2c43e637e696d2048152b0641cf577
|
data/lib/googledrive-easy.rb
CHANGED
@@ -292,12 +292,12 @@ class GoogleDrive
|
|
292
292
|
return file_list.first[:id]
|
293
293
|
end
|
294
294
|
|
295
|
-
def upload_file(file, directory_id
|
295
|
+
def upload_file(file, directory_id: nil)
|
296
296
|
|
297
297
|
file_basename = File.basename(file)
|
298
298
|
|
299
299
|
# see if file exists on Drive
|
300
|
-
file_list =
|
300
|
+
file_list = self.get_all_files(justfiles: true, parentfolderid: directory_id, name: file_basename)
|
301
301
|
if file_list.count > 0
|
302
302
|
if @raise_error; raise "ERROR: File '#{file_basename}' already exists." end
|
303
303
|
return false
|
@@ -344,7 +344,6 @@ end
|
|
344
344
|
# "mimeType": "application/gzip"
|
345
345
|
# }
|
346
346
|
|
347
|
-
|
348
347
|
# check that name = filename
|
349
348
|
# check that kind = drive#file
|
350
349
|
if !response.key?("name") # name key does not exist
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: googledrive-easy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Bullock
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-02-
|
11
|
+
date: 2022-02-16 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Easy File interface to Google Drive
|
14
14
|
email: jmb@rgnets.com
|