Skip to content
Browse files

Migrate to gemspec+Bunlder.

  • Loading branch information...
1 parent 4d647db commit bf407b5807176950cd3e772318343aea90cafea8 @jcoglan committed Mar 24, 2012
Showing with 36 additions and 57 deletions.
  1. +1 −3 .gitignore
  2. +2 −0 Gemfile
  3. +0 −33 Manifest.txt
  4. +0 −13 Rakefile
  5. +4 −3 bin/jake
  6. +22 −0 jake.gemspec
  7. +7 −5 test/test_jake.rb
View
4 .gitignore
@@ -1,4 +1,2 @@
-README.txt
-pkg
-doc
+Gemfile.lock
test/output
View
2 Gemfile
@@ -0,0 +1,2 @@
+source "http://rubygems.org"
+gemspec
View
33 Manifest.txt
@@ -1,33 +0,0 @@
-History.txt
-Manifest.txt
-README.txt
-Rakefile
-bin/jake
-lib/jake.rb
-lib/jake/helper.rb
-lib/jake/build.rb
-lib/jake/buildable.rb
-lib/jake/package.rb
-lib/jake/bundle.rb
-test/test_jake.rb
-test/jake.yml
-test/Jakefile
-test/packages.erb
-test/expected/combo/box.js
-test/expected/combo/box-min.js
-test/expected/sub/dir/foo.js
-test/expected/sub/dir/foo-min.js
-test/expected/sub/path/bar.js
-test/expected/sub/path/bar-min.js
-test/expected/basic.js
-test/expected/basic-min.js
-test/expected/ext.js
-test/expected/ext-min.js
-test/expected/LISTING
-test/expected/README
-test/src/foo/bar.js
-test/src/foo/foo.js
-test/src/basic.js
-test/src/basic-ext.js
-test/src/head.js
-test/src/head2.js
View
13 Rakefile
@@ -1,13 +0,0 @@
-# -*- ruby -*-
-
-require 'rubygems'
-require 'hoe'
-require './lib/jake.rb'
-
-Hoe.spec('jake') do |p|
- # p.rubyforge_name = 'jakex' # if different than lowercase project name
- p.developer('James Coglan', 'jcoglan@googlemail.com')
- p.extra_deps = %w(eventful packr oyster)
-end
-
-# vim: syntax=Ruby
View
7 bin/jake 100644 → 100755
@@ -1,7 +1,8 @@
-#!/usr/bin/ruby
+#!/usr/bin/env ruby
+
require 'rubygems'
require 'oyster'
-require File.dirname(__FILE__) + '/../lib/jake'
+require File.expand_path('../../lib/jake', __FILE__)
spec = Oyster.spec do
name 'jake -- automated build tool for JavaScript projects'
@@ -20,7 +21,7 @@ spec = Oyster.spec do
flag :force, :default => false,
:desc => 'Force a rebuild even if files are up-to-date'
- author 'James Coglan <jcoglan@googlemail.com>'
+ author 'James Coglan <jcoglan@gmail.com>'
end
begin; opts = spec.parse
View
22 jake.gemspec
@@ -0,0 +1,22 @@
+Gem::Specification.new do |s|
+ s.name = "jake"
+ s.version = "1.0.1"
+ s.summary = "Build tools for JavaScript projects"
+ s.author = "James Coglan"
+ s.email = "jcoglan@gmail.com"
+ s.homepage = "http://github.com/jcoglan/jake"
+
+ s.extra_rdoc_files = %w[README.rdoc]
+ s.rdoc_options = %w[--main README.rdoc]
+
+ s.files = %w[History.txt README.rdoc] + Dir.glob("{bin,lib}/**/*")
+
+ s.executables = Dir.glob("bin/**").map { |f| File.basename(f) }
+ s.require_paths = ["lib"]
+
+ s.add_dependency "eventful", ">= 1.0.0"
+ s.add_dependency "packr", ">= 3.1.0"
+ s.add_dependency "oyster", ">= 0.9.5"
+
+ s.add_development_dependency "test-unit"
+end
View
12 test/test_jake.rb
@@ -1,10 +1,12 @@
-require "test/unit"
-require "jake"
-require "fileutils"
-require "find"
+require 'rubygems'
+require 'bundler/setup'
+require 'test/unit'
+require File.expand_path('../../lib/jake', __FILE__)
+require 'fileutils'
+require 'find'
class TestJake < Test::Unit::TestCase
- DIR = File.dirname(__FILE__)
+ DIR = File.expand_path('..', __FILE__)
def setup
FileUtils.rm_rf(File.join(DIR, 'output'))

0 comments on commit bf407b5

Please sign in to comment.
Something went wrong with that request. Please try again.