naether 0.11.1-java → 0.12.0-java
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +4 -2
- data/VERSION +1 -1
- data/core-0.12.0.jar +0 -0
- data/doc/Naether.html +1 -1
- data/doc/Naether/Bootstrap.html +5 -5
- data/doc/Naether/Configurator.html +6 -6
- data/doc/Naether/Java.html +5 -5
- data/doc/Naether/Java/JRuby.html +5 -5
- data/doc/Naether/Java/Ruby.html +91 -75
- data/doc/Naether/Maven.html +121 -47
- data/doc/Naether/Notation.html +7 -7
- data/doc/Naether/Runtime.html +10 -10
- data/doc/_index.html +1 -1
- data/doc/file.README.html +5 -3
- data/doc/index.html +5 -3
- data/doc/method_list.html +29 -23
- data/doc/top-level-namespace.html +1 -1
- data/jar_dependencies.yml +2 -1
- data/lib/naether/java/ruby.rb +9 -1
- data/lib/naether/maven.rb +24 -9
- data/naether.gemspec +3 -3
- data/pom.xml +37 -3
- metadata +3 -3
- data/core-0.11.1.jar +0 -0
@@ -103,7 +103,7 @@
|
|
103
103
|
</div>
|
104
104
|
|
105
105
|
<div id="footer">
|
106
|
-
Generated on
|
106
|
+
Generated on Tue Oct 01 15:16:15 2013 by
|
107
107
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
108
108
|
0.8.7.2 (ruby-1.9.3).
|
109
109
|
</div>
|
data/jar_dependencies.yml
CHANGED
@@ -5,6 +5,7 @@
|
|
5
5
|
- com.jcraft:jsch:jar:0.1.44-1
|
6
6
|
- com.ning:async-http-client:jar:1.6.5
|
7
7
|
- commons-io:commons-io:jar:2.0.1
|
8
|
+
- org.apache.maven.shared:maven-invoker:jar:2.1.1
|
8
9
|
- org.apache.maven:maven-aether-provider:jar:3.0.3
|
9
10
|
- org.apache.maven:maven-model:jar:3.0.3
|
10
11
|
- org.apache.maven:maven-model-builder:jar:3.0.3
|
@@ -19,7 +20,7 @@
|
|
19
20
|
- org.codehaus.plexus:plexus-component-annotations:jar:1.5.5
|
20
21
|
- org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-6
|
21
22
|
- org.codehaus.plexus:plexus-interpolation:jar:1.14
|
22
|
-
- org.codehaus.plexus:plexus-utils:jar:
|
23
|
+
- org.codehaus.plexus:plexus-utils:jar:3.0.8
|
23
24
|
- org.jsoup:jsoup:jar:1.6.1
|
24
25
|
- org.slf4j:slf4j-api:jar:1.6.6
|
25
26
|
- org.slf4j:jcl-over-slf4j:jar:1.6.6
|
data/lib/naether/java/ruby.rb
CHANGED
@@ -23,7 +23,15 @@ module Naether
|
|
23
23
|
|
24
24
|
# Call Rjb::load with an empty classpath, incase Rjb::load has already been called
|
25
25
|
java_opts = (ENV['JAVA_OPTS'] || ENV['JAVA_OPTIONS']).to_s.split
|
26
|
-
|
26
|
+
|
27
|
+
begin
|
28
|
+
Rjb::load("", java_opts)
|
29
|
+
rescue StandardError => e
|
30
|
+
if e.message == "can't create Java VM"
|
31
|
+
puts "RJB was unable to find JVM, try setting JAVA_HOME env"
|
32
|
+
end
|
33
|
+
raise e
|
34
|
+
end
|
27
35
|
|
28
36
|
@loaded_paths = []
|
29
37
|
load_paths( naether_jar )
|
data/lib/naether/maven.rb
CHANGED
@@ -82,17 +82,14 @@ module Naether
|
|
82
82
|
deps = @project.getDependenciesNotation( scopes )
|
83
83
|
end
|
84
84
|
|
85
|
+
elsif scopes
|
86
|
+
list = Naether::Java.convert_to_java_list( scopes )
|
87
|
+
|
88
|
+
deps = @project._invoke('getDependenciesNotation', 'Ljava.util.List;', list)
|
85
89
|
else
|
86
|
-
|
87
|
-
if scopes
|
88
|
-
list = Naether::Java.convert_to_java_list( scopes )
|
89
|
-
|
90
|
-
deps = @project._invoke('getDependenciesNotation', 'Ljava.util.List;', list)
|
91
|
-
else
|
92
|
-
deps = @project.getDependenciesNotation()
|
93
|
-
end
|
94
|
-
|
90
|
+
deps = @project.getDependenciesNotation()
|
95
91
|
end
|
92
|
+
|
96
93
|
|
97
94
|
Naether::Java.convert_to_ruby_array( deps, true )
|
98
95
|
end
|
@@ -148,5 +145,23 @@ module Naether
|
|
148
145
|
def write_pom( file_path )
|
149
146
|
@project.writePom( file_path )
|
150
147
|
end
|
148
|
+
|
149
|
+
def invoke( *opts )
|
150
|
+
#defaults
|
151
|
+
config = {
|
152
|
+
:maven_home => ENV['maven.home'] || '/usr/share/maven',
|
153
|
+
:local_repo => File.expand_path('~/.m2/repository')
|
154
|
+
}
|
155
|
+
|
156
|
+
if opts.last.is_a? Hash
|
157
|
+
config = defaults.merge( opts.pop )
|
158
|
+
end
|
159
|
+
goals = opts
|
160
|
+
|
161
|
+
pom = @project.getPomFile().getAbsolutePath()
|
162
|
+
|
163
|
+
invoker = Naether::Java.create("com.tobedevoured.naether.maven.Invoker", config[:local_repo], config[:maven_home] )
|
164
|
+
invoker.execute( pom, Naether::Java.convert_to_java_list(goals) )
|
165
|
+
end
|
151
166
|
end
|
152
167
|
end
|
data/naether.gemspec
CHANGED
@@ -5,12 +5,12 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "naether"
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.12.0"
|
9
9
|
s.platform = "java"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
12
|
s.authors = ["Michael Guymon"]
|
13
|
-
s.date = "2013-
|
13
|
+
s.date = "2013-10-01"
|
14
14
|
s.description = "Java dependency resolver using Maven's Aether"
|
15
15
|
s.email = "michael@tobedevoured.com"
|
16
16
|
s.extensions = ["Rakefile"]
|
@@ -25,7 +25,7 @@ Gem::Specification.new do |s|
|
|
25
25
|
"README.md",
|
26
26
|
"Rakefile",
|
27
27
|
"VERSION",
|
28
|
-
"core-0.
|
28
|
+
"core-0.12.0.jar",
|
29
29
|
"doc/Naether.html",
|
30
30
|
"doc/Naether/Bootstrap.html",
|
31
31
|
"doc/Naether/Configurator.html",
|
data/pom.xml
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
<modelVersion>4.0.0</modelVersion>
|
4
4
|
<groupId>com.tobedevoured.naether</groupId>
|
5
5
|
<artifactId>core</artifactId>
|
6
|
-
<version>0.
|
6
|
+
<version>0.12.0</version>
|
7
7
|
<name>Naether</name>
|
8
8
|
<packaging>jar</packaging>
|
9
9
|
<url>https://github.com/mguymon/naether</url>
|
@@ -70,6 +70,13 @@
|
|
70
70
|
<version>${org.slf4j.version}</version>
|
71
71
|
</dependency>
|
72
72
|
|
73
|
+
<!-- Maven Invoker -->
|
74
|
+
<dependency>
|
75
|
+
<groupId>org.apache.maven.shared</groupId>
|
76
|
+
<artifactId>maven-invoker</artifactId>
|
77
|
+
<version>2.1.1</version>
|
78
|
+
</dependency>
|
79
|
+
|
73
80
|
<!-- Aeth -->
|
74
81
|
<dependency>
|
75
82
|
<groupId>org.sonatype.aether</groupId>
|
@@ -137,8 +144,14 @@
|
|
137
144
|
<!-- Testing -->
|
138
145
|
<dependency>
|
139
146
|
<groupId>junit</groupId>
|
140
|
-
<artifactId>junit</artifactId>
|
141
|
-
<version>4.
|
147
|
+
<artifactId>junit-dep</artifactId>
|
148
|
+
<version>4.11</version>
|
149
|
+
<scope>test</scope>
|
150
|
+
</dependency>
|
151
|
+
<dependency>
|
152
|
+
<groupId>org.hamcrest</groupId>
|
153
|
+
<artifactId>hamcrest-all</artifactId>
|
154
|
+
<version>1.3</version>
|
142
155
|
<scope>test</scope>
|
143
156
|
</dependency>
|
144
157
|
|
@@ -204,6 +217,27 @@
|
|
204
217
|
</execution>
|
205
218
|
</executions>
|
206
219
|
</plugin>
|
220
|
+
<plugin>
|
221
|
+
<groupId>org.apache.maven.plugins</groupId>
|
222
|
+
<artifactId>maven-dependency-plugin</artifactId>
|
223
|
+
<executions>
|
224
|
+
<execution>
|
225
|
+
<id>copy-dependencies</id>
|
226
|
+
<phase>package</phase>
|
227
|
+
<goals>
|
228
|
+
<goal>copy-dependencies</goal>
|
229
|
+
</goals>
|
230
|
+
<configuration>
|
231
|
+
<outputDirectory>target/dependencies</outputDirectory>
|
232
|
+
<overWriteReleases>false</overWriteReleases>
|
233
|
+
<overWriteSnapshots>false</overWriteSnapshots>
|
234
|
+
<overWriteIfNewer>true</overWriteIfNewer>
|
235
|
+
<stripVersion>true</stripVersion>
|
236
|
+
</configuration>
|
237
|
+
</execution>
|
238
|
+
</executions>
|
239
|
+
</plugin>
|
240
|
+
|
207
241
|
</plugins>
|
208
242
|
</build>
|
209
243
|
|
metadata
CHANGED
@@ -2,14 +2,14 @@
|
|
2
2
|
name: naether
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.
|
5
|
+
version: 0.12.0
|
6
6
|
platform: java
|
7
7
|
authors:
|
8
8
|
- Michael Guymon
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-10-01 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rspec
|
@@ -186,7 +186,7 @@ files:
|
|
186
186
|
- README.md
|
187
187
|
- Rakefile
|
188
188
|
- VERSION
|
189
|
-
- core-0.
|
189
|
+
- core-0.12.0.jar
|
190
190
|
- doc/Naether.html
|
191
191
|
- doc/Naether/Bootstrap.html
|
192
192
|
- doc/Naether/Configurator.html
|
data/core-0.11.1.jar
DELETED
Binary file
|