kameleon-builder 2.2.0 → 2.2.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.
- checksums.yaml +7 -0
- data/CHANGELOG.rst +8 -0
- data/kameleon-builder.gemspec +16 -22
- data/lib/kameleon.rb +1 -0
- data/lib/kameleon/cli.rb +1 -1
- data/lib/kameleon/compat.rb +0 -4
- data/lib/kameleon/recipe.rb +11 -10
- data/templates/extend.erb +3 -3
- data/templates/qemu/archlinux-desktop-i686.yaml +3 -3
- data/templates/qemu/archlinux-desktop-x86_64.yaml +3 -3
- data/templates/qemu/archlinux-i686.yaml +3 -3
- data/templates/qemu/debian7-desktop-amd64.yaml +3 -3
- data/templates/qemu/debian7-kameleon-amd64.yaml +3 -3
- data/templates/qemu/debian7-oar-amd64.yaml +3 -3
- data/templates/qemu/debian8-amd64.yaml +3 -3
- data/templates/qemu/fedora20-desktop-x86_64.yaml +4 -4
- data/templates/qemu/ubuntu-12.04-desktop-amd64.yaml +3 -3
- data/templates/qemu/ubuntu-14.04-amd64.yaml +3 -3
- data/templates/qemu/ubuntu-14.04-desktop-amd64.yaml +3 -3
- data/templates/virtualbox/archlinux-desktop-i686.yaml +3 -3
- data/templates/virtualbox/archlinux-desktop-x86_64.yaml +3 -3
- data/templates/virtualbox/archlinux-i686.yaml +3 -3
- data/templates/virtualbox/centos6.5-i386.yaml +3 -3
- data/templates/virtualbox/debian7-desktop-amd64.yaml +3 -3
- data/templates/virtualbox/debian7-i386.yaml +3 -3
- data/templates/virtualbox/debian7-kameleon-amd64.yaml +3 -3
- data/templates/virtualbox/debian7-oar-amd64.yaml +3 -3
- data/templates/virtualbox/debian8-amd64.yaml +3 -3
- data/templates/virtualbox/debian8-i386.yaml +3 -3
- data/templates/virtualbox/ubuntu-12.04-desktop-amd64.yaml +3 -3
- data/templates/virtualbox/ubuntu-14.04-amd64.yaml +3 -3
- data/templates/virtualbox/ubuntu-14.04-desktop-amd64.yaml +3 -3
- data/version.txt +1 -1
- metadata +26 -24
- data/ext/mkrf_conf.rb +0 -58
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 1eeb84f0518b9bf6cd2f84f448e0abf99b3384e6
|
4
|
+
data.tar.gz: 1cae83863b12c6fb9ffab9f435c6d8bce27c456a
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 318367937e2f8525195ec158b0217c901ffa95b4c87e5711867e40aad830cec076be5380d94167c2f59a692e3efd355e4f635c328ec1283fa2ed8df22be78c92
|
7
|
+
data.tar.gz: 81e853c7b87824f8d8bccfe5f7bd1ec0e8783e13a4a8a493f2f8ebfb3cdf836b2f26a72651e911705dbbebba8c9212e708aae32c73df9b9ae5927afd7a6f3110
|
data/CHANGELOG.rst
CHANGED
data/kameleon-builder.gemspec
CHANGED
@@ -4,34 +4,28 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
require 'kameleon/version'
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
|
-
s.name =
|
7
|
+
s.name = 'kameleon-builder'
|
8
8
|
s.version = Kameleon::VERSION
|
9
|
-
s.authors = [
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
s.email = [
|
14
|
-
|
15
|
-
|
16
|
-
|
9
|
+
s.authors = ['Salem Harrache',
|
10
|
+
'Michael Mercier',
|
11
|
+
'Cristan Ruiz',
|
12
|
+
'Bruno Bzeznik']
|
13
|
+
s.email = ['salem.harrache@inria.fr',
|
14
|
+
'michael.mercier@inria.fr',
|
15
|
+
'cristian.ruiz@imag.fr',
|
16
|
+
'bruno.bzeznik@imag.fr']
|
17
17
|
s.description = %q{The mindful appliance builder}
|
18
18
|
s.summary = %q{Kameleon is a tool to build virtual machines from scratch}
|
19
|
-
s.homepage =
|
20
|
-
s.license =
|
19
|
+
s.homepage = 'http://kameleon.readthedocs.org/'
|
20
|
+
s.license = 'GPL-2'
|
21
21
|
|
22
22
|
s.files = `git ls-files`.split($/)
|
23
|
-
s.files.reject! { |file| file.start_with?(
|
24
|
-
s.files.reject! { |file| file.start_with?("omnibus/") }
|
23
|
+
s.files.reject! { |file| file.start_with?('docs/') }
|
25
24
|
s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
26
25
|
s.test_files = s.files.grep(%r{^(tests|s|features)/})
|
27
|
-
s.require_paths = [
|
26
|
+
s.require_paths = ['lib']
|
28
27
|
|
29
|
-
s.add_dependency 'childprocess', '~> 0.3'
|
30
|
-
s.add_dependency 'thor', '~> 0.15'
|
31
|
-
s.add_dependency 'table_print', '~> 1.5'
|
32
|
-
# Syck is also a dependency for Ruby 2 environments.
|
33
|
-
# It is installed at install-time if necessary,
|
34
|
-
# via ext/mkrf_conf.rb
|
35
|
-
# To allow installing the Syck gem when Ruby version is >2.0.0
|
36
|
-
s.extensions = ["ext/mkrf_conf.rb"]
|
28
|
+
s.add_dependency 'childprocess', '~> 0.5.3', '>= 0.3.0'
|
29
|
+
s.add_dependency 'thor', '~> 0.19', '>= 0.15.0'
|
30
|
+
s.add_dependency 'table_print', '~> 1.5.2'
|
37
31
|
end
|
data/lib/kameleon.rb
CHANGED
data/lib/kameleon/cli.rb
CHANGED
@@ -176,7 +176,7 @@ module Kameleon
|
|
176
176
|
|
177
177
|
desc "commands", "Lists all available commands", :hide => true
|
178
178
|
def commands
|
179
|
-
|
179
|
+
puts CLI.all_commands.keys - ["commands", "completions"]
|
180
180
|
end
|
181
181
|
|
182
182
|
desc "source_root", "Prints the kameleon directory path", :hide => true
|
data/lib/kameleon/compat.rb
CHANGED
data/lib/kameleon/recipe.rb
CHANGED
@@ -46,12 +46,8 @@ module Kameleon
|
|
46
46
|
Kameleon.ui.debug("Loading #{@path}")
|
47
47
|
fail RecipeError, "Could not find this following recipe : #{@path}" \
|
48
48
|
unless File.file? @path
|
49
|
-
yaml_recipe = YAML.load File.open @path
|
50
|
-
unless yaml_recipe.kind_of? Hash
|
51
|
-
fail RecipeError, "Invalid yaml error"
|
52
|
-
end
|
53
49
|
# Load entended recipe variables
|
54
|
-
yaml_recipe = load_base_recipe(
|
50
|
+
yaml_recipe = load_base_recipe(@path)
|
55
51
|
yaml_recipe.delete("extend")
|
56
52
|
|
57
53
|
# Load Global variables
|
@@ -141,21 +137,26 @@ module Kameleon
|
|
141
137
|
}
|
142
138
|
end
|
143
139
|
|
144
|
-
def load_base_recipe(
|
140
|
+
def load_base_recipe(path)
|
141
|
+
yaml_recipe = YAML.load_file path
|
142
|
+
|
143
|
+
unless yaml_recipe.kind_of? Hash
|
144
|
+
fail RecipeError, "Invalid yaml error, #{path}"
|
145
|
+
end
|
145
146
|
base_recipe_name = yaml_recipe.fetch("extend", "")
|
146
147
|
return yaml_recipe if base_recipe_name.empty?
|
147
148
|
|
148
149
|
## check that the recipe has not already been loaded
|
149
150
|
base_recipe_name << ".yaml" unless base_recipe_name.end_with? ".yaml"
|
150
|
-
base_recipe_path = File.join(File.dirname(
|
151
|
+
base_recipe_path = File.join(File.dirname(path), base_recipe_name)
|
151
152
|
|
152
153
|
## check that the recipe has not already been loaded
|
153
154
|
return yaml_recipe if @base_recipes_files.include? base_recipe_path
|
154
155
|
|
155
156
|
base_recipe_path << ".yaml" unless base_recipe_path.end_with? ".yaml"
|
156
157
|
fail RecipeError, "Could not find this following recipe : #{@recipe_path}" \
|
157
|
-
unless File.file?
|
158
|
-
base_yaml_recipe = YAML.
|
158
|
+
unless File.file? path
|
159
|
+
base_yaml_recipe = YAML.load_file base_recipe_path
|
159
160
|
unless yaml_recipe.kind_of? Hash
|
160
161
|
fail RecipeError, "Invalid yaml error"
|
161
162
|
end
|
@@ -187,7 +188,7 @@ module Kameleon
|
|
187
188
|
end
|
188
189
|
end
|
189
190
|
@base_recipes_files.push(Pathname.new(base_recipe_path))
|
190
|
-
return load_base_recipe(
|
191
|
+
return load_base_recipe(base_recipe_path)
|
191
192
|
end
|
192
193
|
|
193
194
|
def load_aliases(yaml_recipe)
|
data/templates/extend.erb
CHANGED
@@ -10,10 +10,10 @@
|
|
10
10
|
extend: archlinux-i686
|
11
11
|
|
12
12
|
bootstrap:
|
13
|
-
- @base
|
13
|
+
- "@base"
|
14
14
|
|
15
15
|
setup:
|
16
|
-
- @base
|
16
|
+
- "@base"
|
17
17
|
- install_yaourt
|
18
18
|
- install_gnome:
|
19
19
|
- keyboard_layout: en
|
@@ -22,4 +22,4 @@ setup:
|
|
22
22
|
hunspell-en faenza-icon-theme file-roller
|
23
23
|
|
24
24
|
export:
|
25
|
-
- @base
|
25
|
+
- "@base"
|
@@ -10,10 +10,10 @@
|
|
10
10
|
extend: archlinux-x86_64
|
11
11
|
|
12
12
|
bootstrap:
|
13
|
-
- @base
|
13
|
+
- "@base"
|
14
14
|
|
15
15
|
setup:
|
16
|
-
- @base
|
16
|
+
- "@base"
|
17
17
|
- install_yaourt
|
18
18
|
- install_gnome:
|
19
19
|
- keyboard_layout: en
|
@@ -22,4 +22,4 @@ setup:
|
|
22
22
|
hunspell-en faenza-icon-theme file-roller
|
23
23
|
|
24
24
|
export:
|
25
|
-
- @base
|
25
|
+
- "@base"
|
@@ -15,10 +15,10 @@ global:
|
|
15
15
|
arch: amd64
|
16
16
|
|
17
17
|
bootstrap:
|
18
|
-
- @base
|
18
|
+
- "@base"
|
19
19
|
|
20
20
|
setup:
|
21
|
-
- @base
|
21
|
+
- "@base"
|
22
22
|
- autologin
|
23
23
|
- install_software:
|
24
24
|
- packages: parted qemu-system debootstrap qemu-utils
|
@@ -37,4 +37,4 @@ setup:
|
|
37
37
|
rm -f /bigemptyfile
|
38
38
|
|
39
39
|
export:
|
40
|
-
- @base
|
40
|
+
- "@base"
|
@@ -30,10 +30,10 @@ global:
|
|
30
30
|
oar_prefix_install: "/usr/local"
|
31
31
|
|
32
32
|
bootstrap:
|
33
|
-
- @base
|
33
|
+
- "@base"
|
34
34
|
|
35
35
|
setup:
|
36
|
-
- @base
|
36
|
+
- "@base"
|
37
37
|
- oar_prereq_install
|
38
38
|
- oar_devel_prereq_install
|
39
39
|
- oar_git_install
|
@@ -48,4 +48,4 @@ setup:
|
|
48
48
|
- autologin
|
49
49
|
|
50
50
|
export:
|
51
|
-
- @base
|
51
|
+
- "@base"
|
@@ -10,12 +10,12 @@
|
|
10
10
|
extend: fedora20-x86_64
|
11
11
|
|
12
12
|
bootstrap:
|
13
|
-
- @base
|
13
|
+
- "@base"
|
14
14
|
|
15
15
|
setup:
|
16
|
-
- @base
|
16
|
+
- "@base"
|
17
17
|
- install_software:
|
18
|
-
- packages: @x-window-system @gnome-desktop
|
18
|
+
- packages: "@x-window-system @gnome-desktop"
|
19
19
|
|
20
20
|
export:
|
21
|
-
- @base
|
21
|
+
- "@base"
|
@@ -10,10 +10,10 @@
|
|
10
10
|
extend: archlinux-i686
|
11
11
|
|
12
12
|
bootstrap:
|
13
|
-
- @base
|
13
|
+
- "@base"
|
14
14
|
|
15
15
|
setup:
|
16
|
-
- @base
|
16
|
+
- "@base"
|
17
17
|
- install_yaourt
|
18
18
|
- install_gnome:
|
19
19
|
- keyboard_layout: en
|
@@ -22,4 +22,4 @@ setup:
|
|
22
22
|
hunspell-en faenza-icon-theme file-roller
|
23
23
|
|
24
24
|
export:
|
25
|
-
- @base
|
25
|
+
- "@base"
|
@@ -13,10 +13,10 @@ global:
|
|
13
13
|
virtualbox_memory_size: 1024
|
14
14
|
|
15
15
|
bootstrap:
|
16
|
-
- @base
|
16
|
+
- "@base"
|
17
17
|
|
18
18
|
setup:
|
19
|
-
- @base
|
19
|
+
- "@base"
|
20
20
|
- install_yaourt
|
21
21
|
- install_gnome:
|
22
22
|
- keyboard_layout: en
|
@@ -25,4 +25,4 @@ setup:
|
|
25
25
|
hunspell-en faenza-icon-theme file-roller
|
26
26
|
|
27
27
|
export:
|
28
|
-
- @base
|
28
|
+
- "@base"
|
@@ -28,12 +28,12 @@ global:
|
|
28
28
|
|
29
29
|
#== Bootstrap the new system and create the 'in_context'
|
30
30
|
bootstrap:
|
31
|
-
- @base
|
31
|
+
- "@base"
|
32
32
|
|
33
33
|
#== Install and configuration steps
|
34
34
|
setup:
|
35
|
-
- @base
|
35
|
+
- "@base"
|
36
36
|
|
37
37
|
#== Export the generated appliance in the format of your choice
|
38
38
|
export:
|
39
|
-
- @base
|
39
|
+
- "@base"
|
@@ -14,10 +14,10 @@ global:
|
|
14
14
|
# variables that you can override
|
15
15
|
|
16
16
|
bootstrap:
|
17
|
-
- @base
|
17
|
+
- "@base"
|
18
18
|
|
19
19
|
setup:
|
20
|
-
- @base
|
20
|
+
- "@base"
|
21
21
|
- autologin
|
22
22
|
- install_software:
|
23
23
|
- packages: parted qemu-system debootstrap qemu-utils ruby ruby-childprocess
|
@@ -35,4 +35,4 @@ setup:
|
|
35
35
|
rm -f /bigemptyfile
|
36
36
|
|
37
37
|
export:
|
38
|
-
- @base
|
38
|
+
- "@base"
|
@@ -30,10 +30,10 @@ global:
|
|
30
30
|
oar_prefix_install: "/usr/local"
|
31
31
|
|
32
32
|
bootstrap:
|
33
|
-
- @base
|
33
|
+
- "@base"
|
34
34
|
|
35
35
|
setup:
|
36
|
-
- @base
|
36
|
+
- "@base"
|
37
37
|
- oar_prereq_install
|
38
38
|
- oar_devel_prereq_install
|
39
39
|
- oar_git_install
|
@@ -48,4 +48,4 @@ setup:
|
|
48
48
|
- autologin
|
49
49
|
|
50
50
|
export:
|
51
|
-
- @base
|
51
|
+
- "@base"
|
data/version.txt
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.2.
|
1
|
+
2.2.1
|
metadata
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kameleon-builder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
5
|
-
prerelease:
|
4
|
+
version: 2.2.1
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Salem Harrache
|
@@ -12,56 +11,62 @@ authors:
|
|
12
11
|
autorequire:
|
13
12
|
bindir: bin
|
14
13
|
cert_chain: []
|
15
|
-
date: 2014-07-
|
14
|
+
date: 2014-07-22 00:00:00.000000000 Z
|
16
15
|
dependencies:
|
17
16
|
- !ruby/object:Gem::Dependency
|
18
17
|
name: childprocess
|
19
18
|
requirement: !ruby/object:Gem::Requirement
|
20
|
-
none: false
|
21
19
|
requirements:
|
22
20
|
- - ~>
|
23
21
|
- !ruby/object:Gem::Version
|
24
|
-
version:
|
22
|
+
version: 0.5.3
|
23
|
+
- - '>='
|
24
|
+
- !ruby/object:Gem::Version
|
25
|
+
version: 0.3.0
|
25
26
|
type: :runtime
|
26
27
|
prerelease: false
|
27
28
|
version_requirements: !ruby/object:Gem::Requirement
|
28
|
-
none: false
|
29
29
|
requirements:
|
30
30
|
- - ~>
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version:
|
32
|
+
version: 0.5.3
|
33
|
+
- - '>='
|
34
|
+
- !ruby/object:Gem::Version
|
35
|
+
version: 0.3.0
|
33
36
|
- !ruby/object:Gem::Dependency
|
34
37
|
name: thor
|
35
38
|
requirement: !ruby/object:Gem::Requirement
|
36
|
-
none: false
|
37
39
|
requirements:
|
38
40
|
- - ~>
|
39
41
|
- !ruby/object:Gem::Version
|
40
|
-
version: '0.
|
42
|
+
version: '0.19'
|
43
|
+
- - '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: 0.15.0
|
41
46
|
type: :runtime
|
42
47
|
prerelease: false
|
43
48
|
version_requirements: !ruby/object:Gem::Requirement
|
44
|
-
none: false
|
45
49
|
requirements:
|
46
50
|
- - ~>
|
47
51
|
- !ruby/object:Gem::Version
|
48
|
-
version: '0.
|
52
|
+
version: '0.19'
|
53
|
+
- - '>='
|
54
|
+
- !ruby/object:Gem::Version
|
55
|
+
version: 0.15.0
|
49
56
|
- !ruby/object:Gem::Dependency
|
50
57
|
name: table_print
|
51
58
|
requirement: !ruby/object:Gem::Requirement
|
52
|
-
none: false
|
53
59
|
requirements:
|
54
60
|
- - ~>
|
55
61
|
- !ruby/object:Gem::Version
|
56
|
-
version:
|
62
|
+
version: 1.5.2
|
57
63
|
type: :runtime
|
58
64
|
prerelease: false
|
59
65
|
version_requirements: !ruby/object:Gem::Requirement
|
60
|
-
none: false
|
61
66
|
requirements:
|
62
67
|
- - ~>
|
63
68
|
- !ruby/object:Gem::Version
|
64
|
-
version:
|
69
|
+
version: 1.5.2
|
65
70
|
description: The mindful appliance builder
|
66
71
|
email:
|
67
72
|
- salem.harrache@inria.fr
|
@@ -70,8 +75,7 @@ email:
|
|
70
75
|
- bruno.bzeznik@imag.fr
|
71
76
|
executables:
|
72
77
|
- kameleon
|
73
|
-
extensions:
|
74
|
-
- ext/mkrf_conf.rb
|
78
|
+
extensions: []
|
75
79
|
extra_rdoc_files: []
|
76
80
|
files:
|
77
81
|
- .editorconfig
|
@@ -110,7 +114,6 @@ files:
|
|
110
114
|
- contrib/steps/setup/root_ssh_config.yaml
|
111
115
|
- contrib/steps/setup/set_user_password.yaml
|
112
116
|
- contrib/steps/setup/system_optimization.yaml
|
113
|
-
- ext/mkrf_conf.rb
|
114
117
|
- kameleon-builder.gemspec
|
115
118
|
- lib/kameleon.rb
|
116
119
|
- lib/kameleon/cli.rb
|
@@ -258,27 +261,26 @@ files:
|
|
258
261
|
homepage: http://kameleon.readthedocs.org/
|
259
262
|
licenses:
|
260
263
|
- GPL-2
|
264
|
+
metadata: {}
|
261
265
|
post_install_message:
|
262
266
|
rdoc_options: []
|
263
267
|
require_paths:
|
264
268
|
- lib
|
265
269
|
required_ruby_version: !ruby/object:Gem::Requirement
|
266
|
-
none: false
|
267
270
|
requirements:
|
268
|
-
- -
|
271
|
+
- - '>='
|
269
272
|
- !ruby/object:Gem::Version
|
270
273
|
version: '0'
|
271
274
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
272
|
-
none: false
|
273
275
|
requirements:
|
274
|
-
- -
|
276
|
+
- - '>='
|
275
277
|
- !ruby/object:Gem::Version
|
276
278
|
version: '0'
|
277
279
|
requirements: []
|
278
280
|
rubyforge_project:
|
279
|
-
rubygems_version: 1.
|
281
|
+
rubygems_version: 2.1.11
|
280
282
|
signing_key:
|
281
|
-
specification_version:
|
283
|
+
specification_version: 4
|
282
284
|
summary: Kameleon is a tool to build virtual machines from scratch
|
283
285
|
test_files:
|
284
286
|
- tests/helper.rb
|
data/ext/mkrf_conf.rb
DELETED
@@ -1,58 +0,0 @@
|
|
1
|
-
# Based on: http://www.programmersparadox.com/2012/05/21/gemspec-loading-dependent-gems-based-on-the-users-system/
|
2
|
-
|
3
|
-
# This file needs to be named mkrf_conf.rb
|
4
|
-
# so that rubygems will recognize it as a ruby extension
|
5
|
-
# file and not think it is a C extension file
|
6
|
-
|
7
|
-
jruby = defined?(JRUBY_VERSION) || (defined?(RUBY_ENGINE) && 'jruby' == RUBY_ENGINE)
|
8
|
-
rbx = defined?(RUBY_ENGINE) && 'rbx' == RUBY_ENGINE
|
9
|
-
|
10
|
-
def already_installed(dep)
|
11
|
-
!Gem::DependencyInstaller.new(:domain => :local).find_gems_with_sources(dep).empty? ||
|
12
|
-
!Gem::DependencyInstaller.new(:domain => :local,:prerelease => true).find_gems_with_sources(dep).empty?
|
13
|
-
end
|
14
|
-
|
15
|
-
# Load up the rubygem's dependency installer to
|
16
|
-
# installer the gems we want based on the version
|
17
|
-
# of Ruby the user has installed
|
18
|
-
|
19
|
-
unless jruby || rbx
|
20
|
-
require 'rubygems'
|
21
|
-
require 'rubygems/command.rb'
|
22
|
-
require 'rubygems/dependency.rb'
|
23
|
-
require 'rubygems/dependency_installer.rb'
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
begin
|
28
|
-
Gem::Command.build_args = ARGV
|
29
|
-
rescue NoMethodError
|
30
|
-
end
|
31
|
-
|
32
|
-
if RUBY_VERSION > "2.0"
|
33
|
-
dep = Gem::Dependency.new("syck", '> 0')
|
34
|
-
end
|
35
|
-
|
36
|
-
begin
|
37
|
-
puts "Installing base gem"
|
38
|
-
inst = Gem::DependencyInstaller.new
|
39
|
-
inst.install dep
|
40
|
-
rescue
|
41
|
-
inst = Gem::DependencyInstaller.new(:prerelease => true)
|
42
|
-
begin
|
43
|
-
inst.install dep
|
44
|
-
rescue Exception => e
|
45
|
-
puts e
|
46
|
-
puts e.backtrace.join "\n "
|
47
|
-
exit(1)
|
48
|
-
end
|
49
|
-
end unless dep.nil? || already_installed(dep)
|
50
|
-
end
|
51
|
-
|
52
|
-
# If this was C, rubygems would attempt to run make
|
53
|
-
# Since this is Ruby, rubygems will attempt to run rake
|
54
|
-
# If it doesn't find and successfully run a rakefile, it errors out
|
55
|
-
f = File.open(File.join(File.dirname(__FILE__), "Rakefile"), "w")
|
56
|
-
f.write("task :default\n")
|
57
|
-
f.close
|
58
|
-
|