1import { ExpoConfig } from '@expo/config-types'; 2import xcode, { PBXFile, PBXGroup, PBXNativeTarget, PBXProject, XCBuildConfiguration, XCConfigurationList, XcodeProject } from 'xcode'; 3export declare type ProjectSectionEntry = [string, PBXProject]; 4export declare type NativeTargetSection = Record<string, PBXNativeTarget>; 5export declare type NativeTargetSectionEntry = [string, PBXNativeTarget]; 6export declare type ConfigurationLists = Record<string, XCConfigurationList>; 7export declare type ConfigurationListEntry = [string, XCConfigurationList]; 8export declare type ConfigurationSectionEntry = [string, XCBuildConfiguration]; 9export declare function getProjectName(projectRoot: string): string; 10export declare function resolvePathOrProject(projectRootOrProject: string | XcodeProject): XcodeProject | null; 11export declare function sanitizedName(name: string): string; 12export declare function getHackyProjectName(projectRoot: string, config: ExpoConfig): string; 13/** 14 * Add a resource file (ex: `SplashScreen.storyboard`, `Images.xcassets`) to an Xcode project. 15 * This is akin to creating a new code file in Xcode with `⌘+n`. 16 */ 17export declare function addResourceFileToGroup({ filepath, groupName, isBuildFile, project, verbose, targetUuid, }: { 18 filepath: string; 19 groupName: string; 20 isBuildFile?: boolean; 21 project: XcodeProject; 22 verbose?: boolean; 23 targetUuid?: string; 24}): XcodeProject; 25/** 26 * Add a build source file (ex: `AppDelegate.m`, `ViewController.swift`) to an Xcode project. 27 * This is akin to creating a new code file in Xcode with `⌘+n`. 28 */ 29export declare function addBuildSourceFileToGroup({ filepath, groupName, project, verbose, targetUuid, }: { 30 filepath: string; 31 groupName: string; 32 project: XcodeProject; 33 verbose?: boolean; 34 targetUuid?: string; 35}): XcodeProject; 36export declare function addFileToGroupAndLink({ filepath, groupName, project, verbose, addFileToProject, targetUuid, }: { 37 filepath: string; 38 groupName: string; 39 project: XcodeProject; 40 verbose?: boolean; 41 targetUuid?: string; 42 addFileToProject: (props: { 43 file: PBXFile; 44 project: XcodeProject; 45 }) => void; 46}): XcodeProject; 47export declare function getApplicationNativeTarget({ project, projectName, }: { 48 project: XcodeProject; 49 projectName: string; 50}): { 51 uuid: string; 52 target: xcode.PBXNativeTarget; 53}; 54/** 55 * Add a framework to the default app native target. 56 * 57 * @param projectName Name of the PBX project. 58 * @param framework String ending in `.framework`, i.e. `StoreKit.framework` 59 */ 60export declare function addFramework({ project, projectName, framework, }: { 61 project: XcodeProject; 62 projectName: string; 63 framework: string; 64}): unknown; 65export declare function ensureGroupRecursively(project: XcodeProject, filepath: string): PBXGroup | null; 66/** 67 * Get the pbxproj for the given path 68 */ 69export declare function getPbxproj(projectRoot: string): XcodeProject; 70/** 71 * Get the productName for a project, if the name is using a variable `$(TARGET_NAME)`, then attempt to get the value of that variable. 72 * 73 * @param project 74 */ 75export declare function getProductName(project: XcodeProject): string; 76export declare function getProjectSection(project: XcodeProject): Record<string, xcode.PBXProject> & Record<string, string>; 77export declare function getXCConfigurationListEntries(project: XcodeProject): ConfigurationListEntry[]; 78export declare function getBuildConfigurationsForListId(project: XcodeProject, configurationListId: string): ConfigurationSectionEntry[]; 79export declare function getBuildConfigurationForListIdAndName(project: XcodeProject, { configurationListId, buildConfiguration, }: { 80 configurationListId: string; 81 buildConfiguration: string; 82}): ConfigurationSectionEntry; 83export declare function isBuildConfig([, sectionItem]: ConfigurationSectionEntry): boolean; 84export declare function isNotTestHost([, sectionItem]: ConfigurationSectionEntry): boolean; 85export declare function isNotComment([key]: ConfigurationSectionEntry | ProjectSectionEntry | ConfigurationListEntry | NativeTargetSectionEntry): boolean; 86export declare function unquote(value: string): string; 87