forked from minimagick/minimagick
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
moving imagemagick to newgem structure
- Loading branch information
1 parent
e089344
commit 911f1b1
Showing
24 changed files
with
2,057 additions
and
302 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
== 0.2.0 2008-05-20 | ||
|
||
* Add << method to images. Let's you send raw commands to mogrify | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
History.txt | ||
License.txt | ||
Manifest.txt | ||
README.txt | ||
Rakefile | ||
config/hoe.rb | ||
config/requirements.rb | ||
lib/mini_magick.rb | ||
lib/mini_magick/version.rb | ||
log/debug.log | ||
script/destroy | ||
script/generate | ||
script/txt2html | ||
setup.rb | ||
tasks/deployment.rake | ||
tasks/environment.rake | ||
tasks/website.rake | ||
test/test_helper.rb | ||
test/test_mini_magick.rb | ||
website/index.html | ||
website/index.txt | ||
website/javascripts/rounded_corners_lite.inc.js | ||
website/stylesheets/screen.css | ||
website/template.rhtml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
README |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,68 +1,4 @@ | ||
require 'rake' | ||
require 'rake/testtask' | ||
require 'rake/rdoctask' | ||
require 'rake/packagetask' | ||
require 'rake/gempackagetask' | ||
|
||
$:.unshift(File.dirname(__FILE__) + "/lib") | ||
require 'mini_magick' | ||
|
||
PKG_NAME = 'mini_magick' | ||
PKG_VERSION = MiniMagick::VERSION | ||
PKG_FILE_NAME = "#{PKG_NAME}-#{PKG_VERSION}" | ||
|
||
desc 'Default: run unit tests.' | ||
task :default => :test | ||
|
||
desc "Clean generated files" | ||
task :clean do | ||
rm FileList['test/output/*.png'] | ||
rm_rf 'pkg' | ||
rm_rf 'doc' | ||
end | ||
|
||
desc 'Test the mini_magick plugin.' | ||
Rake::TestTask.new(:test) do |t| | ||
t.libs << 'lib' | ||
t.pattern = 'test/**/*_test.rb' | ||
t.verbose = true | ||
end | ||
|
||
desc 'Generate documentation for the mini_magick plugin.' | ||
Rake::RDocTask.new(:rdoc) do |rdoc| | ||
rdoc.rdoc_dir = 'rdoc' | ||
rdoc.title = 'MiniMagick' | ||
rdoc.options << '--line-numbers --inline-source' | ||
rdoc.rdoc_files.include('README') | ||
rdoc.rdoc_files.include('lib/**/*.rb') | ||
end | ||
|
||
|
||
# Create compressed packages | ||
spec = Gem::Specification.new do |s| | ||
s.platform = Gem::Platform::RUBY | ||
s.name = PKG_NAME | ||
s.summary = "Manipulate images with minimal use of memory." | ||
s.description = %q{Uses command-line ImageMagick tools to resize, rotate, and mogrify images.} | ||
s.version = PKG_VERSION | ||
|
||
s.author = "Corey Johnson" | ||
s.email = "probablycorey@gmail.com" | ||
s.rubyforge_project = PKG_NAME | ||
s.homepage = "http://gleepglop.com" | ||
|
||
s.has_rdoc = true | ||
s.requirements << 'none' | ||
s.require_path = 'lib' | ||
s.autorequire = 'mini_magick' | ||
|
||
s.files = [ "Rakefile", "README", "MIT-LICENSE" ] | ||
s.files = s.files + Dir.glob( "lib/**/*" ).delete_if { |item| item.include?( "\.svn" ) } | ||
s.files = s.files + Dir.glob( "test/**/*" ).delete_if { |item| item.include?( "\.svn" ) || item.include?("\.png") } | ||
end | ||
|
||
Rake::GemPackageTask.new(spec) do |p| | ||
p.gem_spec = spec | ||
p.need_tar = false | ||
p.need_zip = true | ||
end | ||
require 'config/requirements' | ||
require 'config/hoe' # setup Hoe + all gem configuration | ||
|
||
Dir['tasks/**/*.rake'].each { |rake| load rake } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
require 'mini_magick/version' | ||
|
||
AUTHOR = 'Corey Johnson' # can also be an array of Authors | ||
EMAIL = "probablycorey+minimagick@gmail.com" | ||
DESCRIPTION = "Ruby interface to ImageMagick." | ||
GEM_NAME = 'mini_magick' # what ppl will type to install your gem | ||
RUBYFORGE_PROJECT = 'mini_magick' # The unix name for your project | ||
HOMEPATH = "http://#{RUBYFORGE_PROJECT}.rubyforge.org" | ||
DOWNLOAD_PATH = "http://rubyforge.org/projects/#{RUBYFORGE_PROJECT}" | ||
|
||
@config_file = "~/.rubyforge/user-config.yml" | ||
@config = nil | ||
RUBYFORGE_USERNAME = "unknown" | ||
def rubyforge_username | ||
unless @config | ||
begin | ||
@config = YAML.load(File.read(File.expand_path(@config_file))) | ||
rescue | ||
puts <<-EOS | ||
ERROR: No rubyforge config file found: #{@config_file} | ||
Run 'rubyforge setup' to prepare your env for access to Rubyforge | ||
- See http://newgem.rubyforge.org/rubyforge.html for more details | ||
EOS | ||
exit | ||
end | ||
end | ||
RUBYFORGE_USERNAME.replace @config["username"] | ||
end | ||
|
||
|
||
REV = nil | ||
# UNCOMMENT IF REQUIRED: | ||
# REV = `svn info`.each {|line| if line =~ /^Revision:/ then k,v = line.split(': '); break v.chomp; else next; end} rescue nil | ||
VERS = MiniMagick::VERSION::STRING + (REV ? ".#{REV}" : "") | ||
RDOC_OPTS = ['--quiet', '--title', 'mini_magick documentation', | ||
"--opname", "index.html", | ||
"--line-numbers", | ||
"--main", "README", | ||
"--inline-source"] | ||
|
||
class Hoe | ||
def extra_deps | ||
@extra_deps.reject! { |x| Array(x).first == 'hoe' } | ||
@extra_deps | ||
end | ||
end | ||
|
||
# Generate all the Rake tasks | ||
# Run 'rake -T' to see list of generated tasks (from gem root directory) | ||
hoe = Hoe.new(GEM_NAME, VERS) do |p| | ||
p.developer(AUTHOR, EMAIL) | ||
p.description = DESCRIPTION | ||
p.summary = DESCRIPTION | ||
p.url = HOMEPATH | ||
p.rubyforge_name = RUBYFORGE_PROJECT if RUBYFORGE_PROJECT | ||
p.test_globs = ["test/**/test_*.rb"] | ||
p.clean_globs |= ['**/.*.sw?', '*.gem', '.config', '**/.DS_Store'] #An array of file patterns to delete on clean. | ||
|
||
# == Optional | ||
p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n") | ||
#p.extra_deps = [] # An array of rubygem dependencies [name, version], e.g. [ ['active_support', '>= 1.3.1'] ] | ||
|
||
#p.spec_extras = {} # A hash of extra values to set in the gemspec. | ||
|
||
end | ||
|
||
CHANGES = hoe.paragraphs_of('History.txt', 0..1).join("\\n\\n") | ||
PATH = (RUBYFORGE_PROJECT == GEM_NAME) ? RUBYFORGE_PROJECT : "#{RUBYFORGE_PROJECT}/#{GEM_NAME}" | ||
hoe.remote_rdoc_dir = File.join(PATH.gsub(/^#{RUBYFORGE_PROJECT}\/?/,''), 'rdoc') | ||
hoe.rsync_args = '-av --delete --ignore-errors' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
require 'fileutils' | ||
include FileUtils | ||
|
||
require 'rubygems' | ||
%w[rake hoe newgem rubigen].each do |req_gem| | ||
begin | ||
require req_gem | ||
rescue LoadError | ||
puts "This Rakefile requires the '#{req_gem}' RubyGem." | ||
puts "Installation: gem install #{req_gem} -y" | ||
exit | ||
end | ||
end | ||
|
||
$:.unshift(File.join(File.dirname(__FILE__), %w[.. lib])) | ||
|
||
require 'mini_magick' |
Oops, something went wrong.