How to read current app version in Xcode 11 with script

前端 未结 9 1753
野趣味
野趣味 2020-12-14 00:38

Until Xcode 11, I used a script that reads the current app version (for the AppStore) and help me change the LaunchScreen since we can\'t use swift for that

9条回答
  •  一生所求
    2020-12-14 01:08

    How about saving a value to CURRENT_PROJECT_VERSION ? did anyone managed to do this?

    I can get the value like

    buildNumber=$CURRENT_PROJECT_VERSION
    

    but this doesn't work:

    CURRENT_PROJECT_VERSION=""    or   $CURRENT_PROJECT_VERSION=""
    

    In my case I'm trying to set it to ""

    This line doesn't set the CURRENT_PROJECT_VERSION field too

    /usr/libexec/PlistBuddy -c "Set :CFBundleVersion $buildNumber" "$appInfoPlist"
    

提交回复
热议问题