Skip to content

Commit

Permalink
copy the app from the Applications subdirectory if not found at the r…
Browse files Browse the repository at this point in the history
…oot of the build dir

situation encountered while frankifying an app built with cocoapods
  • Loading branch information
alexnauda committed Dec 20, 2013
1 parent 0bc4aab commit a579fd8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions gem/lib/frank-cucumber/cli.rb
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,12 @@ def build(*args)
exit $?.exitstatus if not $?.success?

app = Dir.glob("#{build_output_dir}/*.app").delete_if { |x| x =~ /\/#{app_bundle_name}$/ }

# when building with Cocoapods, the app is built in an "Applications" subdirectory
if app.empty?
app = Dir.glob("#{build_output_dir}/Applications/*.app").delete_if { |x| x =~ /\/#{app_bundle_name}$/ }
end

app = app.first
FileUtils.cp_r("#{app}/.", frankified_app_dir)

Expand Down

0 comments on commit a579fd8

Please sign in to comment.