diff --git a/CHANGELOG.rdoc b/CHANGELOG.rdoc index d1fb5a0..8491a29 100644 --- a/CHANGELOG.rdoc +++ b/CHANGELOG.rdoc @@ -2,6 +2,11 @@ * Grow Mustache up.(fix the TODOs and move the source to a mustache-rails like gem) * Write some documentation. (In both the github wiki and the source code) +== 0.13.0 +* optimize + * The Haml generators have moved to {the haml-rails gem}[http://github.com/indirect/haml-rails]. + * The jQuery generators have moved to {the jquery-rails gem}[http://github.com/indirect/jquery-rails]. + == 0.12.1 * optimize * changed jqueryui option to --ui diff --git a/README.rdoc b/README.rdoc index 1920ed6..f8836d6 100644 --- a/README.rdoc +++ b/README.rdoc @@ -14,6 +14,8 @@ and add the following to your project's Gemfile The Haml generators have moved to {the haml-rails gem}[http://github.com/indirect/haml-rails]. +The jQuery generators have moved to {the jquery-rails gem}[http://github.com/indirect/jquery-rails]. + To avoid overriding the rails built-in Erb template generators this project uses the namespace Erubis for *.erb templates config.generators do |g| diff --git a/Rakefile b/Rakefile index 6870f02..139f89a 100644 --- a/Rakefile +++ b/Rakefile @@ -9,7 +9,7 @@ begin gem.name = "rails3-generators" gem.summary = %Q{Rails 3 compatible generators} - gem.description = %Q{Rails 3 compatible generators for DataMapper, Haml, Factory-girl, Authlogic, Mongomapper, Mongoid, Shoulda, Formtastic and SimpleForm} + gem.description = %Q{Rails 3 compatible generators for DataMapper, Factory-girl, Authlogic, Mongomapper, Mongoid, Shoulda, Formtastic and SimpleForm} gem.email = "andre@arko.net" gem.homepage = "http://github.com/indirect/rails3-generators" gem.authors = ["Jose Valim", "Anuj Dutta", "Paul Berry", "Jeff Tucker", "Louis T.", "Jai-Gouk Kim", "Darcy Laycock", "Peter Haza", "Peter Gumeson", "Kristian Mandrup"] @@ -20,11 +20,8 @@ rails3-generators-#{version} Be sure to check out the wiki, http://wiki.github.com/indirect/rails3-generators/, for information about recent changes to this project. -note: ORM :datamapper has been renamed to :data_mapper -note: ORM :mongomapper has been renamed to :mongo_mapper - -note: if you use erb templates add the follow to your generators block to take full advantage of this gem. -g.template_engine :erubis +The Haml generators have moved to {the haml-rails gem}[http://github.com/indirect/haml-rails]. +The jQuery generators have moved to {the jquery-rails gem}[http://github.com/indirect/jquery-rails]. } diff --git a/VERSION b/VERSION index 34a8361..54d1a4f 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.12.1 +0.13.0 diff --git a/lib/generators/jquery.rb b/lib/generators/jquery.rb deleted file mode 100644 index 6b2e1b6..0000000 --- a/lib/generators/jquery.rb +++ /dev/null @@ -1,9 +0,0 @@ -module Jquery - module Generators - module TemplatePath - def source_root - @_jquery_source_root ||= File.expand_path(File.join(File.dirname(__FILE__), 'jquery', generator_name, 'templates')) - end - end - end -end \ No newline at end of file diff --git a/lib/generators/jquery/install/install_generator.rb b/lib/generators/jquery/install/install_generator.rb deleted file mode 100644 index 5f7005d..0000000 --- a/lib/generators/jquery/install/install_generator.rb +++ /dev/null @@ -1,32 +0,0 @@ -require 'generators/jquery' - -module Jquery - module Generators - class InstallGenerator < Rails::Generators::Base - extend TemplatePath - - class_option :ui, :type => :boolean, :default => false, :desc => "Indicates when to Include JQueryUI (minified version; source: Google Libraries API)" - - def download_jquery_files - %w(controls.js dragdrop.js effects.js prototype.js rails.js).each do |js| - remove_file "public/javascripts/#{js}" - end - - # Downloading latest jQuery.min - get "http://code.jquery.com/jquery-latest.min.js", "public/javascripts/jquery.js" - - # Downloading latest jQuery drivers - get "http://github.com/rails/jquery-ujs/raw/master/src/rails.js", "public/javascripts/rails.js" - end - - def download_jqueryui_files - # Downloading latest jQueryUI minified - get "http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/jquery-ui.min.js", "public/javascripts/jqueryui.js" if options.ui? - end - - def show_readme - readme "README" - end - end - end -end diff --git a/lib/generators/jquery/install/templates/README b/lib/generators/jquery/install/templates/README deleted file mode 100644 index a9d2d03..0000000 --- a/lib/generators/jquery/install/templates/README +++ /dev/null @@ -1,16 +0,0 @@ - -=============================================================================== - -Some manual steps you have to do - - 1. Uncomment or add the following to you application.rb file: - - config.action_view.javascript_expansions[:defaults] = %w(jquery rails) - - or if you used included jquery ui - - config.action_view.javascript_expansions[:defaults] = %w(jquery jqueryui rails) - - 2. Rerun the generator to update the javascript files - -=============================================================================== diff --git a/test/lib/generators/jquery/install_generator_test.rb b/test/lib/generators/jquery/install_generator_test.rb deleted file mode 100644 index 4776670..0000000 --- a/test/lib/generators/jquery/install_generator_test.rb +++ /dev/null @@ -1,23 +0,0 @@ -require 'test_helper' - -class Jquery::Generators::InstallGeneratorTest < Rails::Generators::TestCase - destination File.join(Rails.root) - tests Jquery::Generators::InstallGenerator - arguments [] - - setup :prepare_destination - - test 'jquery is installed' do - run_generator - - %w(jquery.js rails.js).each { |js| assert_file "public/javascripts/#{js}" } - %w(controls.js dragdrop.js effects.js prototype.js).each { |js| assert_no_file "public/javascripts/#{js}" } - end - - test 'jquery is installed with jqueyui' do - run_generator %w(--ui) - - %w(jquery.js jqueryui.js rails.js).each { |js| assert_file "public/javascripts/#{js}" } - %w(controls.js dragdrop.js effects.js prototype.js).each { |js| assert_no_file "public/javascripts/#{js}" } - end -end