As of iOS 13, SimulatorStatusMagic no longer works, but happily Apple have provided a first-party solution through simctl status_bar
.
However I can't find any way to remove or change the "Carrier" text:
Setting --cellularMode notSupported
removes it, but it also removes the cellular bars.
Is there any way to reproduce the previous functionality of SimulatorStatusMagic and remove or change just the carrier name?
Edit: Xcode 11.4 includes a new parameter to set the operator name, though it doesn't seem to work. The documentation provides the following:
--operatorName <string>
Set the cellular operator/carrier name. Use '' for the empty string.
xcrun simctl is command utils to control iOS simulator, just like adb for Android. Sometimes, in CI server script, We need these simulator-integration command to interact with simulators and run test cases. If we run xcrun simctl help , here are some subcommands.
There are two different ways to access Simulator through Xcode. The first way is to run your app in Simulator, and the second way is to launch Simulator without running an app.
The basic way to open a list of simulators is to use Xcode -> Window -> Devices and Simulators.
I was able to remove the carrier name by passing not an empty string to operatorName
but a string with just a space ' '
However, using operatorName
alone will not have any effect. You also need to activate cellularMode
.
For Example
xcrun simctl status_bar "iPhone 8 Plus" override --operatorName ' '
gives this result
whereas
xcrun simctl status_bar "iPhone 8 Plus" override --operatorName ' ' --cellularMode active
results in this
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With