naether 0.5.0-java → 0.5.1-java

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.0
1
+ 0.5.1
@@ -69,29 +69,31 @@ class Naether
69
69
 
70
70
  deps[:downloaded] = []
71
71
 
72
- puts "Downloading jars for Naether"
73
-
74
- deps[:missing].each do |dep|
75
- notation = dep.split(":")
76
- group = notation[0].gsub("\.", File::SEPARATOR)
77
- artifact = notation[1]
78
- type = notation[2]
79
- version = notation[3]
80
-
81
- jar = "#{artifact}-#{version}.#{type}"
82
-
83
- maven_path = "#{dest}#{File::SEPARATOR}#{jar}"
84
-
85
- if !File.exists? maven_path
86
- maven_mirror = "http://repo1.maven.org/maven2/#{group}/#{artifact}/#{version}/#{jar}"
72
+ if deps[:missing].size > 0
73
+ puts "Downloading jars for Naether"
87
74
 
88
- open(maven_path, 'wb') do |io|
89
- io.print open(maven_mirror).read
90
- end
75
+ deps[:missing].each do |dep|
76
+ notation = dep.split(":")
77
+ group = notation[0].gsub("\.", File::SEPARATOR)
78
+ artifact = notation[1]
79
+ type = notation[2]
80
+ version = notation[3]
91
81
 
92
- deps[:downloaded] << { dep => maven_path }
93
- else
94
- deps[:exists] << maven_path
82
+ jar = "#{artifact}-#{version}.#{type}"
83
+
84
+ maven_path = "#{dest}#{File::SEPARATOR}#{jar}"
85
+
86
+ if !File.exists? maven_path
87
+ maven_mirror = "http://repo1.maven.org/maven2/#{group}/#{artifact}/#{version}/#{jar}"
88
+
89
+ open(maven_path, 'wb') do |io|
90
+ io.print open(maven_mirror).read
91
+ end
92
+
93
+ deps[:downloaded] << { dep => maven_path }
94
+ else
95
+ deps[:exists] << { dep => maven_path }
96
+ end
95
97
  end
96
98
  end
97
99
 
@@ -120,7 +122,7 @@ class Naether
120
122
  maven_path = "#{local_repo}#{File::SEPARATOR}#{group}#{File::SEPARATOR}#{artifact}#{File::SEPARATOR}#{version}#{File::SEPARATOR}#{jar}"
121
123
 
122
124
  if File.exists? maven_path
123
- deps[:exists] << dep
125
+ deps[:exists] << { dep => maven_path }
124
126
  else
125
127
  deps[:missing] << dep
126
128
  end
@@ -131,8 +133,6 @@ class Naether
131
133
  end
132
134
 
133
135
  def install_dependencies_to_local_repo( jars_or_dir, opts = {} )
134
-
135
- deps = check_local_repo_for_deps(opts[:local_repo])
136
136
 
137
137
  @naether = nil
138
138
  jars = []
data/lib/naether.rb CHANGED
@@ -12,6 +12,7 @@ class Naether
12
12
 
13
13
  # Naether jar path will default to packaged in the gem
14
14
  JAR_LIB = "#{File.dirname(__FILE__)}/.."
15
+ JAR_PATH = "#{JAR_LIB}/naether-0.5.1.jar" #XXX: hardcoded, should be based on VERSION file
15
16
 
16
17
  class << self
17
18
 
data/pom.xml CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  <groupId>com.slackworks</groupId>
6
6
  <artifactId>naether</artifactId>
7
- <version>0.5.0</version>
7
+ <version>0.5.1</version>
8
8
  <packaging>jar</packaging>
9
9
  <name>naether</name>
10
10
  <url>https://github.com/mguymon/naether</url>
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: naether
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.5.0
5
+ version: 0.5.1
6
6
  platform: java
7
7
  authors:
8
8
  - Michael Guymon
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-11-20 00:00:00 -05:00
13
+ date: 2011-11-21 00:00:00 -05:00
14
14
  default_executable:
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
@@ -74,7 +74,7 @@ files:
74
74
  - lib/naether.rb
75
75
  - lib/naether/bootstrap.rb
76
76
  - lib/naether/java.rb
77
- - naether-0.5.0.jar
77
+ - naether-0.5.1.jar
78
78
  - pom.xml
79
79
  has_rdoc: true
80
80
  homepage: http://github.com/mguymon/naether