iconsplistapple-watchwatchos-2

Adding App Icon to WatchOS App info.plist


I am trying to add App Icons to my WatchOS app but need to do this in the Info.plist as I am building the project through the NativeScript CLI.

I have all the watch icons stored in AppIcon.appiconset inside Images.xcassets. I am unsure of how to do this and have looked around but found no solution, any help is greatly appreciated!


Solution

  • In NativeScript you must add this to your watchapp.json that you create with the watch app. I realised that our .gitignore included all json files so when I've recloned the repo it has deleted the files.

    Make sure the json files for the appiconset are also on your repo or you will have unassigned children warning.

    watchapp.json (lives inside your WatchOS folder)

    {
      "assetcatalogCompilerAppiconName": "WatchAppIcon",
      "targetBuildConfigurationProperties": {
        "WATCHOS_DEPLOYMENT_TARGET": 5.3,
        "LD": "\"\""
      }
    }
    

    extension.json (lives inside your WatchOS Extensions folder)

    {
      "targetBuildConfigurationProperties": {
        "WATCHOS_DEPLOYMENT_TARGET": 5.3,
        "LD": "\"\""
      }
    }
    

    You would also add your developer team in these json files.