files.com 1.1.182 → 1.1.184
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/README.md +12 -12
- data/_VERSION +1 -1
- data/docs/automation.md +2 -2
- data/docs/behavior.md +1 -1
- data/docs/dns_record.md +1 -1
- data/docs/file.md +12 -12
- data/docs/folder.md +1 -1
- data/docs/site.md +2 -2
- data/lib/files.com/models/automation.rb +2 -2
- data/lib/files.com/models/file.rb +6 -6
- data/lib/files.com/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cd0a46c86c2167b17f252df78fa169f60de881435cc95db697e1fc4644230b81
|
4
|
+
data.tar.gz: 4ec5646cf1c4ecf8fde063a312189e47e7d995ed53acb26c7ad314498486de0e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 43c08967c994d4a2048d2ff0142c2553faeccddc562a3f664e5aa08b7f045486a8d2a140297c4c359b331b1fc849cd0c0f25ab79d704e556c13476f85fb7357a
|
7
|
+
data.tar.gz: 530629ff255de9e1433c6068e0865cf5e88bdd60ec2b2d4ba417bc4dc8b4823fd6312740c12073a416fd50da3b8e01e17d5bd9656b84e73fa727b4532abc7113
|
data/README.md
CHANGED
@@ -519,26 +519,18 @@ A README is available on the GitHub link.
|
|
519
519
|
|
520
520
|
## File/Folder Operations
|
521
521
|
|
522
|
-
### File Operations
|
523
|
-
|
524
522
|
The Files::File and Files::Dir models implement the standard Ruby API
|
525
523
|
for File and Dir, respectively. (Note that the Files.com SDK uses the
|
526
524
|
word Folder, not Dir, and Files::Dir is simply an alias for
|
527
525
|
Files::Folder).
|
528
526
|
|
529
|
-
|
530
|
-
|
531
|
-
```ruby
|
532
|
-
Files::Folder.list_for("/").each do |file|
|
533
|
-
puts file.path
|
534
|
-
end
|
535
|
-
```
|
536
|
-
|
537
|
-
#### Writing a File
|
527
|
+
### Upload
|
538
528
|
|
539
529
|
```ruby
|
530
|
+
## Upload a file on disk.
|
540
531
|
Files::upload_file("local.txt", "/remote.txt")
|
541
532
|
|
533
|
+
## Upload raw file data.
|
542
534
|
File.open("local.txt") do |local_file|
|
543
535
|
Files::File.open("remote.txt", "w") do |remote_file|
|
544
536
|
remote_file.write(local_file.read)
|
@@ -546,8 +538,16 @@ File.open("local.txt") do |local_file|
|
|
546
538
|
end
|
547
539
|
```
|
548
540
|
|
549
|
-
|
541
|
+
### Download
|
550
542
|
|
551
543
|
```ruby
|
552
544
|
Files::File.find("foo.txt").read
|
553
545
|
```
|
546
|
+
|
547
|
+
### List
|
548
|
+
|
549
|
+
```ruby
|
550
|
+
Files::Folder.list_for("/").each do |file|
|
551
|
+
puts file.path
|
552
|
+
end
|
553
|
+
```
|
data/_VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.1.
|
1
|
+
1.1.184
|
data/docs/automation.md
CHANGED
@@ -201,7 +201,7 @@ Files::Automation.create(
|
|
201
201
|
|
202
202
|
---
|
203
203
|
|
204
|
-
## Manually
|
204
|
+
## Manually Run Automation
|
205
205
|
|
206
206
|
```
|
207
207
|
Files::Automation.manual_run(id)
|
@@ -295,7 +295,7 @@ Files::Automation.delete(id)
|
|
295
295
|
|
296
296
|
---
|
297
297
|
|
298
|
-
## Manually
|
298
|
+
## Manually Run Automation
|
299
299
|
|
300
300
|
```
|
301
301
|
automation = Files::Automation.find(id)
|
data/docs/behavior.md
CHANGED
data/docs/dns_record.md
CHANGED
data/docs/file.md
CHANGED
@@ -101,7 +101,7 @@ may places where a Ruby File object can be used.
|
|
101
101
|
|
102
102
|
---
|
103
103
|
|
104
|
-
## Download
|
104
|
+
## Download File
|
105
105
|
|
106
106
|
```
|
107
107
|
Files::File.download(path,
|
@@ -121,7 +121,7 @@ Files::File.download(path,
|
|
121
121
|
|
122
122
|
---
|
123
123
|
|
124
|
-
## Upload
|
124
|
+
## Upload File
|
125
125
|
|
126
126
|
```
|
127
127
|
Files::File.create(path,
|
@@ -156,7 +156,7 @@ Files::File.create(path,
|
|
156
156
|
|
157
157
|
---
|
158
158
|
|
159
|
-
## Update
|
159
|
+
## Update File/Folder Metadata
|
160
160
|
|
161
161
|
```
|
162
162
|
Files::File.update(path,
|
@@ -176,7 +176,7 @@ Files::File.update(path,
|
|
176
176
|
|
177
177
|
---
|
178
178
|
|
179
|
-
## Delete
|
179
|
+
## Delete File/Folder
|
180
180
|
|
181
181
|
```
|
182
182
|
Files::File.delete(path,
|
@@ -192,7 +192,7 @@ Files::File.delete(path,
|
|
192
192
|
|
193
193
|
---
|
194
194
|
|
195
|
-
## Find
|
195
|
+
## Find File/Folder by Path
|
196
196
|
|
197
197
|
```
|
198
198
|
Files::File.find(path,
|
@@ -211,7 +211,7 @@ Files::File.find(path,
|
|
211
211
|
|
212
212
|
---
|
213
213
|
|
214
|
-
## Copy
|
214
|
+
## Copy File/Folder
|
215
215
|
|
216
216
|
```
|
217
217
|
Files::File.copy(path,
|
@@ -231,7 +231,7 @@ Files::File.copy(path,
|
|
231
231
|
|
232
232
|
---
|
233
233
|
|
234
|
-
## Move
|
234
|
+
## Move File/Folder
|
235
235
|
|
236
236
|
```
|
237
237
|
Files::File.move(path,
|
@@ -277,7 +277,7 @@ Files::File.begin_upload(path,
|
|
277
277
|
|
278
278
|
---
|
279
279
|
|
280
|
-
## Download
|
280
|
+
## Download File
|
281
281
|
|
282
282
|
```
|
283
283
|
file = Files::File.find(path)
|
@@ -299,7 +299,7 @@ file.download(
|
|
299
299
|
|
300
300
|
---
|
301
301
|
|
302
|
-
## Update
|
302
|
+
## Update File/Folder Metadata
|
303
303
|
|
304
304
|
```
|
305
305
|
file = Files::File.find(path)
|
@@ -321,7 +321,7 @@ file.update(
|
|
321
321
|
|
322
322
|
---
|
323
323
|
|
324
|
-
## Delete
|
324
|
+
## Delete File/Folder
|
325
325
|
|
326
326
|
```
|
327
327
|
file = Files::File.find(path)
|
@@ -339,7 +339,7 @@ file.delete(
|
|
339
339
|
|
340
340
|
---
|
341
341
|
|
342
|
-
## Copy
|
342
|
+
## Copy File/Folder
|
343
343
|
|
344
344
|
```
|
345
345
|
file = Files::File.find(path)
|
@@ -361,7 +361,7 @@ file.copy(
|
|
361
361
|
|
362
362
|
---
|
363
363
|
|
364
|
-
## Move
|
364
|
+
## Move File/Folder
|
365
365
|
|
366
366
|
```
|
367
367
|
file = Files::File.find(path)
|
data/docs/folder.md
CHANGED
data/docs/site.md
CHANGED
@@ -472,7 +472,7 @@
|
|
472
472
|
|
473
473
|
---
|
474
474
|
|
475
|
-
## Show
|
475
|
+
## Show Site Settings
|
476
476
|
|
477
477
|
```
|
478
478
|
Files::Site.get
|
@@ -490,7 +490,7 @@ Files::Site.get_usage
|
|
490
490
|
|
491
491
|
---
|
492
492
|
|
493
|
-
## Update
|
493
|
+
## Update Site Settings
|
494
494
|
|
495
495
|
```
|
496
496
|
Files::Site.update(
|
@@ -315,7 +315,7 @@ module Files
|
|
315
315
|
@attributes[:webhook_url] = value
|
316
316
|
end
|
317
317
|
|
318
|
-
# Manually
|
318
|
+
# Manually Run Automation
|
319
319
|
def manual_run(params = {})
|
320
320
|
params ||= {}
|
321
321
|
params[:id] = @attributes[:id]
|
@@ -510,7 +510,7 @@ module Files
|
|
510
510
|
Automation.new(response.data, options)
|
511
511
|
end
|
512
512
|
|
513
|
-
# Manually
|
513
|
+
# Manually Run Automation
|
514
514
|
def self.manual_run(id, params = {}, options = {})
|
515
515
|
params ||= {}
|
516
516
|
params[:id] = id
|
@@ -958,7 +958,7 @@ module Files
|
|
958
958
|
@attributes[:with_rename] = value
|
959
959
|
end
|
960
960
|
|
961
|
-
# Download
|
961
|
+
# Download File
|
962
962
|
#
|
963
963
|
# Parameters:
|
964
964
|
# action - string - Can be blank, `redirect` or `stat`. If set to `stat`, we will return file information but without a download URL, and without logging a download. If set to `redirect` we will serve a 302 redirect directly to the file. This is used for integrations with Zapier, and is not recommended for most integrations.
|
@@ -1010,7 +1010,7 @@ module Files
|
|
1010
1010
|
nil
|
1011
1011
|
end
|
1012
1012
|
|
1013
|
-
# Copy
|
1013
|
+
# Copy File/Folder
|
1014
1014
|
#
|
1015
1015
|
# Parameters:
|
1016
1016
|
# destination (required) - string - Copy destination path.
|
@@ -1028,7 +1028,7 @@ module Files
|
|
1028
1028
|
Api.send_request("/file_actions/copy/#{@attributes[:path]}", :post, params, @options)
|
1029
1029
|
end
|
1030
1030
|
|
1031
|
-
# Move
|
1031
|
+
# Move File/Folder
|
1032
1032
|
#
|
1033
1033
|
# Parameters:
|
1034
1034
|
# destination (required) - string - Move destination path.
|
@@ -1076,7 +1076,7 @@ module Files
|
|
1076
1076
|
true
|
1077
1077
|
end
|
1078
1078
|
|
1079
|
-
# Download
|
1079
|
+
# Download File
|
1080
1080
|
#
|
1081
1081
|
# Parameters:
|
1082
1082
|
# action - string - Can be blank, `redirect` or `stat`. If set to `stat`, we will return file information but without a download URL, and without logging a download. If set to `redirect` we will serve a 302 redirect directly to the file. This is used for integrations with Zapier, and is not recommended for most integrations.
|
@@ -1183,7 +1183,7 @@ module Files
|
|
1183
1183
|
find(path, params, options)
|
1184
1184
|
end
|
1185
1185
|
|
1186
|
-
# Copy
|
1186
|
+
# Copy File/Folder
|
1187
1187
|
#
|
1188
1188
|
# Parameters:
|
1189
1189
|
# destination (required) - string - Copy destination path.
|
@@ -1201,7 +1201,7 @@ module Files
|
|
1201
1201
|
FileAction.new(response.data, options)
|
1202
1202
|
end
|
1203
1203
|
|
1204
|
-
# Move
|
1204
|
+
# Move File/Folder
|
1205
1205
|
#
|
1206
1206
|
# Parameters:
|
1207
1207
|
# destination (required) - string - Move destination path.
|
data/lib/files.com/version.rb
CHANGED