files.com 1.0.210 → 1.0.211
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/_VERSION +1 -1
- data/docs/file.md +1 -22
- data/lib/files.com/models/file.rb +2 -20
- 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: 67f2512d48c8972612804b1fa4847652a4b4cc28ad3fd1720c15ecc525d92ab0
|
4
|
+
data.tar.gz: e36e60d409ad93cdd6038c8ef7bbd38f383517e9d2e7dc64e17fa93050f576a9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 33e9d96ca582e97d1b91f3af0022433a2aa967b96ca6d13d20ec518ae86603540dd7ede9e5a9abb8bbff0e9a7cd6c6e542f7b7ff57901a7cf1d685a4d0ba4c25
|
7
|
+
data.tar.gz: e41dc8e333884f93d9b7f76dffb71d6358f6729b56d936147d2cabf49bdcf9b28f41bb35a23af70f4acea5e29a47bce6f00a9f50c29a0dc7479528c9dcc8d12a
|
data/_VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.211
|
data/docs/file.md
CHANGED
@@ -153,7 +153,7 @@ Files::File.delete(path,
|
|
153
153
|
## Return metadata for file/folder
|
154
154
|
|
155
155
|
```
|
156
|
-
Files::File.
|
156
|
+
Files::File.find_by(path,
|
157
157
|
with_previews: true,
|
158
158
|
with_priority_color: true
|
159
159
|
)
|
@@ -287,27 +287,6 @@ file.delete(
|
|
287
287
|
* `recursive` (boolean): If true, will recursively delete folers. Otherwise, will error on non-empty folders.
|
288
288
|
|
289
289
|
|
290
|
-
---
|
291
|
-
|
292
|
-
## Return metadata for file/folder
|
293
|
-
|
294
|
-
```
|
295
|
-
file = Files::File.list_for(path).first
|
296
|
-
|
297
|
-
file.metadata(
|
298
|
-
with_previews: true,
|
299
|
-
with_priority_color: true
|
300
|
-
)
|
301
|
-
```
|
302
|
-
|
303
|
-
### Parameters
|
304
|
-
|
305
|
-
* `path` (string): Required - Path to operate on.
|
306
|
-
* `preview_size` (string): Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
|
307
|
-
* `with_previews` (boolean): Include file preview information?
|
308
|
-
* `with_priority_color` (boolean): Include file priority color information?
|
309
|
-
|
310
|
-
|
311
290
|
---
|
312
291
|
|
313
292
|
## Copy file/folder
|
@@ -867,23 +867,6 @@ module Files
|
|
867
867
|
delete(params)
|
868
868
|
end
|
869
869
|
|
870
|
-
# Return metadata for file/folder
|
871
|
-
#
|
872
|
-
# Parameters:
|
873
|
-
# preview_size - string - Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
|
874
|
-
# with_previews - boolean - Include file preview information?
|
875
|
-
# with_priority_color - boolean - Include file priority color information?
|
876
|
-
def metadata(params = {})
|
877
|
-
params ||= {}
|
878
|
-
params[:path] = @attributes[:path]
|
879
|
-
raise MissingParameterError.new("Current object doesn't have a path") unless @attributes[:path]
|
880
|
-
raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
|
881
|
-
raise InvalidParameterError.new("Bad parameter: preview_size must be an String") if params.dig(:preview_size) and !params.dig(:preview_size).is_a?(String)
|
882
|
-
raise MissingParameterError.new("Parameter missing: path") unless params.dig(:path)
|
883
|
-
|
884
|
-
Api.send_request("/file_actions/metadata/#{@attributes[:path]}", :get, params, @options)
|
885
|
-
end
|
886
|
-
|
887
870
|
# Copy file/folder
|
888
871
|
#
|
889
872
|
# Parameters:
|
@@ -1029,13 +1012,12 @@ module Files
|
|
1029
1012
|
delete(path, params, options)
|
1030
1013
|
end
|
1031
1014
|
|
1032
|
-
# Return metadata for file/folder
|
1033
|
-
#
|
1034
1015
|
# Parameters:
|
1016
|
+
# path (required) - string - Path to operate on.
|
1035
1017
|
# preview_size - string - Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
|
1036
1018
|
# with_previews - boolean - Include file preview information?
|
1037
1019
|
# with_priority_color - boolean - Include file priority color information?
|
1038
|
-
def self.
|
1020
|
+
def self.find_by(path, params = {}, options = {})
|
1039
1021
|
params ||= {}
|
1040
1022
|
params[:path] = path
|
1041
1023
|
raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: files.com
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.211
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- files.com
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-09-
|
11
|
+
date: 2021-09-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|