Process automatisation of Xcode new target creation

M.A. Zhurba, I.V. Stetsenko

Abstract


We live in the era of the Internet and technology. Now it is important for a person to be able to do their routine, uninteresting things quickly, and to be able to focus on more professional things. Everyone wants to minimize the time spent searching for information and have all services in one place.

Due to these desires, significant progress is being made in the development of mobile applications. A number of factors also contribute to this. First, the development of the hardware of pocket-sized devices reaches a level sufficient for complex computing tasks. Secondly, the speed of Internet communication has increased. Third, almost everyone in the world now has a smartphone, so it is much more profitable for businesses to develop mobile applications to reach a wider audience. The development of applications for mobile devices is becoming more and more popular, but at the same time more expensive. In some cases, a business needs to have a number of similar applications for one reason or another. There are several approaches to code reuse in the context of iOS development. One is to use a common codebase and separate Xcode targets for each product. The process of creating a new target requires a number of routine operations, which require the programmer’s time, and writing code is potentially error-prone. This research proposes to improve this approach by using scripts to generate a project file based on given configurations. A console script for generating a project file and a project to illustrate the approach have been developed.

Prombles in programming 2023; 1: 11-18

 


Keywords


Xcode target; Xcode project; mobile application; script; file generation; automatisation

References


iOS : How to create two versions of your app with a single codebase [Online] – Available from: https://anutoshdatta.medium.com/ios- how-to-create-two-versions-of-your-app-with- a-single-codebase-eca0bb75b0fe, last accessed 2022/06/11.

2 iOS Apps, 1 Codebase with XCode Scheme [Online] – Available from: https://testfairy. com/blog/2-ios-apps-1-codebase-with-xcode- scheme/, last accessed: 2022/06/11.

Bundle IDs [Online] – Available from: https://developer.apple.com/documentation/ appstoreconnectapi/bundle_ids, last accessed: 2022/06/11.

XcodeGen [Online] – Available from: https:// github.com/yonaskolb/XcodeGen, last accessed: 2022/06/11.

BuildSettingsExtractor [Online] – Available from: https://buildsettingextractor.com/, last accessed: 2022/06/11.

Example project.yaml [Online] – Available from: https://github.com/gloomikon/ MultiTargetAutomatisation/blob/main/iNote/ project.yml, last accessed: 2022/06/11.

igen [Online] – Available from: https://github. com/gloomikon/MultiTargetAutomatisation/ tree/main/igen, last accessed: 2022/06/11.

Template Method [Online] – Available from: https://refactoring.guru/design-patterns/ template-method, last accessed: 2022/06/11

MultiTargetAutomatisation Example Project [Online] – Available from: https://github.com/gloomikon/MultiTargetAutomatisation, last accessed: 2022/06/11.




DOI: https://doi.org/10.15407/pp2023.01.011

Refbacks

  • There are currently no refbacks.