【问题标题】:How to get the version of the app installed in the simulator from terminal如何从终端获取安装在模拟器中的应用程序版本
【发布时间】:2020-10-15 14:26:39
【问题描述】:

是否有命令可以获取安装在模拟器中的应用程序版本,我正在寻找任何 xcode 命令或任何其他可以获取应用程序版本的命令

【问题讨论】:

    标签: swift xcode appium appium-ios xcrun


    【解决方案1】:

    让我们试试:

    defaults read $(xcrun simctl get_app_container booted your.app.bundle.identifier)/Info CFBundleVersion
    

    【讨论】:

    • 我运行成功了,你运行了多少模拟器?
    • 你可以先尝试运行子命令:xcrun simctl get_app_container booted your.app.bundle.identifier
    • 记得把 your.app.bundle.identifier 改成你的
    • 只有 1 个模拟器正在运行,我已经替换了捆绑包 ID:(xcrun simctl get_app_container booted myBundleId)/Info CFBundleVersion。我正在使用这个命令,请检查我是否遗漏了什么?
    • 如果您的应用名称包含空格,请务必使用引号defaults read "$(xcrun simctl get_app_container booted your.app.bundle.identifier)"/Info
    猜你喜欢
    • 2011-07-14
    • 2014-07-16
    • 2016-01-30
    • 2016-08-14
    • 1970-01-01
    • 2012-12-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多