dropbox 0.0.9 → 0.0.10
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog.rdoc +5 -2
- data/VERSION +1 -1
- data/lib/dropbox/dropbox.rb +10 -2
- metadata +2 -2
data/ChangeLog.rdoc
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
== 0.0.10 (April 16, 2010):
|
2
|
+
* Fixed a bug downloading files (tvongaza)
|
3
|
+
|
1
4
|
== 0.0.9 (April 16, 2010):
|
2
5
|
* Really fixed bug with empty stats (chrissearle)
|
3
6
|
* Fixed a bug uploading files (Luka87)
|
@@ -6,8 +9,8 @@
|
|
6
9
|
* Fixed bug with empty stats (chrissearle)
|
7
10
|
|
8
11
|
== 0.0.7 (March 11, 2010):
|
9
|
-
* Fixed stats
|
10
|
-
* Added some additional documentation
|
12
|
+
* Fixed stats (chrissearle)
|
13
|
+
* Added some additional documentation (tvongaza)
|
11
14
|
* Running into issue creating files, anyone else?
|
12
15
|
|
13
16
|
== 0.0.6 (March 4, 2010);
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.10
|
data/lib/dropbox/dropbox.rb
CHANGED
@@ -18,6 +18,10 @@ class DropBox
|
|
18
18
|
@logged_in = false
|
19
19
|
end
|
20
20
|
|
21
|
+
def agent
|
22
|
+
@agent
|
23
|
+
end
|
24
|
+
|
21
25
|
# Lists all the files and folders in a given directory
|
22
26
|
def index(path = "/")
|
23
27
|
login_filter
|
@@ -79,13 +83,17 @@ class DropBox
|
|
79
83
|
|
80
84
|
# Downloads the specified file from DropBox
|
81
85
|
def show(path)
|
86
|
+
require 'pathname'
|
82
87
|
# change to before filter
|
83
88
|
login_filter
|
84
89
|
|
85
|
-
|
90
|
+
# round about way of getting the secure url we need
|
91
|
+
# path = namespace_path(path)
|
92
|
+
pathname = Pathname.new(path)
|
93
|
+
url = self.list(pathname.dirname.to_s).detect{ |f| f["name"] == pathname.basename.to_s }["url"]
|
86
94
|
|
87
95
|
#https://dl-web.dropbox.com/get/testing.txt?w=0ff80d5d&sjid=125987568
|
88
|
-
@agent.get(
|
96
|
+
@agent.get(url).content
|
89
97
|
end
|
90
98
|
|
91
99
|
alias :get :show
|