Questions tagged [xcrun]

xcrun provides to locate or invoke ios developer tools from the command-line to support multiple Xcode tool chains.

xcrun provides a means to locate or invoke developer tools from the command-line, without requiring users to modify Makefiles or otherwise take inconvenient measures to support multiple Xcode tool chains. The tool xcode-select is used to set a system default for the active developer directory, and may be overridden by the DEVELOPER_DIR environment variable (see ENVIRONMENT). The SDK which will be searched defaults to the boot system OS SDK, and can be specified by the SDK-ROOT SDKROOT ROOT environment variable or the --sdk option (which takes precedences over SDKROOT). When used to invoke another tool (as opposed to simply finding it), xcrun will provide the absolute path to the selected SDK in the SDKROOT environment variable. See ENVIRONMENT for more information.

153 questions
4
votes
1 answer

iOS code coverage report contains files that shouldn't be in there

I have an Xcode project with two targets - the main target where the source code lives (let's call it CoolApp), and a test target for the unit tests (let's call it CoolAppTests). I also have a Git commit hook that ensures I can't commit a change if…
RuslanD
  • 295
  • 3
  • 12
4
votes
2 answers

Command line created and installed iOS .app crashes when booting inside the simulator

I'm in the middle of some proof of concept test of mine, using xcodebuild and xcrun in order to create and deploy an .app onto my ios Simulators (or even to deliver the .app directory to my final client). Whatever, the thing is I deal sucessfully…
Isaac
  • 1,794
  • 4
  • 21
  • 41
4
votes
1 answer

xcrun: Is there a way to set environment variable via "xcrun simctl" cli

I am looking for a way to set environment while using xcrun. We could set environment via xcrun simctl setenv prior to Xcode 7.0. Now we can only view environment using xcrun simctl getenv . I have seen a reference of…
RKS
  • 1,333
  • 2
  • 12
  • 12
4
votes
4 answers

How to specify app id when upload to iTunesConnect using command line

Summary I`m trying to automatize my applications upload to iTunesConnect. I have at least 6 apps and all are always "ready to upload". The problem is when I try to upload an app to iTunesConnect using command line, I have the following error…
4
votes
1 answer

Xcrun is not embedding passed provisioning profile

I have "myApp.app" package that was build using command line. This app package contains distribution profile inside. Now, I need to make separate ipa package for testing (sign with development profile) so I'm executing xcrun command: /usr/bin/xcrun…
Centurion
  • 14,106
  • 31
  • 105
  • 197
4
votes
2 answers

Distribute ipa to iTunes connect from command line

I have several iPhone apps, and I've set out to do away with as much of the clicking around on iTunes connect that I have to do. One thing that I'd like to do is be able to upload an ipa to iTunes connect through the command line. How To Perform…
marklar
  • 502
  • 7
  • 21
4
votes
0 answers

Continuous Integration Code Signing issue

I've been working on setting up a TeamCity continuous integration build agent for my iOS builds and I've run into a bit of a road block. We're going to be making builds for different clients with different certificates and mobile provisioning…
Jose Ibanez
  • 3,325
  • 3
  • 28
  • 33
3
votes
0 answers

How to install *.app file to real device by script?

Get device list xcrun xctrace list devices => 'Simson’s iPhone 11 (14.4.2) (00008030-00122CD62291802E)' Install app file xcrun simctl install 00008030-00122CD62291802E app/ios/test.app Then I get error: stderr: 'Invalid device:…
Tuan Nguyen
  • 2,542
  • 19
  • 29
3
votes
2 answers

get output from xcrun xctrace list devices

On a jenkins pipeline, I execute: def devicesText = sh(script: "xcrun xctrace list devices", returnStdout: true) printf devicesText which has strange behaviour, since it prints the output on the console but does not save the output in the variable.…
Daniel
  • 20,420
  • 10
  • 92
  • 149
3
votes
1 answer

xcrun simctl status_bar not working in xcode 12

I have just upgraded my Xcode to 12 beta. I have tried to override the status bar on the simulator using this command: xcrun simctl status_bar 52B135BF-F549-4684-A959-914499AB3296 override --time '9:41' --batteryState charged --batteryLevel…
Kelvin Tan
  • 982
  • 1
  • 12
  • 33
3
votes
0 answers

Error: code 1091 Invalid Code Signing Entitlements 'com.apple.security.app-sandbox'

I'm trying to upload an app built with Unity on MacOs to AppStoreConnect, and I get this error when validating the .pkg file with xcrun altool --validate-app Error: code 1091 (App Store operation failed. Invalid Code Signing Entitlements. Your…
3
votes
1 answer

Is it possible to interact with cloned iOS simulators via xcrun simctl?

When I'm running UI tests in parallel on multiple simulators, the cloned simulators appear to be totally invisible to xcrun simctl. When running xcrun simctl list, the source simulator appears, but is in a "shutdown" state: 4 Inch Snapshots - en-US…
Chris Vasselli
  • 13,064
  • 4
  • 46
  • 49
3
votes
1 answer

iOS simulators boot, but don't appear, with "xcrun simctl boot ${UUID}"

I run this script #!/usr/bin/env bash device1="B13D4F22-AA4E-4890-8C2B-3C5B7B6E3678" device2="5E2588E9-38B5-48AF-99C5-DEE8A1E6FDA0" device3="2C28BD02-18BE-4FC5-94DE-075880E70E60" device4="723705CD-B038-44E0-B42E-F1D29A28E85E" xcrun simctl boot…
the_prole
  • 8,275
  • 16
  • 78
  • 163
3
votes
0 answers

simctl recordVideo - problem streaming the video

I want to be able to stream the booted simulator's screen to a video output. I know that simctl has a recordVideo option that supports streaming. I've tried the following command: xcrun simctl io DEVICE_ID recordVideo --type=fmp4…
Chris
  • 7,830
  • 6
  • 38
  • 72
3
votes
0 answers

how to use xcrun simctl io to pipe and record an iOS audio stream

My iOS app writes a stereo audio stream into a circular buffer at 44.1KHz and outputs successfully to either simulator or iOS device. I want to capture the audio stream while the app is running in Xcode and do it without altering the code or…
Greg
  • 1,750
  • 2
  • 29
  • 56