calabash-cucumber 0.9.140.pre1 → 0.9.140.pre2
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +27 -28
- data/lib/calabash-cucumber/version.rb +1 -1
- metadata +1 -1
data/Rakefile
CHANGED
@@ -11,44 +11,43 @@ task :build_server do
|
|
11
11
|
|
12
12
|
def build_server
|
13
13
|
return if ENV['SKIP_SERVER']
|
14
|
-
|
15
|
-
|
16
|
-
unless
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
Please checkout as #{dir} or set CALABASH_SERVER_PATH to point
|
22
|
-
to Calabash server (branch 0.9.x).
|
14
|
+
framework_zip = nil
|
15
|
+
dir = ENV['CALABASH_SERVER_PATH'] || File.join('..', '..', 'calabash-ios-server')
|
16
|
+
unless File.exist?(dir)
|
17
|
+
raise <<EOF
|
18
|
+
Unable to find calabash server checked out at #{dir}.
|
19
|
+
Please checkout as #{dir} or set CALABASH_SERVER_PATH to point
|
20
|
+
to Calabash server (branch 0.9.x).
|
23
21
|
EOF
|
22
|
+
end
|
23
|
+
|
24
|
+
FileUtils.cd(dir) do
|
25
|
+
puts 'Building Server'
|
26
|
+
cmd = 'xcodebuild build -project calabash.xcodeproj -target Framework -configuration Debug -sdk iphonesimulator6.1'
|
27
|
+
puts cmd
|
28
|
+
puts `#{cmd}`
|
29
|
+
|
30
|
+
unless File.exist?(FRAMEWORK)
|
31
|
+
raise 'Unable to build framework'
|
24
32
|
end
|
25
33
|
|
26
|
-
|
27
|
-
puts 'Building Server'
|
28
|
-
cmd = 'xcodebuild build -project calabash.xcodeproj -target Framework -configuration Debug -sdk iphonesimulator6.1'
|
29
|
-
puts cmd
|
30
|
-
puts `#{cmd}`
|
34
|
+
puts "Zipping down framework"
|
31
35
|
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
+
|
37
|
+
zip_cmd = "zip -q -r #{ZIP_FILE} #{FRAMEWORK}"
|
38
|
+
puts zip_cmd
|
39
|
+
puts `#{zip_cmd}`
|
40
|
+
framework_zip = File.expand_path(ZIP_FILE)
|
41
|
+
unless File.exist?(framework_zip)
|
42
|
+
raise 'Unable to zip down framework...'
|
36
43
|
end
|
37
44
|
end
|
38
45
|
|
39
|
-
|
46
|
+
|
40
47
|
|
41
48
|
FileUtils.mkdir_p('staticlib')
|
42
49
|
output_path = File.join('staticlib', ZIP_FILE)
|
43
|
-
|
44
|
-
zip_cmd = "zip -q -r #{output_path} #{framework_path}"
|
45
|
-
puts zip_cmd
|
46
|
-
puts `#{zip_cmd}`
|
47
|
-
|
48
|
-
unless File.exist?(output_path)
|
49
|
-
raise 'Unable to zip down framework...'
|
50
|
-
end
|
51
|
-
|
50
|
+
FileUtils.mv(framework_zip,output_path, :force => true)
|
52
51
|
puts "Server built to path #{output_path}"
|
53
52
|
|
54
53
|
end
|