Skip to content

Commit

Permalink
New gemspec and version handling
Browse files Browse the repository at this point in the history
  • Loading branch information
imanel committed Nov 25, 2011
1 parent 76b3baf commit d20c184
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 88 deletions.
5 changes: 2 additions & 3 deletions .gitignore
@@ -1,3 +1,2 @@
doc pkg/
.yardoc Gemfile.lock
pkg
3 changes: 3 additions & 0 deletions Gemfile
@@ -0,0 +1,3 @@
source "http://rubygems.org"

gemspec
23 changes: 4 additions & 19 deletions Rakefile
@@ -1,26 +1,11 @@
$:.unshift(File.dirname(__FILE__)) require 'bundler'
require 'rake/testtask' Bundler::GemHelper.install_tasks
require 'lib/libwebsocket'


task :default => :test require 'rake/testtask'


Rake::TestTask.new do |t| Rake::TestTask.new do |t|
t.libs << "test" t.libs << "test"
t.test_files = FileList['test/**/test_*.rb'] t.test_files = FileList['test/**/test_*.rb']
end end


begin task :default => :test
require 'jeweler'
Jeweler::Tasks.new do |gemspec|
gemspec.name = "libwebsocket"
gemspec.version = LibWebSocket::VERSION
gemspec.summary = "Universal Ruby library to handle WebSocket protocol"
gemspec.description = "Universal Ruby library to handle WebSocket protocol"
gemspec.email = "bernard.potocki@imanel.org"
gemspec.homepage = "http://github.com/imanel/libwebsocket"
gemspec.authors = ["Bernard Potocki"]
gemspec.files.exclude ".gitignore"
end
rescue LoadError
puts "Jeweler not available. Install it with: gem install jeweler"
end
4 changes: 1 addition & 3 deletions lib/libwebsocket.rb
Expand Up @@ -3,8 +3,6 @@
# or clients to provide WebSocket support. # or clients to provide WebSocket support.
module LibWebSocket module LibWebSocket


VERSION = '0.1.1' # Version of LibWebSocket

autoload :Cookie, "#{File.dirname(__FILE__)}/libwebsocket/cookie" autoload :Cookie, "#{File.dirname(__FILE__)}/libwebsocket/cookie"
autoload :Frame, "#{File.dirname(__FILE__)}/libwebsocket/frame" autoload :Frame, "#{File.dirname(__FILE__)}/libwebsocket/frame"
autoload :OpeningHandshake, "#{File.dirname(__FILE__)}/libwebsocket/opening_handshake" autoload :OpeningHandshake, "#{File.dirname(__FILE__)}/libwebsocket/opening_handshake"
Expand All @@ -14,4 +12,4 @@ module LibWebSocket
autoload :Stateful, "#{File.dirname(__FILE__)}/libwebsocket/stateful" autoload :Stateful, "#{File.dirname(__FILE__)}/libwebsocket/stateful"
autoload :URL, "#{File.dirname(__FILE__)}/libwebsocket/url" autoload :URL, "#{File.dirname(__FILE__)}/libwebsocket/url"


end end
3 changes: 3 additions & 0 deletions lib/libwebsocket/version.rb
@@ -0,0 +1,3 @@
module LibWebSocket
VERSION = '0.1.1'
end
79 changes: 16 additions & 63 deletions libwebsocket.gemspec
@@ -1,69 +1,22 @@
# Generated by jeweler
# DO NOT EDIT THIS FILE DIRECTLY
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
# -*- encoding: utf-8 -*- # -*- encoding: utf-8 -*-
$:.push File.expand_path("../lib", __FILE__)
require "libwebsocket/version"


Gem::Specification.new do |s| Gem::Specification.new do |s|
s.name = "libwebsocket" s.name = "libwebsocket"
s.version = "0.1.1" s.version = LibWebSocket::VERSION
s.platform = Gem::Platform::RUBY
s.authors = ["Bernard Potocki"]
s.email = ["bernard.potocki@imanel.org"]
s.homepage = "http://github.com/imanel/libwebsocket"
s.summary = %q{Universal Ruby library to handle WebSocket protocol}
s.description = %q{Universal Ruby library to handle WebSocket protocol}


s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= s.add_dependency 'addressable'
s.authors = ["Bernard Potocki"] s.add_development_dependency 'rake'
s.date = "2011-10-24"
s.description = "Universal Ruby library to handle WebSocket protocol"
s.email = "bernard.potocki@imanel.org"
s.extra_rdoc_files = [
"README.md"
]
s.files = [
"CHANGELOG.md",
"README.md",
"Rakefile",
"examples/eventmachine_server.rb",
"examples/plain_client.rb",
"examples/thin_server.rb",
"lib/libwebsocket.rb",
"lib/libwebsocket/cookie.rb",
"lib/libwebsocket/cookie/request.rb",
"lib/libwebsocket/cookie/response.rb",
"lib/libwebsocket/frame.rb",
"lib/libwebsocket/message.rb",
"lib/libwebsocket/opening_handshake.rb",
"lib/libwebsocket/opening_handshake/client.rb",
"lib/libwebsocket/opening_handshake/server.rb",
"lib/libwebsocket/request.rb",
"lib/libwebsocket/response.rb",
"lib/libwebsocket/stateful.rb",
"lib/libwebsocket/url.rb",
"libwebsocket.gemspec",
"test/libwebsocket/cookie/request.rb",
"test/libwebsocket/cookie/response.rb",
"test/libwebsocket/opening_handshake/test_client.rb",
"test/libwebsocket/opening_handshake/test_server.rb",
"test/libwebsocket/test_cookie.rb",
"test/libwebsocket/test_frame.rb",
"test/libwebsocket/test_message.rb",
"test/libwebsocket/test_request_75.rb",
"test/libwebsocket/test_request_76.rb",
"test/libwebsocket/test_request_common.rb",
"test/libwebsocket/test_response_75.rb",
"test/libwebsocket/test_response_76.rb",
"test/libwebsocket/test_response_common.rb",
"test/libwebsocket/test_url.rb",
"test/test_helper.rb"
]
s.homepage = "http://github.com/imanel/libwebsocket"
s.require_paths = ["lib"]
s.rubygems_version = "1.8.11"
s.summary = "Universal Ruby library to handle WebSocket protocol"

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.files = `git ls-files`.split("\n")
else s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
end s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
else s.require_paths = ["lib"]
end
end end

0 comments on commit d20c184

Please sign in to comment.