clove 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 599d15df4ca241298a1d38a59c483c1a566808b7
4
+ data.tar.gz: b8de61ffed82e706bf0c02b62c13b945d9152815
5
+ SHA512:
6
+ metadata.gz: 368c738ce2d6d956617f8039ee5805a156117d747bdd22bda12b90d0cb8991ff5950fc3ff292f30c5c65f514fd0163eb4aaae66128fb42b098c429c348874496
7
+ data.tar.gz: 2d61e913d5dab6d3190422401aef3f5b9c3cb8449e052f0a404efe3a718984f2bcceb10a77cd7f983bf5a779eedd8cceda0ee8867ca8396577f3597e7dbc313a
@@ -0,0 +1,22 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
18
+ *.bundle
19
+ *.so
20
+ *.o
21
+ *.a
22
+ mkmf.log
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in clove.gemspec
4
+ gemspec
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 Clinton Dreisbach
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,31 @@
1
+ # Clove
2
+
3
+ Creates very simple Ruby projects not intended to be gems, but just
4
+ to be well-designed programs.
5
+
6
+ ## Installation
7
+
8
+ Add this line to your application's Gemfile:
9
+
10
+ gem 'clove'
11
+
12
+ And then execute:
13
+
14
+ $ bundle
15
+
16
+ Or install it yourself as:
17
+
18
+ $ gem install clove
19
+
20
+ ## Usage
21
+
22
+ Use `clove <project_name>` on the command line to create a new simple
23
+ Ruby project.
24
+
25
+ ## Contributing
26
+
27
+ 1. Fork it ( https://github.com/[my-github-username]/clove/fork )
28
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
29
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
30
+ 4. Push to the branch (`git push origin my-new-feature`)
31
+ 5. Create a new Pull Request
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ lib = File.expand_path(File.dirname(__FILE__) + '/../lib')
4
+ $LOAD_PATH.unshift(lib) if File.directory?(lib) && !$LOAD_PATH.include?(lib)
5
+
6
+ require "clove"
7
+
8
+ Clove::Generator.start
@@ -0,0 +1,27 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'clove/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "clove"
8
+ spec.version = Clove::VERSION
9
+ spec.authors = ["Clinton Dreisbach"]
10
+ spec.email = ["clinton@theironyard.com"]
11
+ spec.summary = %q{Creates very simple Ruby projects.}
12
+ spec.description = %q{Creates very simple Ruby projects not intended to be gems, but just
13
+ to be well-designed programs.}
14
+ spec.homepage = ""
15
+ spec.license = "MIT"
16
+
17
+ spec.files = `git ls-files -z`.split("\x0")
18
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
19
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
20
+ spec.require_paths = ["lib"]
21
+
22
+ spec.add_dependency "activesupport", "~> 4.0.5"
23
+ spec.add_dependency "thor", "~> 0.19.1"
24
+
25
+ spec.add_development_dependency "bundler", "~> 1.6"
26
+ spec.add_development_dependency "rake"
27
+ end
@@ -0,0 +1,40 @@
1
+ require "clove/version"
2
+ require "thor"
3
+ require "active_support/core_ext/string"
4
+
5
+ module Clove
6
+ class Generator < Thor::Group
7
+ desc "Creates a simple project directory for a new Ruby program."
8
+
9
+ include Thor::Actions
10
+
11
+ argument :name
12
+
13
+ def self.source_root
14
+ File.dirname(__FILE__)
15
+ end
16
+
17
+ def create_rakefile
18
+ template "templates/Rakefile.tt", "#{name}/Rakefile"
19
+ end
20
+
21
+ def create_gemfile
22
+ template "templates/Gemfile.tt", "#{name}/Gemfile"
23
+ end
24
+
25
+ def create_lib_file
26
+ template "templates/lib.tt", "#{name}/lib/#{name}.rb"
27
+ end
28
+
29
+ def create_test_file
30
+ template "templates/test.tt", "#{name}/test/#{name}_test.rb"
31
+ end
32
+
33
+ def create_bin_file
34
+ if yes? "Create an executable file?"
35
+ template "templates/bin.tt", "#{name}/bin/#{name}"
36
+ chmod "#{name}/bin/#{name}", 0755
37
+ end
38
+ end
39
+ end
40
+ end
@@ -0,0 +1,3 @@
1
+ module Clove
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,7 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Add gems here like the following:
4
+ # gem 'nokogiri'
5
+ # gem 'rack', '~> 1.1'
6
+ #
7
+ # See bundler.io for more info.
@@ -0,0 +1,11 @@
1
+ # <%= name.camelize %>
2
+
3
+ TODO: Describe the purpose of this program.
4
+
5
+ ## Usage
6
+
7
+ TODO: Describe how to start this program.
8
+
9
+ To run the tests, run `rake` on the command line. `rake` is a Ruby program that
10
+ executes tasks from a file called a `Rakefile`. It is often used by Ruby
11
+ libraries to run tests and other tasks.
@@ -0,0 +1,7 @@
1
+ require 'rake/testtask'
2
+
3
+ Rake::TestTask.new do |t|
4
+ t.pattern = "test/*_test.rb"
5
+ end
6
+
7
+ task :default => :test
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ lib = File.expand_path(File.dirname(__FILE__) + '/../lib')
4
+ $LOAD_PATH.unshift(lib) if File.directory?(lib) && !$LOAD_PATH.include?(lib)
5
+
6
+ raise RuntimeError.new "You need to add some functionality here before you can use this."
@@ -0,0 +1,2 @@
1
+ class <%= name.camelize %>
2
+ end
@@ -0,0 +1,8 @@
1
+ require "minitest/autorun"
2
+ require "<%= name %>"
3
+
4
+ class <%= name.camelize %>Test < MiniTest::Unit::TestCase
5
+ def test_first_test
6
+ assert false, "Please add a test here"
7
+ end
8
+ end
metadata ADDED
@@ -0,0 +1,119 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: clove
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Clinton Dreisbach
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-06-10 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activesupport
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 4.0.5
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 4.0.5
27
+ - !ruby/object:Gem::Dependency
28
+ name: thor
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: 0.19.1
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: 0.19.1
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '1.6'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '1.6'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ description: |-
70
+ Creates very simple Ruby projects not intended to be gems, but just
71
+ to be well-designed programs.
72
+ email:
73
+ - clinton@theironyard.com
74
+ executables:
75
+ - clove
76
+ extensions: []
77
+ extra_rdoc_files: []
78
+ files:
79
+ - ".gitignore"
80
+ - Gemfile
81
+ - LICENSE.txt
82
+ - README.md
83
+ - Rakefile
84
+ - bin/clove
85
+ - clove.gemspec
86
+ - lib/clove.rb
87
+ - lib/clove/version.rb
88
+ - lib/templates/Gemfile.tt
89
+ - lib/templates/README.tt
90
+ - lib/templates/Rakefile.tt
91
+ - lib/templates/bin.tt
92
+ - lib/templates/lib.tt
93
+ - lib/templates/test.tt
94
+ homepage: ''
95
+ licenses:
96
+ - MIT
97
+ metadata: {}
98
+ post_install_message:
99
+ rdoc_options: []
100
+ require_paths:
101
+ - lib
102
+ required_ruby_version: !ruby/object:Gem::Requirement
103
+ requirements:
104
+ - - ">="
105
+ - !ruby/object:Gem::Version
106
+ version: '0'
107
+ required_rubygems_version: !ruby/object:Gem::Requirement
108
+ requirements:
109
+ - - ">="
110
+ - !ruby/object:Gem::Version
111
+ version: '0'
112
+ requirements: []
113
+ rubyforge_project:
114
+ rubygems_version: 2.2.2
115
+ signing_key:
116
+ specification_version: 4
117
+ summary: Creates very simple Ruby projects.
118
+ test_files: []
119
+ has_rdoc: