paperdragon 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 14395b1c15c23ae0dd9b68795d714ce399b73c2b
4
- data.tar.gz: 6b7587815f2a57a3964cfbab14c2c81efbf06c35
3
+ metadata.gz: 2af4cc674da4c766be355baeb541aea52b73a2c0
4
+ data.tar.gz: 0fda345ec014359c597b6d090ab4efd23c952021
5
5
  SHA512:
6
- metadata.gz: 1fd4b681f89d0a3edae7a967613db00026df7a60adde0e0b3268df710c83c36a2a0c8405978906f09d4ce65dc154412fd1595eb9114e26047ac95100b9a7f625
7
- data.tar.gz: 525f69bd268b962dff804f6b169d402b8427d74f517fae18c4c65d34bdb9040429b3c1f20a55d2999c04f9d606765698da9083a38f770b58481220efcb41fc42
6
+ metadata.gz: f4e6cced395393045795cf8674f56b4e8dd8372bf8fa7b995d0cc720681818d295860a63e8c434a29f90ca6399ee5066bf6b60306e4233c1e211d8c61fcc047b
7
+ data.tar.gz: 3a3e9e574ad94bdf10ac8ddb06ce4088f2a4a773f57763fd5c70605afffbc1737bcc3eae2cf128201d50ae58b71d026bbb8b96252bca256c1921688f22aeb261
data/README.md CHANGED
@@ -217,7 +217,7 @@ class User < ActiveRecord::Base
217
217
 
218
218
  class Attachment < Paperdragon::Attachment
219
219
  def build_uid(style, file)
220
- "/path/to/#{style}/#{obfuscator}/#{file.original_filename}"
220
+ "/path/to/#{style}/#{obfuscator}/#{file.name}"
221
221
  end
222
222
 
223
223
  def obfuscator
@@ -1,3 +1,7 @@
1
+ # 0.0.10
2
+
3
+ * Require Dragonfly 1.0.12 or above and change internal API accordingly. Thanks @acaron for fixing that!
4
+
1
5
  # 0.0.9
2
6
 
3
7
  * Add `Task#delete!` which allows to delete files in task blocks.
@@ -64,7 +64,7 @@ module Paperdragon
64
64
 
65
65
  def build_uid(style, file)
66
66
  # can we use Dragonfly's API here?
67
- "#{style}-#{Dragonfly::TempObject.new(file).original_filename}"
67
+ "#{style}-#{Dragonfly::TempObject.new(file).name}"
68
68
  end
69
69
  end
70
70
 
@@ -1,3 +1,3 @@
1
1
  module Paperdragon
2
- VERSION = "0.0.9"
2
+ VERSION = "0.0.10"
3
3
  end
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
21
- spec.add_dependency "dragonfly"
21
+ spec.add_dependency "dragonfly", "~> 1.0.12"
22
22
  spec.add_dependency "uber"
23
23
 
24
24
  spec.add_development_dependency "bundler", "~> 1.6"
@@ -51,7 +51,7 @@ class PaperdragonFileTest < MiniTest::Spec
51
51
  job.thumb!("16x16")
52
52
  end
53
53
 
54
- assert file.data.size <= 457 # smaller after thumb!
54
+ assert file.data.size < 500 # smaller after thumb!
55
55
  end
56
56
 
57
57
  # additional metadata
@@ -106,7 +106,7 @@ class PaperdragonFileTest < MiniTest::Spec
106
106
 
107
107
  end
108
108
 
109
- assert file.data.size <= 457
109
+ assert file.data.size < 500
110
110
  end
111
111
  end
112
112
 
@@ -135,4 +135,4 @@ class PaperdragonFileTest < MiniTest::Spec
135
135
  exists?(new_uid).must_equal true
136
136
  end
137
137
  end
138
- end
138
+ end
@@ -6,7 +6,7 @@ class PaperclipUidTest < MiniTest::Spec
6
6
  Uid = Paperdragon::Paperclip::Uid
7
7
 
8
8
  let (:options) { {:class_name => :avatars, :attachment => :image, :id => 1234,
9
- :style => :original, :updated_at => Time.parse("20-06-2014 9:40:59").to_i,
9
+ :style => :original, :updated_at => Time.parse("20-06-2014 9:40:59 +1000").to_i,
10
10
  :file_name => "kristylee.jpg", :hash_secret => "secret"} }
11
11
 
12
12
  it { Uid.from(options).
@@ -54,4 +54,4 @@ class PaperclipModelTest < MiniTest::Spec
54
54
 
55
55
  # delegates all unknown methods back to Attachment.
56
56
  it { Avatar.new.image.exists?.must_equal "Of course!" }
57
- end
57
+ end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paperdragon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Sutterer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-25 00:00:00.000000000 Z
11
+ date: 2015-11-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dragonfly
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0'
19
+ version: 1.0.12
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ">="
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0'
26
+ version: 1.0.12
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: uber
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -147,4 +147,3 @@ test_files:
147
147
  - test/paperclip_uid_test.rb
148
148
  - test/task_test.rb
149
149
  - test/test_helper.rb
150
- has_rdoc: