specific_install 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +13 -5
- metadata +14 -23
- data/.gitignore +0 -6
- data/Gemfile +0 -4
- data/LICENSE.txt +0 -22
- data/README.md +0 -61
- data/Rakefile +0 -1
- data/lib/rubygems/commands/specific_install_command.rb +0 -133
- data/lib/rubygems_plugin.rb +0 -2
- data/lib/specific_install/version.rb +0 -3
- data/specific_install.gemspec +0 -28
checksums.yaml
CHANGED
@@ -1,7 +1,15 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
2
|
+
!binary "U0hBMQ==":
|
3
|
+
metadata.gz: !binary |-
|
4
|
+
YmJlZWEyZmM1NzgxZWNjMGU1MjcxOWE4YjBjZDM1NmViZjRkYjA4ZQ==
|
5
|
+
data.tar.gz: !binary |-
|
6
|
+
MTA4NTFlNjE1Y2QxNjQyMzMyNTEzNjZhODJhNTU4ZmFmOTExM2Q0Yw==
|
5
7
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
|
8
|
+
metadata.gz: !binary |-
|
9
|
+
ZjczMTc2MzM0YjJiNzhmNWQwZGI2YTBjN2FmOTU1YThmZTM0ZjE5ODE4NGQ4
|
10
|
+
YmYxNzAxNWQyNTdkYjkyYzU2NGY3MWVlOGNjMmY5MTYyNWU2ZjI5MTk5MTAy
|
11
|
+
ZTNjM2Y1ZGE4NzQxNzhkYjE0NTc1MDJmMmU1ODA4MTMzYTg3ODk=
|
12
|
+
data.tar.gz: !binary |-
|
13
|
+
NGQxNTkxZWExZmRmZGUxMzc3YTllOTJkNjZmNjM4ZWExYjkyYTk4YzdmMGE5
|
14
|
+
MTY2MTI4MDBkN2I3NzQ4Zjk0YzQwMzQ3YjJiMzcxMGQ2ZjY4YWFlNTAyMDgx
|
15
|
+
NTk2OWU1MDY1YjM5NDBlN2VlZjg5YjY1ZTRkN2VmNTgwNDQ3OWU=
|
metadata
CHANGED
@@ -1,55 +1,55 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: specific_install
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Roger Pack
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: backports
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - '>='
|
17
|
+
- - ! '>='
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - '>='
|
24
|
+
- - ! '>='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rspec
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - '>='
|
31
|
+
- - ! '>='
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - '>='
|
38
|
+
- - ! '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: sane
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - '>='
|
45
|
+
- - ! '>='
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - '>='
|
52
|
+
- - ! '>='
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
@@ -70,14 +70,14 @@ dependencies:
|
|
70
70
|
name: rake
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - '>='
|
73
|
+
- - ! '>='
|
74
74
|
- !ruby/object:Gem::Version
|
75
75
|
version: '0'
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - '>='
|
80
|
+
- - ! '>='
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '0'
|
83
83
|
description: rubygems plugin that allows you you to install a gem from from its github
|
@@ -86,16 +86,7 @@ email: rogerdpack@gmail.com
|
|
86
86
|
executables: []
|
87
87
|
extensions: []
|
88
88
|
extra_rdoc_files: []
|
89
|
-
files:
|
90
|
-
- .gitignore
|
91
|
-
- Gemfile
|
92
|
-
- LICENSE.txt
|
93
|
-
- README.md
|
94
|
-
- Rakefile
|
95
|
-
- lib/rubygems/commands/specific_install_command.rb
|
96
|
-
- lib/rubygems_plugin.rb
|
97
|
-
- lib/specific_install/version.rb
|
98
|
-
- specific_install.gemspec
|
89
|
+
files: []
|
99
90
|
homepage: https://github.com/rdp/specific_install
|
100
91
|
licenses:
|
101
92
|
- MIT
|
@@ -106,17 +97,17 @@ require_paths:
|
|
106
97
|
- lib
|
107
98
|
required_ruby_version: !ruby/object:Gem::Requirement
|
108
99
|
requirements:
|
109
|
-
- - '>='
|
100
|
+
- - ! '>='
|
110
101
|
- !ruby/object:Gem::Version
|
111
102
|
version: '0'
|
112
103
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
113
104
|
requirements:
|
114
|
-
- - '>='
|
105
|
+
- - ! '>='
|
115
106
|
- !ruby/object:Gem::Version
|
116
107
|
version: '0'
|
117
108
|
requirements: []
|
118
109
|
rubyforge_project:
|
119
|
-
rubygems_version: 2.
|
110
|
+
rubygems_version: 2.1.1
|
120
111
|
signing_key:
|
121
112
|
specification_version: 4
|
122
113
|
summary: rubygems plugin that allows you you to install a gem from from its github
|
data/.gitignore
DELETED
data/Gemfile
DELETED
data/LICENSE.txt
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
Copyright (c) 2010-2013 Roger Pack
|
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
DELETED
@@ -1,61 +0,0 @@
|
|
1
|
-
# Gem::SpecificInstall
|
2
|
-
|
3
|
-
## Installation
|
4
|
-
|
5
|
-
Add this line to your application's Gemfile:
|
6
|
-
|
7
|
-
gem 'specific_install'
|
8
|
-
|
9
|
-
And then execute:
|
10
|
-
|
11
|
-
$ bundle
|
12
|
-
|
13
|
-
Or install it yourself as:
|
14
|
-
|
15
|
-
$ gem install specific_install
|
16
|
-
|
17
|
-
## Usage
|
18
|
-
|
19
|
-
A Rubygem plugin that allows you to install an "edge" gem straight from its github repository,
|
20
|
-
or install one from an arbitrary url web:
|
21
|
-
|
22
|
-
ex:
|
23
|
-
|
24
|
-
`
|
25
|
-
$ gem specific_install -l http://github.com/githubsvnclone/rdoc.git
|
26
|
-
`
|
27
|
-
|
28
|
-
### Additional Options
|
29
|
-
|
30
|
-
-l --location URL of resource
|
31
|
-
Formats of URL/Resource
|
32
|
-
* Full URL to HTTP Repo `https://github.com/rdp/specific_install.git`
|
33
|
-
* Full URL to Git Repo `git@github.com:rdp/specific_install.git`
|
34
|
-
* URL of Pre-Built Gem `http://example.com/specific_install.gem`
|
35
|
-
* Github Repo shortcode `rdp/specific_install`
|
36
|
-
|
37
|
-
-b --branch BRANCH to use for Gem creation
|
38
|
-
Branch option does a `git checkout BRANCH` before `gem build GEM`
|
39
|
-
Example:
|
40
|
-
`git specific_install -l rdp/specific_install -b pre-release`
|
41
|
-
Note: This feature is new and may not fail gracefully.
|
42
|
-
|
43
|
-
|
44
|
-
`git_install` is aliased to the behavior of `specific_install`
|
45
|
-
This alias is shorter and is more intention revealing of the gem's behavior.
|
46
|
-
## Internal Behavior
|
47
|
-
|
48
|
-
It runs `git clone`, and `rake install,` install the gem, then deletes the temp directory]
|
49
|
-
|
50
|
-
|
51
|
-
## Contributing
|
52
|
-
|
53
|
-
1. Fork it
|
54
|
-
2. Create your feature branch (`git checkout -b my-new-feature`)
|
55
|
-
3. Commit your changes (`git commit -am 'Add some feature'`)
|
56
|
-
4. Push to the branch (`git push origin my-new-feature`)
|
57
|
-
5. Create new Pull Request
|
58
|
-
|
59
|
-
Enjoy!
|
60
|
-
|
61
|
-
Copyright 2010-2013 Roger Pack - `http://github.com/rdp/specific_installs`
|
data/Rakefile
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
require "bundler/gem_tasks"
|
@@ -1,133 +0,0 @@
|
|
1
|
-
require 'rubygems/command_manager'
|
2
|
-
|
3
|
-
class Gem::Commands::SpecificInstallCommand < Gem::Command
|
4
|
-
|
5
|
-
def description
|
6
|
-
"Allows you to install an \"edge\" gem straight from its github repository or from a web site"
|
7
|
-
end
|
8
|
-
|
9
|
-
def initialize
|
10
|
-
super 'specific_install', description
|
11
|
-
|
12
|
-
add_option('-l', '--location LOCATION', arguments) do |location|
|
13
|
-
options[:location] = location
|
14
|
-
end
|
15
|
-
|
16
|
-
add_option('-b', '--branch LOCATION', arguments) do |branch|
|
17
|
-
options[:branch] = branch
|
18
|
-
end
|
19
|
-
|
20
|
-
end
|
21
|
-
|
22
|
-
def arguments
|
23
|
-
"LOCATION like http://github.com/rdp/ruby_tutorials_core or git://github.com/rdp/ruby_tutorials_core.git or http://host/gem_name.gem"
|
24
|
-
"BRANCH (optional) like beta, or new-feature"
|
25
|
-
end
|
26
|
-
|
27
|
-
def usage
|
28
|
-
"#{program_name} [LOCATION] [BRANCH]"
|
29
|
-
end
|
30
|
-
|
31
|
-
def execute
|
32
|
-
require 'tempfile'
|
33
|
-
require 'backports'
|
34
|
-
require 'fileutils'
|
35
|
-
require 'open-uri'
|
36
|
-
unless options[:location]
|
37
|
-
puts "No location received. Use `gem specific_install -l http://example.com/rdp/specific_install`"
|
38
|
-
exit 1
|
39
|
-
end
|
40
|
-
# options are
|
41
|
-
# http://github.com/githubsvnclone/rdoc.git
|
42
|
-
# git://github.com/githubsvnclone/rdoc.git
|
43
|
-
# git@github.com:rdp/install_from_git.git
|
44
|
-
# http://github.com/rdp/install_from_git [later]
|
45
|
-
# http://host/gem_name.gem
|
46
|
-
# rdp/specific_install
|
47
|
-
dir = Dir.mktmpdir
|
48
|
-
begin
|
49
|
-
loc = options[:location]
|
50
|
-
case loc
|
51
|
-
when /^http(.*)\.gem$/
|
52
|
-
Dir.chdir dir do
|
53
|
-
say "downloading #{loc}"
|
54
|
-
gem_name = loc.split("/").last
|
55
|
-
download(loc, gem_name)
|
56
|
-
|
57
|
-
if install_gemspec
|
58
|
-
success_message
|
59
|
-
else
|
60
|
-
puts "failed"
|
61
|
-
end
|
62
|
-
end
|
63
|
-
when /\.git$/
|
64
|
-
say 'git installing from ' + loc
|
65
|
-
|
66
|
-
system("git clone #{loc} #{dir}")
|
67
|
-
install_from_git(dir)
|
68
|
-
when %r(.*/.*)
|
69
|
-
puts "Installing from git@github.com:#{loc}.git"
|
70
|
-
|
71
|
-
system("git clone git@github.com:#{loc}.git #{dir}")
|
72
|
-
install_from_git(dir)
|
73
|
-
else
|
74
|
-
puts 'Error: must end with .git to be a git repository' +
|
75
|
-
'or be in shorthand form: rdp/specific_install'
|
76
|
-
end
|
77
|
-
ensure
|
78
|
-
FileUtils.rm_rf dir
|
79
|
-
end
|
80
|
-
|
81
|
-
end
|
82
|
-
|
83
|
-
private
|
84
|
-
|
85
|
-
def download( full_url, output_name )
|
86
|
-
File.open(output_name, "wb") do |output_file|
|
87
|
-
output_file.write(open(full_url).read)
|
88
|
-
end
|
89
|
-
end
|
90
|
-
|
91
|
-
def install_from_git(dir)
|
92
|
-
Dir.chdir dir do
|
93
|
-
['', 'rake gemspec', 'rake gem', 'rake build', 'rake package'].each do |command|
|
94
|
-
system command
|
95
|
-
if install_gemspec
|
96
|
-
success_message
|
97
|
-
exit 0
|
98
|
-
end
|
99
|
-
end
|
100
|
-
end
|
101
|
-
end
|
102
|
-
|
103
|
-
def success_message
|
104
|
-
puts 'Successfully installed'
|
105
|
-
end
|
106
|
-
|
107
|
-
def install_gemspec
|
108
|
-
if gemspec = Dir['*.gemspec'][0]
|
109
|
-
change_to_branch(options[:branch]) if options[:branch]
|
110
|
-
system("gem build #{gemspec}")
|
111
|
-
system("gem install *.gem")
|
112
|
-
true
|
113
|
-
else
|
114
|
-
if gem = Dir['**/*.gem'][0]
|
115
|
-
system("gem install #{gem}")
|
116
|
-
true
|
117
|
-
else
|
118
|
-
false
|
119
|
-
end
|
120
|
-
end
|
121
|
-
end
|
122
|
-
|
123
|
-
def change_to_branch(branch)
|
124
|
-
system("git checkout #{branch}")
|
125
|
-
system("git branch")
|
126
|
-
end
|
127
|
-
end
|
128
|
-
|
129
|
-
class Gem::Commands::GitInstallCommand < Gem::Commands::SpecificInstallCommand
|
130
|
-
end
|
131
|
-
|
132
|
-
Gem::CommandManager.instance.register_command :specific_install
|
133
|
-
Gem::CommandManager.instance.register_command :git_install
|
data/lib/rubygems_plugin.rb
DELETED
data/specific_install.gemspec
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
lib = File.expand_path('../lib', __FILE__)
|
3
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
-
require 'specific_install/version'
|
5
|
-
|
6
|
-
Gem::Specification.new do |s|
|
7
|
-
|
8
|
-
s.name = "specific_install"
|
9
|
-
s.description = %q{rubygems plugin that allows you you to install a gem from from its github repository (like 'edge'), or from an arbitrary URL}
|
10
|
-
s.summary = "rubygems plugin that allows you you to install a gem from from its github repository (like 'edge'), or from an arbitrary URL"
|
11
|
-
s.email = "rogerdpack@gmail.com"
|
12
|
-
s.homepage = "http://github.com/rdp/specific_installs"
|
13
|
-
s.authors = ["Roger Pack"]
|
14
|
-
s.version = SpecificInstall::VERSION
|
15
|
-
s.homepage = "https://github.com/rdp/specific_install"
|
16
|
-
s.license = "MIT"
|
17
|
-
|
18
|
-
s.files = `git ls-files`.split($/)
|
19
|
-
s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
20
|
-
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
21
|
-
s.require_paths = ["lib"]
|
22
|
-
|
23
|
-
s.add_dependency 'backports'
|
24
|
-
s.add_development_dependency 'rspec'
|
25
|
-
s.add_development_dependency 'sane'
|
26
|
-
s.add_development_dependency "bundler", "~> 1.3"
|
27
|
-
s.add_development_dependency "rake"
|
28
|
-
end
|