ruboto 0.9.0.rc.0 → 0.9.0.rc.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,8 @@
1
- if `ant -version` !~ /version (\d+)\.(\d+)\.(\d+)/ || $1.to_i < 1 || ($1.to_i == 1 && $2.to_i < 8)
1
+ require 'rbconfig'
2
+
3
+ ANT_CMD = (RbConfig::CONFIG['host_os'] =~ /mswin|mingw/i) ? "ant.bat" : "ant"
4
+
5
+ if `#{ANT_CMD} -version` !~ /version (\d+)\.(\d+)\.(\d+)/ || $1.to_i < 1 || ($1.to_i == 1 && $2.to_i < 8)
2
6
  puts "ANT version 1.8.0 or later required. Version found: #{$1}.#{$2}.#{$3}"
3
7
  exit 1
4
8
  end
@@ -182,7 +186,7 @@ task :test => :uninstall do
182
186
  Dir.chdir('test') do
183
187
  puts 'Running tests'
184
188
  sh "adb uninstall #{package}.tests"
185
- sh "ant instrument install test"
189
+ sh "#{ANT_CMD} instrument install test"
186
190
  end
187
191
  end
188
192
 
@@ -190,9 +194,9 @@ namespace :test do
190
194
  task :quick => :update_scripts do
191
195
  Dir.chdir('test') do
192
196
  puts 'Running quick tests'
193
- sh 'ant instrument'
194
- sh 'ant installi'
195
- sh "ant run-tests-quick"
197
+ sh "#{ANT_CMD} instrument"
198
+ sh "#{ANT_CMD} installi"
199
+ sh "#{ANT_CMD} run-tests-quick"
196
200
  end
197
201
  end
198
202
  end
@@ -398,9 +402,9 @@ def build_apk(t, release)
398
402
  puts "Forcing rebuild of #{apk_file}."
399
403
  end
400
404
  if release
401
- sh 'ant release'
405
+ sh "#{ANT_CMD} release"
402
406
  else
403
- sh 'ant debug'
407
+ sh "#{ANT_CMD} debug"
404
408
  end
405
409
  return true
406
410
  end
@@ -365,7 +365,7 @@ module Ruboto
365
365
  update_core_classes "exclude"
366
366
  update_bundle
367
367
  when "jruby" then
368
- update_jruby(params['force'].value) || abort
368
+ update_jruby(params['force'].value, true) || abort
369
369
  # FIXME(uwe): Deprecated in Ruboto 0.8.1. Remove september 2013.
370
370
  when "ruboto" then
371
371
  puts "\nThe 'ruboto update ruboto' command has been deprecated. Use\n\n ruboto update app\n\ninstead.\n\n"
@@ -136,13 +136,13 @@ module Ruboto
136
136
  end
137
137
  end
138
138
 
139
- def update_jruby(force=nil)
139
+ def update_jruby(force=nil, explicit = false)
140
140
  jruby_core = Dir.glob("libs/jruby-core-*.jar")[0]
141
141
  jruby_stdlib = Dir.glob("libs/jruby-stdlib-*.jar")[0]
142
142
 
143
143
  unless force
144
144
  if !jruby_core || !jruby_stdlib
145
- puts "Cannot find existing jruby jars in libs. Make sure you're in the root directory of your app."
145
+ puts "Cannot find existing jruby jars in libs. Make sure you're in the root directory of your app." if explicit
146
146
  return false
147
147
  end
148
148
  end
@@ -184,6 +184,10 @@ module Ruboto
184
184
  end
185
185
 
186
186
  def update_dx_jar(force=nil)
187
+ # FIXME(uwe): Remove when we stop updating from Ruboto 0.8.1 and older.
188
+ FileUtils.rm(Dir['libs/dexmaker*.jar'])
189
+ # EMXIF
190
+
187
191
  jar_file = Dir.glob("libs/dx.jar")[0]
188
192
 
189
193
  # FIXME(uwe): Skip copying dx.jar to apps using RubotoCore when we include dx.jar in RubotoCore
@@ -1,4 +1,4 @@
1
1
  module Ruboto
2
- VERSION = '0.9.0.rc.0'
2
+ VERSION = '0.9.0.rc.1'
3
3
  UPDATE_VERSION_LIMIT = '0.5.2'
4
4
  end
@@ -23,12 +23,13 @@ test('stack depth') do |activity|
23
23
  jruby_offset = {
24
24
  '0.4.7' => [0, 0, 0, 0],
25
25
  '0.4.8.dev' => [0, 0, -4, -4],
26
+ '0.4.8' => [0, 0, -4, -4],
26
27
  }[org.ruboto.JRubyAdapter.platform_version_name] || [0, 0, 0, 0]
27
28
  else # STANDALONE
28
29
  jruby_offset = {
29
30
  '1.7.0.dev' => [1, 1, 1, 1],
30
31
  '1.7.0.preview2' => [0, 0, -4, -4],
31
- '1.7.0.rc1' => [0, 0, -4, -4],
32
+ '1.7.0.RC1' => [0, 0, -4, -4],
32
33
  }[org.jruby.runtime.Constants::VERSION] || [0, 0, 0, 0]
33
34
  end
34
35
  version_message ="ANDROID: #{android.os.Build::VERSION::SDK_INT}, PLATFORM: #{org.ruboto.JRubyAdapter.uses_platform_apk ? org.ruboto.JRubyAdapter.platform_version_name : 'STANDALONE'}, JRuby: #{org.jruby.runtime.Constants::VERSION}"
@@ -16,12 +16,13 @@ test('stack depth') do |activity|
16
16
  jruby_offset = {
17
17
  '0.4.7' => [0, 0, 0, 0],
18
18
  '0.4.8.dev' => [0, -1, 0, 0],
19
+ '0.4.8' => [0, -1, 0, 0],
19
20
  }[org.ruboto.JRubyAdapter.platform_version_name] || [0, 0, 0, 0]
20
21
  else # STANDALONE
21
22
  jruby_offset = {
22
23
  '1.7.0.preview1' => [0, -1, -1, -1],
23
24
  '1.7.0.preview2' => [0, -1, 0, 0],
24
- '1.7.0.rc1' => [0, -1, 0, 0],
25
+ '1.7.0.RC1' => [0, -1, 0, 0],
25
26
  }[org.jruby.runtime.Constants::VERSION] || [0, 0, 0, 0]
26
27
  end
27
28
  version_message ="ANDROID: #{android.os.Build::VERSION::SDK_INT}, PLATFORM: #{org.ruboto.JRubyAdapter.uses_platform_apk ? org.ruboto.JRubyAdapter.platform_version_name : 'STANDALONE'}, JRuby: #{org.jruby.runtime.Constants::VERSION}"
@@ -21,13 +21,14 @@ test('stack depth') do |activity|
21
21
  jruby_offset = {
22
22
  '0.4.7' => [0, 0, 0, 0],
23
23
  '0.4.8.dev' => [0, -1, -1, -1],
24
+ '0.4.8' => [0, -1, -1, -1],
24
25
  }[org.ruboto.JRubyAdapter.platform_version_name] || [0, 0, 0, 0]
25
26
  else # STANDALONE
26
27
  jruby_offset = {
27
28
  '1.7.0.dev' => [1, 0, 0, 0],
28
29
  '1.7.0.preview1' => [0, -1, -1, -1],
29
30
  '1.7.0.preview2' => [0, -1, -1, -1],
30
- '1.7.0.rc1' => [0, -1, -1, -1],
31
+ '1.7.0.RC1' => [0, -1, -1, -1],
31
32
  }[org.jruby.runtime.Constants::VERSION] || [0, 0, 0, 0]
32
33
  end
33
34
  version_message ="ANDROID: #{android.os.Build::VERSION::SDK_INT}, PLATFORM: #{org.ruboto.JRubyAdapter.uses_platform_apk ? org.ruboto.JRubyAdapter.platform_version_name : 'STANDALONE'}, JRuby: #{org.jruby.runtime.Constants::VERSION}"
@@ -29,4 +29,12 @@ module UpdatedExampleTestMethods
29
29
  end
30
30
  end
31
31
 
32
+ # FIXME(uwe): Remove when we stop updating from Ruboto 0.8.1 and older.
33
+ def test_dexmaker_jar_is_removed
34
+ Dir.chdir APP_DIR do
35
+ assert_equal [], Dir['libs/dexmaker*.jar']
36
+ end
37
+ end
38
+ # EMXIF
39
+
32
40
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruboto
3
3
  version: !ruby/object:Gem::Version
4
- hash: 752453167
4
+ hash: -3487987620
5
5
  prerelease: 6
6
6
  segments:
7
7
  - 0
8
8
  - 9
9
9
  - 0
10
10
  - rc
11
- - 0
12
- version: 0.9.0.rc.0
11
+ - 1
12
+ version: 0.9.0.rc.1
13
13
  platform: ruby
14
14
  authors:
15
15
  - Daniel Jackoway
@@ -20,7 +20,7 @@ autorequire:
20
20
  bindir: bin
21
21
  cert_chain: []
22
22
 
23
- date: 2012-09-28 00:00:00 Z
23
+ date: 2012-09-29 00:00:00 Z
24
24
  dependencies:
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: main