bundler-norelease 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +22 -0
- data/.rspec +2 -0
- data/.travis.yml +4 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +22 -0
- data/README.md +29 -0
- data/Rakefile +7 -0
- data/bin/bundler-norelease +10 -0
- data/bundler-norelease.gemspec +24 -0
- data/lib/bundler/norelease/cli.rb +57 -0
- data/lib/bundler/norelease/version.rb +5 -0
- data/lib/bundler/norelease.rb +3 -0
- data/lib/bundler/templates/newgem/Rakefile.tt +28 -0
- data/spec/bundler/norelease_spec.rb +11 -0
- data/spec/spec_helper.rb +2 -0
- metadata +105 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 2688f317d7a9a3a31a2029cfdca29bf096d3c530
|
4
|
+
data.tar.gz: e3f701cb51c153c69e7fb6eccf84a82ac84ce1ad
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 362d768afd77b1c5b91daf5d21b9c27531a61ff0949e50afd7f7cf5c1c4574a0823445a395cab0c79d374d00184b2e6470614d03b4bb9e87d31b858cdfe57f5f
|
7
|
+
data.tar.gz: 08ba43f4f58405f90635cc61cbe7ad96c78af70c7db9a156946e94d7a43b58873d03f3f8b66c056e7a90d011f9cad7fec5cdf04b692c8fbb41b23aeba0e973c9
|
data/.gitignore
ADDED
@@ -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/.rspec
ADDED
data/.travis.yml
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2014 SpringMT
|
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.
|
data/README.md
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
# Bundler::Norelease
|
2
|
+
|
3
|
+
TODO: Write a gem description
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
Add this line to your application's Gemfile:
|
8
|
+
|
9
|
+
gem 'bundler-norelease'
|
10
|
+
|
11
|
+
And then execute:
|
12
|
+
|
13
|
+
$ bundle
|
14
|
+
|
15
|
+
Or install it yourself as:
|
16
|
+
|
17
|
+
$ gem install bundler-norelease
|
18
|
+
|
19
|
+
## Usage
|
20
|
+
|
21
|
+
TODO: Write usage instructions here
|
22
|
+
|
23
|
+
## Contributing
|
24
|
+
|
25
|
+
1. Fork it ( https://github.com/[my-github-username]/bundler-norelease/fork )
|
26
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
27
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
28
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
29
|
+
5. Create a new Pull Request
|
data/Rakefile
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require 'rubygems'
|
4
|
+
|
5
|
+
lib_dir = File.expand_path(File.join(File.dirname(__FILE__),'..','lib'))
|
6
|
+
$LOAD_PATH << lib_dir unless $LOAD_PATH.include?(lib_dir)
|
7
|
+
|
8
|
+
require 'bundler/norelease'
|
9
|
+
|
10
|
+
Bundler::Norelease::CLI.start(ARGV, debug: true)
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'bundler/norelease/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "bundler-norelease"
|
8
|
+
spec.version = Bundler::Norelease::VERSION
|
9
|
+
spec.authors = ["SpringMT"]
|
10
|
+
spec.email = ["today.is.sky.blue.sky@gmail.com"]
|
11
|
+
spec.summary = %q{gem generator for no release}
|
12
|
+
spec.description = %q{gem generator for no release}
|
13
|
+
spec.homepage = "https://github.com/SpringMT/bundler-norelease"
|
14
|
+
spec.license = "MIT"
|
15
|
+
|
16
|
+
spec.files = `git ls-files -z`.split("\x0")
|
17
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
+
spec.require_paths = ["lib"]
|
20
|
+
|
21
|
+
spec.add_development_dependency "bundler", "~> 1.6"
|
22
|
+
spec.add_development_dependency "rake"
|
23
|
+
spec.add_development_dependency "rspec"
|
24
|
+
end
|
@@ -0,0 +1,57 @@
|
|
1
|
+
require 'bundler/cli'
|
2
|
+
require 'bundler/cli/gem'
|
3
|
+
require 'bundler/vendored_thor'
|
4
|
+
require 'thor/actions'
|
5
|
+
|
6
|
+
module Bundler
|
7
|
+
class Norelease::CLI < ::Thor
|
8
|
+
include Thor::Actions
|
9
|
+
|
10
|
+
def self.start(*)
|
11
|
+
super
|
12
|
+
end
|
13
|
+
|
14
|
+
default_task :gem
|
15
|
+
desc "gem GEM [OPTIONS]", "Creates a skeleton for creating a rubygem"
|
16
|
+
method_option :bin, :type => :boolean, :default => false, :aliases => '-b', :banner => "Generate a binary for your library."
|
17
|
+
method_option :edit, :type => :string, :aliases => "-e",
|
18
|
+
:lazy_default => [ENV['BUNDLER_EDITOR'], ENV['VISUAL'], ENV['EDITOR']].find{|e| !e.nil? && !e.empty? },
|
19
|
+
:required => false, :banner => "/path/to/your/editor",
|
20
|
+
:desc => "Open generated gemspec in the specified editor (defaults to $EDITOR or $BUNDLER_EDITOR)"
|
21
|
+
method_option :ext, :type => :boolean, :default => false, :banner => "Generate the boilerplate for C extension code"
|
22
|
+
method_option :test, :type => :string, :lazy_default => 'rspec', :aliases => '-t', :banner =>
|
23
|
+
"Generate a test directory for your library: 'rspec' is the default, but 'minitest' is also supported."
|
24
|
+
def gem(name)
|
25
|
+
underscored_name = name.tr('-', '_')
|
26
|
+
namespaced_path = name.tr('-', '/')
|
27
|
+
constant_name = name.split('_').map{|p| p[0..0].upcase + p[1..-1] }.join
|
28
|
+
constant_name = constant_name.split('-').map{|q| q[0..0].upcase + q[1..-1] }.join('::') if constant_name =~ /-/
|
29
|
+
constant_array = constant_name.split('::')
|
30
|
+
|
31
|
+
opts = {
|
32
|
+
:name => name,
|
33
|
+
:underscored_name => underscored_name,
|
34
|
+
:namespaced_path => namespaced_path,
|
35
|
+
:makefile_path => "#{underscored_name}/#{underscored_name}",
|
36
|
+
:constant_name => constant_name,
|
37
|
+
:constant_array => constant_array,
|
38
|
+
:test => options[:test],
|
39
|
+
:ext => options[:ext]
|
40
|
+
}
|
41
|
+
|
42
|
+
Bundler::Norelease::CLI.source_root(File.join(Gem::Specification.find_by_path('bundler').full_gem_path, 'lib/bundler/templates'))
|
43
|
+
bundler = ::Bundler::CLI::Gem.new(options, name, self)
|
44
|
+
bundler.run
|
45
|
+
Bundler::Norelease::CLI.source_root(File.join(File.expand_path('../', __dir__), 'templates'))
|
46
|
+
opts[:force] = true
|
47
|
+
template("newgem/Rakefile.tt", File.join(bundler.target, "Rakefile"), opts)
|
48
|
+
end
|
49
|
+
|
50
|
+
private
|
51
|
+
|
52
|
+
def source_paths
|
53
|
+
self.class.source_paths_for_search
|
54
|
+
end
|
55
|
+
|
56
|
+
end
|
57
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
2
|
+
Rake::Task[:release].clear
|
3
|
+
|
4
|
+
<% if config[:test] == 'minitest' -%>
|
5
|
+
require "rake/testtask"
|
6
|
+
|
7
|
+
Rake::TestTask.new(:test) do |t|
|
8
|
+
t.libs << "test"
|
9
|
+
end
|
10
|
+
|
11
|
+
task :default => :test
|
12
|
+
<% elsif config[:test] == 'rspec' -%>
|
13
|
+
require "rspec/core/rake_task"
|
14
|
+
|
15
|
+
RSpec::Core::RakeTask.new(:spec)
|
16
|
+
|
17
|
+
task :default => :spec
|
18
|
+
<% end -%>
|
19
|
+
|
20
|
+
<% if config[:ext] -%>
|
21
|
+
require "rake/extensiontask"
|
22
|
+
|
23
|
+
task :build => :compile
|
24
|
+
|
25
|
+
Rake::ExtensionTask.new("<%=config[:underscored_name]%>") do |ext|
|
26
|
+
ext.lib_dir = "lib/<%=config[:namespaced_path]%>"
|
27
|
+
end
|
28
|
+
<% end -%>
|
data/spec/spec_helper.rb
ADDED
metadata
ADDED
@@ -0,0 +1,105 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: bundler-norelease
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.2
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- SpringMT
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-09-24 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.6'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.6'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
description: gem generator for no release
|
56
|
+
email:
|
57
|
+
- today.is.sky.blue.sky@gmail.com
|
58
|
+
executables:
|
59
|
+
- bundler-norelease
|
60
|
+
extensions: []
|
61
|
+
extra_rdoc_files: []
|
62
|
+
files:
|
63
|
+
- ".gitignore"
|
64
|
+
- ".rspec"
|
65
|
+
- ".travis.yml"
|
66
|
+
- Gemfile
|
67
|
+
- LICENSE.txt
|
68
|
+
- README.md
|
69
|
+
- Rakefile
|
70
|
+
- bin/bundler-norelease
|
71
|
+
- bundler-norelease.gemspec
|
72
|
+
- lib/bundler/norelease.rb
|
73
|
+
- lib/bundler/norelease/cli.rb
|
74
|
+
- lib/bundler/norelease/version.rb
|
75
|
+
- lib/bundler/templates/newgem/Rakefile.tt
|
76
|
+
- spec/bundler/norelease_spec.rb
|
77
|
+
- spec/spec_helper.rb
|
78
|
+
homepage: https://github.com/SpringMT/bundler-norelease
|
79
|
+
licenses:
|
80
|
+
- MIT
|
81
|
+
metadata: {}
|
82
|
+
post_install_message:
|
83
|
+
rdoc_options: []
|
84
|
+
require_paths:
|
85
|
+
- lib
|
86
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
87
|
+
requirements:
|
88
|
+
- - ">="
|
89
|
+
- !ruby/object:Gem::Version
|
90
|
+
version: '0'
|
91
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
92
|
+
requirements:
|
93
|
+
- - ">="
|
94
|
+
- !ruby/object:Gem::Version
|
95
|
+
version: '0'
|
96
|
+
requirements: []
|
97
|
+
rubyforge_project:
|
98
|
+
rubygems_version: 2.2.2
|
99
|
+
signing_key:
|
100
|
+
specification_version: 4
|
101
|
+
summary: gem generator for no release
|
102
|
+
test_files:
|
103
|
+
- spec/bundler/norelease_spec.rb
|
104
|
+
- spec/spec_helper.rb
|
105
|
+
has_rdoc:
|