mirror of
https://github.com/rubyjs/therubyrhino
synced 2023-03-27 23:21:34 -04:00
bundler-ize therubyrhino
This commit is contained in:
parent
fad42f1795
commit
d08b275b77
8 changed files with 44 additions and 63 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -2,3 +2,4 @@
|
||||||
doc
|
doc
|
||||||
*.gem
|
*.gem
|
||||||
.rvmrc
|
.rvmrc
|
||||||
|
.bundle
|
||||||
|
|
3
Gemfile
Normal file
3
Gemfile
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
source :rubygems
|
||||||
|
|
||||||
|
gemspec
|
16
Gemfile.lock
Normal file
16
Gemfile.lock
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
PATH
|
||||||
|
remote: .
|
||||||
|
specs:
|
||||||
|
therubyrhino (1.72.7)
|
||||||
|
|
||||||
|
GEM
|
||||||
|
remote: http://rubygems.org/
|
||||||
|
specs:
|
||||||
|
rspec (1.3.0)
|
||||||
|
|
||||||
|
PLATFORMS
|
||||||
|
java
|
||||||
|
|
||||||
|
DEPENDENCIES
|
||||||
|
rspec
|
||||||
|
therubyrhino!
|
39
Rakefile
39
Rakefile
|
@ -1,36 +1,11 @@
|
||||||
require 'rubygems'
|
require 'bundler/setup'
|
||||||
require './lib/rhino'
|
Bundler::GemHelper.install_tasks
|
||||||
Gem::Specification.new do |gemspec|
|
|
||||||
$gemspec = gemspec
|
|
||||||
gemspec.name = gemspec.rubyforge_project = "therubyrhino"
|
|
||||||
gemspec.version = Rhino::VERSION
|
|
||||||
gemspec.summary = "Embed the Rhino JavaScript interpreter into JRuby"
|
|
||||||
gemspec.description = "Call javascript code and manipulate javascript objects from ruby. Call ruby code and manipulate ruby objects from javascript."
|
|
||||||
gemspec.email = "cowboyd@thefrontside.net"
|
|
||||||
gemspec.homepage = "http://github.com/cowboyd/therubyrhino"
|
|
||||||
gemspec.authors = ["Charles Lowell"]
|
|
||||||
gemspec.extra_rdoc_files = ["README.rdoc"]
|
|
||||||
gemspec.files = Rake::FileList.new("**/*").tap do |manifest|
|
|
||||||
manifest.exclude "*.gem"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
desc "Build gem"
|
|
||||||
task :gem => :gemspec do
|
|
||||||
Gem::Builder.new($gemspec).build
|
|
||||||
end
|
|
||||||
|
|
||||||
desc "build the gemspec"
|
|
||||||
task :gemspec => :clean do
|
|
||||||
File.open("#{$gemspec.name}.gemspec", "w") do |f|
|
|
||||||
f.write($gemspec.to_ruby)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
task :clean do
|
|
||||||
sh "rm -rf *.gem"
|
|
||||||
end
|
|
||||||
|
|
||||||
for file in Dir['tasks/*.rake']
|
for file in Dir['tasks/*.rake']
|
||||||
load file
|
load file
|
||||||
end
|
end
|
||||||
|
|
||||||
|
desc "remove all build artifacts"
|
||||||
|
task :clean do
|
||||||
|
sh "rm -rf pkg/"
|
||||||
|
end
|
||||||
|
|
|
@ -3,7 +3,7 @@ $:.unshift(File.dirname(__FILE__)) unless
|
||||||
|
|
||||||
|
|
||||||
module Rhino
|
module Rhino
|
||||||
VERSION = '1.72.7.pre'
|
VERSION = '1.72.7'
|
||||||
require 'rhino/java'
|
require 'rhino/java'
|
||||||
require 'rhino/object'
|
require 'rhino/object'
|
||||||
require 'rhino/context'
|
require 'rhino/context'
|
||||||
|
|
4
lib/rhino/version.rb
Normal file
4
lib/rhino/version.rb
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
|
||||||
|
module Rhino
|
||||||
|
VERSION = "1.72.7"
|
||||||
|
end
|
|
@ -1,21 +1,13 @@
|
||||||
begin
|
begin
|
||||||
require 'spec'
|
require 'spec'
|
||||||
rescue LoadError
|
|
||||||
require 'rubygems' unless ENV['NO_RUBYGEMS']
|
|
||||||
require 'spec'
|
|
||||||
end
|
|
||||||
begin
|
|
||||||
require 'spec/rake/spectask'
|
require 'spec/rake/spectask'
|
||||||
|
desc "Run the specs under spec/models"
|
||||||
|
Spec::Rake::SpecTask.new do |t|
|
||||||
|
t.spec_opts = ['--options', "spec/spec.opts"]
|
||||||
|
t.spec_files = FileList['spec/**/*_spec.rb']
|
||||||
|
end
|
||||||
rescue LoadError
|
rescue LoadError
|
||||||
puts <<-EOS
|
desc "bundle install to run rspecs"
|
||||||
To use rspec for testing you must install rspec gem:
|
task :spec
|
||||||
gem install rspec
|
|
||||||
EOS
|
|
||||||
exit(0)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "Run the specs under spec/models"
|
|
||||||
Spec::Rake::SpecTask.new do |t|
|
|
||||||
t.spec_opts = ['--options', "spec/spec.opts"]
|
|
||||||
t.spec_files = FileList['spec/**/*_spec.rb']
|
|
||||||
end
|
|
||||||
|
|
|
@ -1,29 +1,19 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
|
$:.push File.expand_path("../lib", __FILE__)
|
||||||
|
require "rhino/version"
|
||||||
|
|
||||||
Gem::Specification.new do |s|
|
Gem::Specification.new do |s|
|
||||||
s.name = %q{therubyrhino}
|
s.name = %q{therubyrhino}
|
||||||
s.version = "1.72.7.pre"
|
s.version = Rhino::VERSION
|
||||||
|
|
||||||
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
|
||||||
s.authors = ["Charles Lowell"]
|
s.authors = ["Charles Lowell"]
|
||||||
s.date = %q{2010-08-10}
|
|
||||||
s.description = %q{Call javascript code and manipulate javascript objects from ruby. Call ruby code and manipulate ruby objects from javascript.}
|
s.description = %q{Call javascript code and manipulate javascript objects from ruby. Call ruby code and manipulate ruby objects from javascript.}
|
||||||
s.email = %q{cowboyd@thefrontside.net}
|
s.email = %q{cowboyd@thefrontside.net}
|
||||||
s.extra_rdoc_files = ["README.rdoc"]
|
s.extra_rdoc_files = ["README.rdoc"]
|
||||||
s.files = ["History.txt", "lib", "Rakefile", "README.rdoc", "spec", "tasks", "therubyrhino.gemspec", "lib/rhino", "lib/rhino.rb", "lib/rhino/context.rb", "lib/rhino/java.rb", "lib/rhino/native_function.rb", "lib/rhino/native_object.rb", "lib/rhino/object.rb", "lib/rhino/rhino-1.7R2.jar", "lib/rhino/ruby_function.rb", "lib/rhino/ruby_object.rb", "lib/rhino/wormhole.rb", "spec/redjs", "spec/redjs_helper.rb", "spec/rhino", "spec/spec.opts", "spec/spec_helper.rb", "spec/redjs/jsapi_spec.rb", "spec/redjs/README.txt", "spec/rhino/context_spec.rb", "spec/rhino/wormhole_spec.rb", "tasks/jruby.rake", "tasks/rspec.rake"]
|
s.files = `git ls-files`.split("\n")
|
||||||
s.homepage = %q{http://github.com/cowboyd/therubyrhino}
|
s.homepage = %q{http://github.com/cowboyd/therubyrhino}
|
||||||
s.require_paths = ["lib"]
|
s.require_paths = ["lib"]
|
||||||
s.rubyforge_project = %q{therubyrhino}
|
s.rubyforge_project = %q{therubyrhino}
|
||||||
s.rubygems_version = %q{1.3.6}
|
|
||||||
s.summary = %q{Embed the Rhino JavaScript interpreter into JRuby}
|
s.summary = %q{Embed the Rhino JavaScript interpreter into JRuby}
|
||||||
|
|
||||||
if s.respond_to? :specification_version then
|
s.add_development_dependency "rspec"
|
||||||
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
|
||||||
s.specification_version = 3
|
|
||||||
|
|
||||||
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
|
||||||
else
|
|
||||||
end
|
|
||||||
else
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue