summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobby Russell <robby@planetargon.com>2014-11-06 09:13:40 -0800
committerRobby Russell <robby@planetargon.com>2014-11-06 09:13:40 -0800
commit548b9c447da5edad36a9a0b9c1174fb29230e018 (patch)
tree6acc5e29a1618405e640526c9335df1ad91ccb64
parentba6bf248b49b3b2f5405b6841b1392e44afc28ba (diff)
parent071de5fb39ff951bffe75a4d6f590d85f25871f3 (diff)
downloadzsh-548b9c447da5edad36a9a0b9c1174fb29230e018.tar.gz
zsh-548b9c447da5edad36a9a0b9c1174fb29230e018.tar.bz2
zsh-548b9c447da5edad36a9a0b9c1174fb29230e018.zip
Merge pull request #3224 from Neal/xcode-simulator-fix
Update path for the iOS simulator.
-rw-r--r--plugins/xcode/xcode.plugin.zsh7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/xcode/xcode.plugin.zsh b/plugins/xcode/xcode.plugin.zsh
index e59bee8c7..b7b75cf93 100644
--- a/plugins/xcode/xcode.plugin.zsh
+++ b/plugins/xcode/xcode.plugin.zsh
@@ -16,4 +16,9 @@ function xcsel {
alias xcb='xcodebuild'
alias xcp='xcode-select --print-path'
-alias simulator='open $(xcode-select -p)/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app'
+
+if [[ -d $(xcode-select -p)/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app ]]; then
+ alias simulator='open $(xcode-select -p)/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app'
+else
+ alias simulator='open $(xcode-select -p)/Applications/iOS\ Simulator.app'
+fi