Xcode 14 -How to Open Custom iOS Target Properties (info.plist) as Source Code? - xcode

How can I open Custom iOS Target Properties as Source Code? I want to c+p items there.
I'm using Xcode 14 and I have a bunch of SKAdNetowrkItems that I need to add. When I'm in the navigator -> open info.plist as Source Code -> manually add all of the items, it's there.
But when I check in Custom iOS Target Properties the SKAdNetowrkItems doesn't appear so they aren't synced

Related

How to prevent (and recover from) Xcode 12 NoBuildableEntriesError errors?

Sometimes when I reopen an existing Swift UI project in Xcode 12, the component preview pane fails to display previews of components and displays the following error message instead:
NoBuildableEntriesError: active scheme does not build this file
Select a scheme that builds a target which contains the current file,
or add this file to a target that is built by the current scheme.
How can I resolve this and prevent it from happening again?
In particular, how can I:
"select a scheme that builds a target which contains the current file", and/or
"add this file to a target that is built by the current scheme."
Below is the Scheme it is at the very top of Xcode you can click it to change it.
And the membership is in the file inspector. Just click the Target you want.
My CustomPicker.swift files does NOT belong to StackOverflow14-Multi (macOS)

Add target to iOS/macOS Multi-Platform Project (Xcode 12)

Xcode 12 (Beta) introduced the new multi-platform project template for iOS/macOS apps. If I add a new target (File -> New -> Target... -> Watch App), Xcode adds a new app project to the existing one.
My preference is, that the watchOS-Project uses the shared folder, like the iOS and macOS app.
My question is, how to integrate another app project, like watchOS or tvOS, to an existing multi-platform project? As a reference, I found a GitHub-Project, which integrated watchOS and tvOS in a multi-platform project: https://github.com/jordansinger/SwiftUI-Kit
I also struggled adding an new target for an additional platform. I ended up doing it like this:
Create new project for iOS platform and name it "iOS"
Rename project (first file in the file list) to your product name. Xcode will ask you if you want to rename all other project files -> click on "Don't rename"
While the project file is still selected, you see a column with the targets. Click on the "+" on the bottom and select the app template for an other platform (e.g. tvOS). Set the product name to "tvOS" and click on "Finish".
Add more platforms if needed.
Go through all targets and change the Bundle Identifier for each of them to the correct product name.
Create the following folders by right-clicking on the project file and choosing "New Group": Shared, Shared Tests, Shared UITests.
Now you move the files you want to share between all platforms from one of the platform folders to the "Shared" folder (e.g. ContentView.swift). Delete all those files from the other platforms folders.
Go through all the files in the "Shared" folder and select the other platforms under "Target Membership":
9. Do the same for the Tests und UITests
It's cumbersome, but it works. Maybe somebody else finds a better way...

Edit GUI without using base internationalization

I set my Xcode 5 project to use a build target of OSX 10.6, unchecked "Use Autolayout" for MainMenu.xib and followed this answer to turn off base internationalization. This resulted in my MainMenu.xib file being removed from my project. When I build and run my project the window layout is how I left it, but going into finder, opening MainMenu.xib in Interface Builder and changing it's layout does not effect my project when I go to build and run it again.
How do I change the GUI for projects set to a build target of 10.6?
Can be added again to the project by:
Drag MainMenu.xib from Finder to the project files panel in Xcode.
A dialog will open, select copy items (if needed), created folder references, and add to the project's target (not "test"), click Finish and it should work!
If a more complete answer is added, I will best answer it instead of my own.

How to add localization language to Xcode 4.4?

In reference to this guide:
How to localize my app with Xcode 4?
I noticed that under Localization, my Xcode 4.4 shows no [+] button:
How can I add languages to the Localization list?
Note: I'm not using IB. I purely need a localized strings file with translated strings for a game.
My workaround so far: I created the de.lproj folders manually, copied the strings file into de.lproj, added it to Xcode and Xcode did recognize the file as german. Xcode also added German to the Localization list. I'm wondering if there is an easier way to do this (from within Xcode) instead of copying & adding the files manually?
Select your project from the project navigator to open the project editor. Select your project from the left side of the project editor. Click the Info button at the top of the editor. You should see a list of localizations along with a button to add a localization. Click the Add button and choose a language. A sheet will open that lets you choose what files to localize.

Settings.bundle is missing Root.plist and other items in iOS project;

I'm using xcode Version 4.2 (Build 4C199) with iOS 5.0.
I'm following the Apple's documentation at:
http://developer.apple.com/library/ios/#documentation/cocoa/Conceptual/UserDefaults/Preferences/Preferences.html
When I tried to add Settings.bundle, described under "Adding the Settings Bundle" section, I'm not getting all files under this bundle; Like after adding this bundle, I had only Settings.bundle at root of my project and there isn't any Root.plist and en.lproj etc;
Screenshot of my project:
So after reading some other questions here, I found that I have to right click on settings bundle icon -> show in finder -> right click on finder item -> show package content; Now I can view Root.plist and other items; But my question is is there a way to view the hierarchy of Settings.bundle inside xcode project navigator?
The next query is how can I add Child plists under Settings.bundle? As right now I'm unable to expand Settings.bundle in my project navigator;
Open the package in Finder. Drag the files into the project file list (but make sure that you remove them from all build phases)

Resources