Knowledgebase

Managing Xcode Projects and Targets Print

  • appletechnology, apple, woocommerce, guide, howto, solution, zillionkinghost, hosting
  • 0

Structuring a project.

WHAT A TARGET PRODUCES

One build product: an application, a framework, an extension, a test bundle.

WHAT TO SEPARATE INTO TARGETS

Extensions, which are separate executables Shared code, as a framework or package Tests

WHAT BUILD SETTINGS CONTROL

Almost everything about compilation and packaging.

WHERE THEY CAN BE SET

At project level, target level, and through configuration files.

WHAT TO PREFER

Configuration files, held in version control.

WHY

Settings buried in the project file are hard to review and cause conflicts.

WHAT CAUSES MERGE CONFLICTS

The project file, which is a single file every change touches.

WHAT REDUCES THEM

Moving settings into configuration files Using package-based dependencies Smaller, more frequent changes

WHAT TO KEEP CONSISTENT

The deployment target across targets Swift language version Signing configuration

WHAT TO AVOID

Hard-coded paths Settings that differ between developers' machines Manual steps required to build

WHAT TO VERIFY

That a clean checkout builds without manual intervention.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot