Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
9ecf4c74
Commit
9ecf4c74
authored
Jun 18, 2013
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Rakefile] Examples robustness for future versions of Xcode
parent
efdedaa6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
5 deletions
+13
-5
Rakefile
Rakefile
+13
-5
No files found.
Rakefile
View file @
9ecf4c74
...
...
@@ -329,11 +329,18 @@ namespace :examples do
execute_command
"rm -rf Pods DerivedData"
execute_command
"
#{
'../../bin/'
unless
ENV
[
'FROM_GEM'
]
}
sandbox-pod install --verbose --no-repo-update"
command
=
"xcodebuild -workspace '
#{
example
.
basename
}
.xcworkspace' -scheme '
#{
example
.
basename
}
'"
if
(
example
+
'Podfile'
).
read
.
include?
(
'platform :ios'
)
# Specifically build against the simulator SDK so we don't have to deal with code signing.
command
<<
" -sdk "
command
<<
Dir
.
glob
(
"
#{
`xcode-select -print-path`
.
chomp
}
/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator*.sdk"
).
last
end
if
(
example
+
'Podfile'
).
read
.
include?
(
'platform :ios'
)
# Specifically build against the simulator SDK so we don't have to deal with code signing.
xcode_version
=
`xcodebuild -version`
.
scan
(
/Xcode (.*)\n/
).
first
.
first
major_version
=
xcode_version
.
split
(
'.'
).
first
.
to_i
destination_flag_supported
=
major_version
>
4
if
destination_flag_supported
command
<<
" -destination 'platform=iOS Simulator,name=iPhone'"
else
command
<<
" -sdk "
command
<<
Dir
.
glob
(
"
#{
`xcode-select -print-path`
.
chomp
}
/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator*.sdk"
).
last
end
end
execute_command
(
command
)
end
end
...
...
@@ -379,3 +386,4 @@ def title(title)
puts
"-"
*
80
puts
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment