gemsmith 2.0.0 → 2.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/{LICENSE.rdoc → LICENSE.md} +1 -1
  3. data/README.md +154 -0
  4. data/lib/gemsmith.rb +2 -2
  5. data/lib/gemsmith/cli.rb +32 -131
  6. data/lib/gemsmith/cli_helpers.rb +90 -0
  7. data/lib/gemsmith/cli_options.rb +94 -0
  8. data/lib/gemsmith/skeletons/base_skeleton.rb +35 -0
  9. data/lib/gemsmith/skeletons/cli_skeleton.rb +10 -0
  10. data/lib/gemsmith/skeletons/default_skeleton.rb +21 -0
  11. data/lib/gemsmith/skeletons/documentation_skeleton.rb +12 -0
  12. data/lib/gemsmith/skeletons/git_skeleton.rb +13 -0
  13. data/lib/gemsmith/skeletons/rails_skeleton.rb +51 -0
  14. data/lib/gemsmith/skeletons/rspec_skeleton.rb +17 -0
  15. data/lib/gemsmith/skeletons/travis_skeleton.rb +9 -0
  16. data/lib/gemsmith/templates/{gem.gemspec.tmp → %gem_name%/%gem_name%.gemspec.tt} +4 -3
  17. data/lib/gemsmith/templates/{gitignore.tmp → %gem_name%/.gitignore.tt} +2 -1
  18. data/lib/gemsmith/templates/{rspec.tmp → %gem_name%/.rspec.tt} +0 -0
  19. data/lib/gemsmith/templates/%gem_name%/.ruby-version.tt +1 -0
  20. data/lib/gemsmith/templates/{travis.yml.tmp → %gem_name%/.travis.yml.tt} +0 -2
  21. data/lib/gemsmith/templates/{CHANGELOG.rdoc.tmp → %gem_name%/CHANGELOG.md.tt} +1 -1
  22. data/lib/gemsmith/templates/{CONTRIBUTING.md.tmp → %gem_name%/CONTRIBUTING.md.tt} +0 -0
  23. data/lib/gemsmith/templates/{Gemfile.tmp → %gem_name%/Gemfile.tt} +0 -0
  24. data/lib/gemsmith/templates/{LICENSE.rdoc.tmp → %gem_name%/LICENSE.md.tt} +1 -1
  25. data/lib/gemsmith/templates/%gem_name%/README.md.tt +59 -0
  26. data/lib/gemsmith/templates/{Rakefile.tmp → %gem_name%/Rakefile.tt} +0 -0
  27. data/lib/gemsmith/templates/{bin/gem.tmp → %gem_name%/bin/%gem_name%.tt} +0 -0
  28. data/lib/gemsmith/templates/{gemfiles/rails-3.2.x.gemfile.tmp → %gem_name%/gemfiles/rails-3.2.x.gemfile.tt} +1 -1
  29. data/lib/gemsmith/templates/%gem_name%/lib/%gem_name%.rb.tt +33 -0
  30. data/lib/gemsmith/templates/{lib/gem/action_controller/class_methods.rb.tmp → %gem_name%/lib/%gem_name%/action_controller/class_methods.rb.tt} +2 -2
  31. data/lib/gemsmith/templates/{lib/gem/action_controller/instance_methods.rb.tmp → %gem_name%/lib/%gem_name%/action_controller/instance_methods.rb.tt} +0 -0
  32. data/lib/gemsmith/templates/{lib/gem/action_view/instance_methods.rb.tmp → %gem_name%/lib/%gem_name%/action_view/instance_methods.rb.tt} +0 -0
  33. data/lib/gemsmith/templates/{lib/gem/active_record/class_methods.rb.tmp → %gem_name%/lib/%gem_name%/active_record/class_methods.rb.tt} +2 -2
  34. data/lib/gemsmith/templates/{lib/gem/active_record/instance_methods.rb.tmp → %gem_name%/lib/%gem_name%/active_record/instance_methods.rb.tt} +0 -0
  35. data/lib/gemsmith/templates/{lib/gem/cli.rb.tmp → %gem_name%/lib/%gem_name%/cli.rb.tt} +1 -1
  36. data/lib/gemsmith/templates/{lib/gem/version.rb.tmp → %gem_name%/lib/%gem_name%/version.rb.tt} +0 -0
  37. data/lib/gemsmith/templates/{lib/generators/gem/install/USAGE.tmp → %gem_name%/lib/generators/%gem_name%/install/USAGE.tt} +0 -0
  38. data/lib/gemsmith/templates/{lib/generators/gem/install/install_generator.rb.tmp → %gem_name%/lib/generators/%gem_name%/install/install_generator.rb.tt} +0 -0
  39. data/lib/gemsmith/templates/{lib/generators/gem/upgrade/USAGE.tmp → %gem_name%/lib/generators/%gem_name%/upgrade/USAGE.tt} +0 -0
  40. data/lib/gemsmith/templates/{lib/generators/gem/upgrade/upgrade_generator.rb.tmp → %gem_name%/lib/generators/%gem_name%/upgrade/upgrade_generator.rb.tt} +0 -0
  41. data/lib/gemsmith/templates/{spec/gem_spec.rb.tmp → %gem_name%/spec/%gem_name%_spec.rb.tt} +0 -0
  42. data/lib/gemsmith/templates/{spec/spec_helper.rb.tmp → %gem_name%/spec/spec_helper.rb.tt} +2 -1
  43. data/lib/gemsmith/version.rb +1 -1
  44. metadata +61 -40
  45. data/CHANGELOG.rdoc +0 -134
  46. data/README.rdoc +0 -133
  47. data/lib/gemsmith/templates/README.rdoc.tmp +0 -59
  48. data/lib/gemsmith/templates/gemfiles/rails-3.0.x.gemfile.tmp +0 -5
  49. data/lib/gemsmith/templates/gemfiles/rails-3.1.x.gemfile.tmp +0 -5
  50. data/lib/gemsmith/templates/lib/gem.rb.tmp +0 -33
@@ -1,59 +0,0 @@
1
- = Overview
2
-
3
- {<img src="https://badge.fury.io/rb/<%= config[:gem_name] %>.png" alt="Gem Version" />}[http://badge.fury.io/rb/<%= config[:gem_name] %>]
4
- <%- if config[:code_climate] -%>
5
- {<img src="https://codeclimate.com/github/<%= config[:github_user] %>/<%= config[:gem_name] %>.png" alt="Code Climate GPA" />}[https://codeclimate.com/github/<%= config[:github_user] %>/<%= config[:gem_name] %>]
6
- <%- end -%>
7
- <%- if config[:travis] -%>
8
- {<img src="https://secure.travis-ci.org/<%= config[:github_user] %>/<%= config[:gem_name] %>.png" alt="Travis CI Status" />}[http://travis-ci.org/<%= config[:github_user] %>/<%= config[:gem_name] %>]
9
- <%- end -%>
10
-
11
- = Features
12
-
13
- = Requirements
14
-
15
- <%- if config[:rails] -%>
16
- 1. {Ruby on Rails}[http://rubyonrails.org].
17
- <%- end -%>
18
-
19
- = Setup
20
-
21
- Type the following from the command line to install:
22
-
23
- gem install <%= config[:gem_name] %>
24
-
25
- <%- if config[:rails] -%>
26
- Add the following to your Gemfile:
27
-
28
- gem "<%= config[:gem_name] %>"
29
- <%- end -%>
30
-
31
- = Usage
32
-
33
- <%- if config[:rspec] -%>
34
- = Tests
35
-
36
- To test, do the following:
37
-
38
- 1. cd to the gem root.
39
- 2. bundle install
40
- 3. bundle exec rspec spec
41
- <%- end -%>
42
-
43
- = Contributions
44
-
45
- Read CONTRIBUTING for details.
46
-
47
- = Credits
48
-
49
- Developed by {<%= config[:author_name] %>}[<%= config[:author_url] %>] at {<%= config[:company_name] %>}[<%= config[:company_url] %>]
50
-
51
- = License
52
-
53
- Copyright (c) <%= config[:year] %> {<%= config[:company_name] %>}[<%= config[:company_url] %>].
54
- Read the LICENSE for details.
55
-
56
- = History
57
-
58
- Read the CHANGELOG for details.
59
- Built with Gemsmith[https://github.com/bkuhlmann/gemsmith].
@@ -1,5 +0,0 @@
1
- source :rubygems
2
-
3
- gem "rails", "~> 3.0.0"
4
-
5
- gemspec path: "../"
@@ -1,5 +0,0 @@
1
- source :rubygems
2
-
3
- gem "rails", "~> 3.1.0"
4
-
5
- gemspec path: "../"
@@ -1,33 +0,0 @@
1
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "version.rb"
2
-
3
- <%- if config[:rails] -%>
4
- # Rails Enhancements
5
- if defined? Rails
6
- # Dependencies
7
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "active_record", "class_methods.rb"
8
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "active_record", "instance_methods.rb"
9
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "action_view", "instance_methods.rb"
10
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "action_controller", "class_methods.rb"
11
- require File.join File.dirname(__FILE__), "<%= config[:gem_name] %>", "action_controller", "instance_methods.rb"
12
-
13
- # Model
14
- if defined? ActiveRecord
15
- ActiveRecord::Base.send :include, <%= config[:gem_class] %>::ActiveRecord
16
- end
17
-
18
- # View
19
- if defined? ActionView
20
- ActionView::Base.send :include, <%= config[:gem_class] %>::ActionView
21
- end
22
-
23
- # Controller
24
- if defined? ActionController
25
- ActionController::Base.send :include, <%= config[:gem_class] %>::ActionController
26
- end
27
- end
28
- <%- else -%>
29
- # Namespace
30
- module <%= config[:gem_class] %>
31
- # TODO - Add code here.
32
- end
33
- <%- end -%>