Open tstephansen opened 1 month ago
I'm glad I'm not the only one who discovered this and realized this yesterday when I noticed all my provisioning profiles weren't showing up.
Hey, thanks for the notice, i will deliver an update in the following days.
Hi @banditoth, would you have to know when the update regarding Xcode 16 provisioning profiles will be released?
If you don't want to wait for the fix, here is how you can patch your local installation:
~/.vscode/extensions/banditoth.vscode-maui-archive-1.1.2/Platforms/iOSFeatures.js
const provisioningProfilesPath = path.join(process.env.HOME, 'Library', 'MobileDevice', 'Provisioning Profiles');
const provisioningProfilesPath = path.join(process.env.HOME, 'Library', 'Developer','Xcode', 'UserData', 'Provisioning Profiles');
This works for me, but when I actually try to build a development build to my local device I get a /tools/msbuild/iOS/Xamarin.Shared.targets(1725,3): error : Could not find any available provisioning profiles for [MY APP] on iOS. error. Am I supposed to be building a different way than just pressing the Play button in VS Code since I'm using this extension?
Hi @banditoth, would you have to know when the update regarding Xcode 16 provisioning profiles will be released?
Hey, I will release a version with configurable path for this tomorrow.
This works for me, but when I actually try to build a development build to my local device I get a /tools/msbuild/iOS/Xamarin.Shared.targets(1725,3): error : Could not find any available provisioning profiles for [MY APP] on iOS. error. Am I supposed to be building a different way than just pressing the Play button in VS Code since I'm using this extension?
It has nothing to do with this extension, but I recommend you to check your provisioning profiles are valid, and downloaded to your machine (in XCode)
If you don't want to wait for the fix, here is how you can patch your local installation:
- Close VSCode
- Edit the file
~/.vscode/extensions/banditoth.vscode-maui-archive-1.1.2/Platforms/iOSFeatures.js
- Line 46 reads:
const provisioningProfilesPath = path.join(process.env.HOME, 'Library', 'MobileDevice', 'Provisioning Profiles');
- Replace it with:
const provisioningProfilesPath = path.join(process.env.HOME, 'Library', 'Developer','Xcode', 'UserData', 'Provisioning Profiles');
Thanks for this workaround!
Rolled out an update with version 1.1.3. Thats a pre-release version. Since I do not have provisioning profiles somehow in the mentioned directory, and even if I copy from the old directory it gets deleted, I can not validate this now back.
Could you check up on it for me?
Thanks in advance, bandi
Could you check up on it for me?
Hey thanks, yes it does work. But I'm afraid it won't for those developers out there that still stick to the old (<v16) OS and Xcode version, which will cause trouble for you (having to tell them they must set the new extension property to the old path). So to prevent this, you might either check the current Xcode version or check if the new folder path.join(process.env.HOME, 'Library', 'Developer','Xcode', 'UserData', 'Provisioning Profiles') exists and actually does contain files and - if not - automatically fall back to the old one: path.join(process.env.HOME, 'Library', 'MobileDevice', 'Provisioning Profiles'). I don't think the user has any option to decide where those provisioning profiles should be stored. I guess it is dictated by the system, so making it freely configurable can only cause problems with users entering the wrong path there. If you really prefer introducing an extension property, make sure the description tells the user exactly what to do. Currently: "description": "Set a custom directory where your iOS Provisioning Profiles are located at. Leave blank for default. (Developer/XCode/UserData/ProvisioningProfiles)" Better: "description": "Set the directory where your iOS Provisioning Profiles are located. Leave blank for Xcode 16 or later. or set it to '/Users/[YOUR USERNAME]/Library/MobileDevice/Provisioning Profiles' for older Xcode versions" Thanks for your work anyway. I just had to move from Visual Studio to VSC to build my app for iOS and was happy to find your extension to streamline the release workflow.
The provisioning profiles folder has changed from ~/Library/MobileDevice/Provisioning Profiles to ~/Library/Developer/Xcode/UserData/Provisioning Profiles. I found this out today when I went to clear out my profiles. I removed them from the old location and when I went in Xcode to redownload them the folder was empty. I think this is why the extension won't find any profiles installed on my system. When I copied the profiles from the new location to the old the extension was able to find them.
It may be a good idea to update the extension to look for profiles in both locations going forward. I made these changes in my fork to make sure that it worked.