diff --git a/Gemfile b/Gemfile index 786b0e0..8643c77 100644 --- a/Gemfile +++ b/Gemfile @@ -1,4 +1,7 @@ source :rubygems +gemspec -gem 'newrelic_rpm' -gem 'eventmachine' +group :development do + gem "bundler", "~> 1.0.0" + gem "jeweler", "~> 1.6.2" +end diff --git a/Gemfile.lock b/Gemfile.lock index 8de9452..f123e46 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,13 +1,25 @@ +PATH + remote: . + specs: + varnish-rb (0.0.0) + eventmachine + GEM remote: http://rubygems.org/ specs: eventmachine (0.12.10-java) - newrelic_rpm (3.1.0) + git (1.2.5) + jeweler (1.6.2) + bundler (~> 1.0) + git (>= 1.2.5) + rake + rake (0.9.2) PLATFORMS java ruby DEPENDENCIES - eventmachine - newrelic_rpm + bundler (~> 1.0.0) + jeweler (~> 1.6.2) + varnish-rb! diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 0000000..e883cb9 --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,20 @@ +Copyright (c) 2011 ZephirWorks + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.rdoc b/README.rdoc new file mode 100644 index 0000000..727ae45 --- /dev/null +++ b/README.rdoc @@ -0,0 +1,19 @@ += varnish-rb + +Description goes here. + +== Contributing to varnish-rb + +* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet +* Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it +* Fork the project +* Start a feature/bugfix branch +* Commit and push until you are happy with your contribution +* Make sure to add tests for it. This is important so I don't break it in a future version unintentionally. +* Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it. + +== Copyright + +Copyright (c) 2011 Andrea Campi. See LICENSE.txt for +further details. + diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..23c9933 --- /dev/null +++ b/Rakefile @@ -0,0 +1,52 @@ +# encoding: utf-8 + +require 'rubygems' +require 'bundler' +begin + Bundler.setup(:default, :development) +rescue Bundler::BundlerError => e + $stderr.puts e.message + $stderr.puts "Run `bundle install` to install missing gems" + exit e.status_code +end +require 'rake' + +require 'jeweler' +Jeweler::Tasks.new do |gem| + # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options + gem.name = "varnish-rb" + gem.homepage = "http://github.com/andreacampi/varnish-rb" + gem.license = "MIT" + gem.summary = %Q{TODO: one-line summary of your gem} + gem.description = %Q{TODO: longer description of your gem} + gem.email = "andrea.campi@zephirworks.com" + gem.authors = ["Andrea Campi"] +end +Jeweler::RubygemsDotOrgTasks.new + +# require 'rake/testtask' +# Rake::TestTask.new(:test) do |test| +# test.libs << 'lib' << 'test' +# test.pattern = 'test/**/test_*.rb' +# test.verbose = true +# end +# +# require 'rcov/rcovtask' +# Rcov::RcovTask.new do |test| +# test.libs << 'test' +# test.pattern = 'test/**/test_*.rb' +# test.verbose = true +# test.rcov_opts << '--exclude "gems/*"' +# end +# +# task :default => :test + +require 'rake/rdoctask' +Rake::RDocTask.new do |rdoc| + version = File.exist?('VERSION') ? File.read('VERSION') : "" + + rdoc.rdoc_dir = 'rdoc' + rdoc.title = "varnish-rb #{version}" + rdoc.rdoc_files.include('README*') + rdoc.rdoc_files.include('lib/**/*.rb') +end diff --git a/varnish-rb.gemspec b/varnish-rb.gemspec new file mode 100644 index 0000000..48e21a1 --- /dev/null +++ b/varnish-rb.gemspec @@ -0,0 +1,60 @@ +# Generated by jeweler +# DO NOT EDIT THIS FILE DIRECTLY +# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec' +# -*- encoding: utf-8 -*- + +Gem::Specification.new do |s| + s.name = %q{varnish-rb} + s.version = "0.0.0" + + s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= + s.authors = ["Andrea Campi"] + s.date = %q{2011-06-24} + s.description = %q{TODO: longer description of your gem} + s.email = %q{andrea.campi@zephirworks.com} + s.extra_rdoc_files = [ + "LICENSE.txt", + "README.rdoc" + ] + s.files = [ + ".rvmrc", + "Gemfile", + "Gemfile.lock", + "VERSION", + "lib/em/varnish/log_connection.rb", + "lib/em/varnish/log_stream.rb", + "lib/em/varnish/request_stream.rb", + "lib/varnish.rb", + "lib/varnish/connection.rb", + "lib/varnish/log_entry.rb", + "lib/varnish/vsl.rb", + "lib/varnish/vsm.rb", + "log.rb", + "log_tailer.rb", + "tailer.rb" + ] + s.homepage = %q{http://github.com/andreacampi/varnish-rb} + s.licenses = ["MIT"] + s.require_paths = ["lib"] + s.rubygems_version = %q{1.5.1} + s.summary = %q{TODO: one-line summary of your gem} + + if s.respond_to? :specification_version then + s.specification_version = 3 + + if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then + s.add_development_dependency(%q, ["~> 1.0.0"]) + s.add_development_dependency(%q, ["~> 1.6.2"]) + s.add_runtime_dependency(%q, [">= 0"]) + else + s.add_dependency(%q, ["~> 1.0.0"]) + s.add_dependency(%q, ["~> 1.6.2"]) + s.add_dependency(%q, [">= 0"]) + end + else + s.add_dependency(%q, ["~> 1.0.0"]) + s.add_dependency(%q, ["~> 1.6.2"]) + s.add_dependency(%q, [">= 0"]) + end +end +