image_size 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1 @@
1
+ /*.gemspec
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2010 Ivan Kuchin
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,29 @@
1
+ # image_size
2
+
3
+ measure image size using pure Ruby
4
+ formats: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF
5
+
6
+ ## Download
7
+
8
+ The latest version of image\_size can be found at http://github.com/toy/image_size
9
+
10
+ ## Installation
11
+
12
+ gem install image_size
13
+
14
+ ## Simple Example
15
+
16
+ ruby "rubygems" # you use rubygems
17
+ ruby "image_size"
18
+ ruby "open-uri"
19
+ open("http://www.rubycgi.org/image/ruby_gtk_book_title.jpg", "rb") do |fh|
20
+ p ImageSize.new(fh.read).size
21
+ end
22
+
23
+ ## Licence
24
+
25
+ This code is free to use under the terms of the Ruby's licence.
26
+
27
+ ## Contact
28
+
29
+ Original author: "Keisuke Minami": mailto:keisuke@rccn.com
data/Rakefile CHANGED
@@ -1,22 +1,21 @@
1
- require 'rubygems'
2
1
  require 'rake'
2
+ require 'jeweler'
3
+ require 'rake/gem_ghost_task'
3
4
 
4
5
  name = 'image_size'
5
6
 
6
- begin
7
- require 'jeweler'
8
-
9
- Jeweler::Tasks.new do |gem|
10
- gem.name = name
11
- gem.summary = %Q{measure image size using pure Ruby}
12
- gem.description = %Q{measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF}
13
- gem.homepage = "http://github.com/toy/#{name}"
14
- gem.authors = ['Keisuke Minami', 'Boba Fat']
15
- end
16
- Jeweler::GemcutterTasks.new
17
- rescue LoadError
18
- puts 'Jeweler (or a dependency) not available. Install it with: gem install jeweler'
7
+ Jeweler::Tasks.new do |gem|
8
+ gem.name = name
9
+ gem.summary = %Q{Measure image size using pure Ruby}
10
+ gem.description = %Q{Measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF}
11
+ gem.homepage = "http://github.com/toy/#{name}"
12
+ gem.license = 'MIT'
13
+ gem.authors = ['Ivan Kuchin']
14
+ gem.add_development_dependency 'jeweler', '~> 1.5.1'
15
+ gem.add_development_dependency 'rake-gem-ghost'
19
16
  end
17
+ Jeweler::RubygemsDotOrgTasks.new
18
+ Rake::GemGhostTask.new
20
19
 
21
20
  require 'rake/testtask'
22
21
  Rake::TestTask.new(:test) do |test|
@@ -24,16 +23,4 @@ Rake::TestTask.new(:test) do |test|
24
23
  test.pattern = 'test/**/test_*.rb'
25
24
  test.verbose = true
26
25
  end
27
-
28
- task :test => :check_dependencies
29
26
  task :default => :test
30
-
31
- require 'rake/rdoctask'
32
- Rake::RDocTask.new do |rdoc|
33
- version = File.exist?('VERSION') ? File.read('VERSION') : ''
34
-
35
- rdoc.rdoc_dir = 'rdoc'
36
- rdoc.title = "#{name} #{version}"
37
- rdoc.rdoc_files.include('README*')
38
- rdoc.rdoc_files.include('lib/**/*.rb')
39
- end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.0
1
+ 1.0.1
@@ -1,49 +1,51 @@
1
1
  # Generated by jeweler
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{image_size}
8
- s.version = "1.0.0"
8
+ s.version = "1.0.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
- s.authors = ["Keisuke Minami", "Boba Fat"]
12
- s.date = %q{2010-11-01}
13
- s.description = %q{measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF}
11
+ s.authors = ["Ivan Kuchin"]
12
+ s.date = %q{2010-12-15}
13
+ s.description = %q{Measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF}
14
14
  s.extra_rdoc_files = [
15
- "README.rdoc"
15
+ "LICENSE.txt",
16
+ "README.markdown"
16
17
  ]
17
18
  s.files = [
18
- ".gitignore",
19
- "README.rdoc",
20
- "Rakefile",
21
- "VERSION",
22
- "image_size.gemspec",
23
- "lib/image_size.rb",
24
- "test/2-4-7.png",
25
- "test/4_1_2.gif",
26
- "test/bmp.bmp",
27
- "test/cursor.xbm",
28
- "test/detect.swf",
29
- "test/pbm.pbm",
30
- "test/pcx.pcx",
31
- "test/pgm.pgm",
32
- "test/test.xpm",
33
- "test/test_helper.rb",
34
- "test/test_image_size.rb",
35
- "test/tiff.tiff",
36
- "test/tokyo_tower.jpg",
37
- "test/tower_e.psd"
19
+ ".tmignore",
20
+ "LICENSE.txt",
21
+ "README.markdown",
22
+ "Rakefile",
23
+ "VERSION",
24
+ "image_size.gemspec",
25
+ "lib/image_size.rb",
26
+ "test/2-4-7.png",
27
+ "test/4_1_2.gif",
28
+ "test/bmp.bmp",
29
+ "test/cursor.xbm",
30
+ "test/detect.swf",
31
+ "test/pbm.pbm",
32
+ "test/pcx.pcx",
33
+ "test/pgm.pgm",
34
+ "test/test.xpm",
35
+ "test/test_helper.rb",
36
+ "test/test_image_size.rb",
37
+ "test/tiff.tiff",
38
+ "test/tokyo_tower.jpg",
39
+ "test/tower_e.psd"
38
40
  ]
39
41
  s.homepage = %q{http://github.com/toy/image_size}
40
- s.rdoc_options = ["--charset=UTF-8"]
42
+ s.licenses = ["MIT"]
41
43
  s.require_paths = ["lib"]
42
44
  s.rubygems_version = %q{1.3.7}
43
- s.summary = %q{measure image size using pure Ruby}
45
+ s.summary = %q{Measure image size using pure Ruby}
44
46
  s.test_files = [
45
47
  "test/test_helper.rb",
46
- "test/test_image_size.rb"
48
+ "test/test_image_size.rb"
47
49
  ]
48
50
 
49
51
  if s.respond_to? :specification_version then
@@ -51,9 +53,15 @@ Gem::Specification.new do |s|
51
53
  s.specification_version = 3
52
54
 
53
55
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
56
+ s.add_development_dependency(%q<jeweler>, ["~> 1.5.1"])
57
+ s.add_development_dependency(%q<rake-gem-ghost>, [">= 0"])
54
58
  else
59
+ s.add_dependency(%q<jeweler>, ["~> 1.5.1"])
60
+ s.add_dependency(%q<rake-gem-ghost>, [">= 0"])
55
61
  end
56
62
  else
63
+ s.add_dependency(%q<jeweler>, ["~> 1.5.1"])
64
+ s.add_dependency(%q<rake-gem-ghost>, [">= 0"])
57
65
  end
58
66
  end
59
67
 
metadata CHANGED
@@ -1,36 +1,66 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: image_size
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 0
10
- version: 1.0.0
9
+ - 1
10
+ version: 1.0.1
11
11
  platform: ruby
12
12
  authors:
13
- - Keisuke Minami
14
- - Boba Fat
13
+ - Ivan Kuchin
15
14
  autorequire:
16
15
  bindir: bin
17
16
  cert_chain: []
18
17
 
19
- date: 2010-11-01 00:00:00 +03:00
18
+ date: 2010-12-15 00:00:00 +03:00
20
19
  default_executable:
21
- dependencies: []
22
-
23
- description: "measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF"
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
22
+ name: jeweler
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ hash: 1
30
+ segments:
31
+ - 1
32
+ - 5
33
+ - 1
34
+ version: 1.5.1
35
+ type: :development
36
+ version_requirements: *id001
37
+ - !ruby/object:Gem::Dependency
38
+ name: rake-gem-ghost
39
+ prerelease: false
40
+ requirement: &id002 !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ">="
44
+ - !ruby/object:Gem::Version
45
+ hash: 3
46
+ segments:
47
+ - 0
48
+ version: "0"
49
+ type: :development
50
+ version_requirements: *id002
51
+ description: "Measure following file dimensions: PCX, PSD, XPM, TIFF, XBM, PGM, PBM, PPM, BMP, JPEG, PNG, GIF, SWF"
24
52
  email:
25
53
  executables: []
26
54
 
27
55
  extensions: []
28
56
 
29
57
  extra_rdoc_files:
30
- - README.rdoc
58
+ - LICENSE.txt
59
+ - README.markdown
31
60
  files:
32
- - .gitignore
33
- - README.rdoc
61
+ - .tmignore
62
+ - LICENSE.txt
63
+ - README.markdown
34
64
  - Rakefile
35
65
  - VERSION
36
66
  - image_size.gemspec
@@ -51,11 +81,11 @@ files:
51
81
  - test/tower_e.psd
52
82
  has_rdoc: true
53
83
  homepage: http://github.com/toy/image_size
54
- licenses: []
55
-
84
+ licenses:
85
+ - MIT
56
86
  post_install_message:
57
- rdoc_options:
58
- - --charset=UTF-8
87
+ rdoc_options: []
88
+
59
89
  require_paths:
60
90
  - lib
61
91
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -82,7 +112,7 @@ rubyforge_project:
82
112
  rubygems_version: 1.3.7
83
113
  signing_key:
84
114
  specification_version: 3
85
- summary: measure image size using pure Ruby
115
+ summary: Measure image size using pure Ruby
86
116
  test_files:
87
117
  - test/test_helper.rb
88
118
  - test/test_image_size.rb
data/.gitignore DELETED
@@ -1,5 +0,0 @@
1
- .DS_Store
2
- pkg
3
- doc
4
- *.gem
5
- *.swp
@@ -1,31 +0,0 @@
1
- = image_size -- measure image size(GIF, PNG, JPEG ,,, etc)
2
-
3
- measure image size using pure Ruby
4
- ["PCX", "PSD", "XPM", "TIFF", "XBM", "PGM", "PBM", "PPM", "BMP", "JPEG", "PNG", "GIF", "SWF"]
5
-
6
- == Download
7
-
8
- The latest version of image_size can be found at
9
-
10
- * http://github.com/toy/image_size
11
-
12
- == Installation
13
-
14
- gem install image_size
15
-
16
- == Simple Example
17
-
18
- ruby "rubygems" # you use rubygems
19
- ruby "image_size"
20
- ruby "open-uri"
21
- open("http://www.rubycgi.org/image/ruby_gtk_book_title.jpg", "rb") do |fh|
22
- p ImageSize.new(fh.read).size
23
- end
24
-
25
- == Licence
26
-
27
- This code is free to use under the terms of the Ruby's licence.
28
-
29
- == Contact
30
-
31
- Comments are welcome. Send an email to "Keisuke Minami":mailto:keisuke@rccn.com