aws_imageshack 0.2.0 → 0.3.0
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.
- data/Rakefile +6 -12
- data/aws_imageshack-0.2.0.gem +0 -0
- data/lib/aws_imageshack.rb +3 -0
- metadata +20 -6
data/Rakefile
CHANGED
@@ -6,17 +6,6 @@ require 'rake/rdoctask'
|
|
6
6
|
require 'rake/packagetask'
|
7
7
|
require 'rake/gempackagetask'
|
8
8
|
|
9
|
-
desc 'Default: run unit tests.'
|
10
|
-
task :default => :test
|
11
|
-
|
12
|
-
desc 'Test the aws_imageshack plugin.'
|
13
|
-
Rake::TestTask.new(:test) do |t|
|
14
|
-
t.libs << 'lib'
|
15
|
-
t.libs << 'test'
|
16
|
-
t.pattern = 'test/**/*_test.rb'
|
17
|
-
t.verbose = true
|
18
|
-
end
|
19
|
-
|
20
9
|
desc 'Generate documentation for the aws_imageshack plugin.'
|
21
10
|
Rake::RDocTask.new(:rdoc) do |rdoc|
|
22
11
|
rdoc.rdoc_dir = 'rdoc'
|
@@ -28,12 +17,17 @@ end
|
|
28
17
|
|
29
18
|
spec = Gem::Specification.new do |s|
|
30
19
|
s.name = "aws_imageshack"
|
31
|
-
s.version = "0.
|
20
|
+
s.version = "0.3.0"
|
32
21
|
s.author = "Denis FABIEN"
|
33
22
|
s.email = "denis@miseajour.net"
|
23
|
+
s.add_dependency('multipart-post')
|
34
24
|
s.homepage = "http://www.miseajour.net/une-gem-pour-surveiller-la-modification-des-champs.html"
|
35
25
|
s.platform = Gem::Platform::RUBY
|
36
26
|
s.summary = "Use ImageShack to host your image, with un ajax upload form"
|
27
|
+
s.description = <<-EOF
|
28
|
+
The gem allow to use imageshack to host your images. You just need to require and API key on imageshack
|
29
|
+
EOF
|
30
|
+
|
37
31
|
s.files = FileList[
|
38
32
|
'[a-zA-Z]*',
|
39
33
|
'lib/**/*']
|
Binary file
|
data/lib/aws_imageshack.rb
CHANGED
@@ -49,6 +49,7 @@ with(window.parent) { setTimeout(function() { window.eval('#{self.class.helpers.
|
|
49
49
|
def aws_imageshack_save(params, api_key)
|
50
50
|
require "net/http"
|
51
51
|
require "net/http/post/multipart"
|
52
|
+
return '' if params[:aws][:fileupload] == ''
|
52
53
|
|
53
54
|
name = params[:aws][:fileupload].original_filename
|
54
55
|
directory = 'tmp/uploads'
|
@@ -91,4 +92,6 @@ with(window.parent) { setTimeout(function() { window.eval('#{self.class.helpers.
|
|
91
92
|
end
|
92
93
|
end
|
93
94
|
end
|
95
|
+
ActionController::Base.helper AwsImageshack::ViewHelpersMethods
|
96
|
+
ActionController::Base.send :include, AwsImageshack::PublicControllerMethods
|
94
97
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws_imageshack
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 19
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
|
-
-
|
8
|
+
- 3
|
9
9
|
- 0
|
10
|
-
version: 0.
|
10
|
+
version: 0.3.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Denis FABIEN
|
@@ -17,9 +17,22 @@ cert_chain: []
|
|
17
17
|
|
18
18
|
date: 2010-12-29 00:00:00 -05:00
|
19
19
|
default_executable:
|
20
|
-
dependencies:
|
21
|
-
|
22
|
-
|
20
|
+
dependencies:
|
21
|
+
- !ruby/object:Gem::Dependency
|
22
|
+
name: multipart-post
|
23
|
+
prerelease: false
|
24
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
hash: 3
|
30
|
+
segments:
|
31
|
+
- 0
|
32
|
+
version: "0"
|
33
|
+
type: :runtime
|
34
|
+
version_requirements: *id001
|
35
|
+
description: " The gem allow to use imageshack to host your images. You just need to require and API key on imageshack\n"
|
23
36
|
email: denis@miseajour.net
|
24
37
|
executables: []
|
25
38
|
|
@@ -29,6 +42,7 @@ extra_rdoc_files:
|
|
29
42
|
- README
|
30
43
|
files:
|
31
44
|
- aws_imageshack-0.1.0.gem
|
45
|
+
- aws_imageshack-0.2.0.gem
|
32
46
|
- init.rb
|
33
47
|
- install.rb
|
34
48
|
- MIT-LICENSE
|