Wizard: Fix MPP mobile application template

This commit is contained in:
Ilya Kirillov
2020-03-23 17:17:15 +03:00
parent e98b0782c1
commit ab59657e61
33 changed files with 441 additions and 302 deletions
@@ -16,5 +16,4 @@ class IdeaVelocityEngineTemplateService : TemplateEngineService, IdeaWizardServi
val templateText = Template::class.java.getResource(templatePath).readText()
return FileTemplateUtil.mergeTemplate(data, templateText, false)
}
}
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="${package.asCodePackage()}">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="${package}">
<application
android:allowBackup="true"
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="${package.asCodePackage()}"/>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="${package}"/>
@@ -1,4 +1,4 @@
package ${package.asCodePackage()}
package ${package}
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
@@ -1,4 +1,5 @@
// !$*UTF8*$!
#set( $bang = "!" )
// !$*UTF8*$${bang}
{
archiveVersion = 1;
classes = {
@@ -7,82 +8,92 @@
objects = {
/* Begin PBXBuildFile section */
47729E0622F447C800B9B36B /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47729E0522F447C800B9B36B /* AppDelegate.swift */; };
47729E0822F447C800B9B36B /* Vie qwController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47729E0722F447C800B9B36B /* ViewController.swift */; };
47729E0B22F447C800B9B36B /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 47729E0922F447C800B9B36B /* Main.storyboard */; };
47729E0D22F447CA00B9B36B /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 47729E0C22F447CA00B9B36B /* Assets.xcassets */; };
47729E1022F447CA00B9B36B /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 47729E0E22F447CA00B9B36B /* LaunchScreen.storyboard */; };
47729E1B22F447CA00B9B36B /* ${moduleName}Tests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47729E1A22F447CA00B9B36B /* ${moduleName}Tests.swift */; };
47729E2622F447CA00B9B36B /* ${moduleName}UITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47729E2522F447CA00B9B36B /* ${moduleName}UITests.swift */; };
47729E6E22F4806C00B9B36B /* ${sharedModuleName}.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 47729E6D22F4806B00B9B36B /* ${sharedModuleName}.framework */; };
47729E6F22F4806C00B9B36B /* ${sharedModuleName}.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 47729E6D22F4806B00B9B36B /* ${sharedModuleName}.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
7555FF7F242A565900829871 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7555FF7E242A565900829871 /* AppDelegate.swift */; };
7555FF81242A565900829871 /* SceneDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7555FF80242A565900829871 /* SceneDelegate.swift */; };
7555FF83242A565900829871 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7555FF82242A565900829871 /* ContentView.swift */; };
7555FF85242A565B00829871 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 7555FF84242A565B00829871 /* Assets.xcassets */; };
7555FF88242A565B00829871 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 7555FF87242A565B00829871 /* Preview Assets.xcassets */; };
7555FF8B242A565B00829871 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 7555FF89242A565B00829871 /* LaunchScreen.storyboard */; };
7555FF96242A565B00829871 /* ${moduleName}Tests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7555FF95242A565B00829871 /* ${moduleName}Tests.swift */; };
7555FFA1242A565B00829871 /* ${moduleName}UITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7555FFA0242A565B00829871 /* ${moduleName}UITests.swift */; };
#if($sharedModuleName)
7555FFB2242A642300829871 /* ${sharedModuleName}.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7555FFB1242A642300829871 /* ${sharedModuleName}.framework */; };
7555FFB3242A642300829871 /* ${sharedModuleName}.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 7555FFB1242A642300829871 /* ${sharedModuleName}.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
#end
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
47729E1722F447CA00B9B36B /* PBXContainerItemProxy */ = {
7555FF92242A565B00829871 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 47729DFA22F447C800B9B36B /* Project object */;
containerPortal = 7555FF73242A565900829871 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 47729E0122F447C800B9B36B;
remoteGlobalIDString = 7555FF7A242A565900829871;
remoteInfo = ${moduleName};
};
47729E2222F447CA00B9B36B /* PBXContainerItemProxy */ = {
7555FF9D242A565B00829871 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 47729DFA22F447C800B9B36B /* Project object */;
containerPortal = 7555FF73242A565900829871 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 47729E0122F447C800B9B36B;
remoteGlobalIDString = 7555FF7A242A565900829871;
remoteInfo = ${moduleName};
};
/* End PBXContainerItemProxy section */
#if($sharedModuleName)
/* Begin PBXCopyFilesBuildPhase section */
47729E7022F4806C00B9B36B /* Embed Frameworks */ = {
7555FFB4242A642300829871 /* Embed Frameworks */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 10;
files = (
47729E6F22F4806C00B9B36B /* ${sharedModuleName}.framework in Embed Frameworks */,
7555FFB3242A642300829871 /* ${sharedModuleName}.framework in Embed Frameworks */,
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXCopyFilesBuildPhase section */
#end
/* Begin PBXFileReference section */
47729E0222F447C800B9B36B /* ${moduleName}.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ${moduleName}.app; sourceTree = BUILT_PRODUCTS_DIR; };
47729E0522F447C800B9B36B /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
47729E0722F447C800B9B36B /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
47729E0A22F447C800B9B36B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
47729E0C22F447CA00B9B36B /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
47729E0F22F447CA00B9B36B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
47729E1122F447CA00B9B36B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
47729E1622F447CA00B9B36B /* ${moduleName}Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ${moduleName}Tests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
47729E1A22F447CA00B9B36B /* ${moduleName}Tests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ${moduleName}Tests.swift; sourceTree = "<group>"; };
47729E1C22F447CA00B9B36B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
47729E2122F447CA00B9B36B /* ${moduleName}UITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ${moduleName}UITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
47729E2522F447CA00B9B36B /* ${moduleName}UITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ${moduleName}UITests.swift; sourceTree = "<group>"; };
47729E2722F447CA00B9B36B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
47729E6D22F4806B00B9B36B /* ${sharedModuleName}.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ${sharedModuleName}.framework; path = "${pathToSharedModule}/build/xcode-frameworks/${sharedModuleName}.framework"; sourceTree = "<group>"; };
7555FF7B242A565900829871 /* ${moduleName}.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ${moduleName}.app; sourceTree = BUILT_PRODUCTS_DIR; };
7555FF7E242A565900829871 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
7555FF80242A565900829871 /* SceneDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SceneDelegate.swift; sourceTree = "<group>"; };
7555FF82242A565900829871 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
7555FF84242A565B00829871 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
7555FF87242A565B00829871 /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = "<group>"; };
7555FF8A242A565B00829871 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
7555FF8C242A565B00829871 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
7555FF91242A565B00829871 /* ${moduleName}Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ${moduleName}Tests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
7555FF95242A565B00829871 /* ${moduleName}Tests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ${moduleName}Tests.swift; sourceTree = "<group>"; };
7555FF97242A565B00829871 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
7555FF9C242A565B00829871 /* ${moduleName}UITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ${moduleName}UITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
7555FFA0242A565B00829871 /* ${moduleName}UITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ${moduleName}UITests.swift; sourceTree = "<group>"; };
7555FFA2242A565B00829871 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
#if($sharedModuleName)
7555FFB1242A642300829871 /* ${sharedModuleName}.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ${sharedModuleName}.framework; path = "../${sharedModuleName}/build/xcode-frameworks/${sharedModuleName}.framework"; sourceTree = "<group>"; };
#end
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
47729DFF22F447C800B9B36B /* Frameworks */ = {
7555FF78242A565900829871 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
47729E6E22F4806C00B9B36B /* ${sharedModuleName}.framework in Frameworks */,
#if($sharedModuleName)
7555FFB2242A642300829871 /* ${sharedModuleName}.framework in Frameworks */,
#end
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1322F447CA00B9B36B /* Frameworks */ = {
7555FF8E242A565B00829871 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1E22F447CA00B9B36B /* Frameworks */ = {
7555FF99242A565B00829871 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
@@ -92,70 +103,93 @@
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
47729DF922F447C800B9B36B = {
7555FF72242A565900829871 = {
isa = PBXGroup;
children = (
47729E6D22F4806B00B9B36B /* ${sharedModuleName}.framework */,
47729E0422F447C800B9B36B /* ${moduleName} */,
47729E1922F447CA00B9B36B /* ${moduleName}Tests */,
47729E2422F447CA00B9B36B /* ${moduleName}UITests */,
47729E0322F447C800B9B36B /* Products */,
7555FF7D242A565900829871 /* ${moduleName} */,
7555FF94242A565B00829871 /* ${moduleName}Tests */,
7555FF9F242A565B00829871 /* ${moduleName}UITests */,
7555FF7C242A565900829871 /* Products */,
#if($sharedModuleName)
7555FFB0242A642200829871 /* Frameworks */,
#end
);
sourceTree = "<group>";
};
47729E0322F447C800B9B36B /* Products */ = {
7555FF7C242A565900829871 /* Products */ = {
isa = PBXGroup;
children = (
47729E0222F447C800B9B36B /* ${moduleName}.app */,
47729E1622F447CA00B9B36B /* ${moduleName}Tests.xctest */,
47729E2122F447CA00B9B36B /* ${moduleName}UITests.xctest */,
7555FF7B242A565900829871 /* ${moduleName}.app */,
7555FF91242A565B00829871 /* ${moduleName}Tests.xctest */,
7555FF9C242A565B00829871 /* ${moduleName}UITests.xctest */,
);
name = Products;
sourceTree = "<group>";
};
47729E0422F447C800B9B36B /* ${moduleName} */ = {
7555FF7D242A565900829871 /* ${moduleName} */ = {
isa = PBXGroup;
children = (
47729E0522F447C800B9B36B /* AppDelegate.swift */,
47729E0722F447C800B9B36B /* ViewController.swift */,
47729E0922F447C800B9B36B /* Main.storyboard */,
47729E0C22F447CA00B9B36B /* Assets.xcassets */,
47729E0E22F447CA00B9B36B /* LaunchScreen.storyboard */,
47729E1122F447CA00B9B36B /* Info.plist */,
7555FF7E242A565900829871 /* AppDelegate.swift */,
7555FF80242A565900829871 /* SceneDelegate.swift */,
7555FF82242A565900829871 /* ContentView.swift */,
7555FF84242A565B00829871 /* Assets.xcassets */,
7555FF89242A565B00829871 /* LaunchScreen.storyboard */,
7555FF8C242A565B00829871 /* Info.plist */,
7555FF86242A565B00829871 /* Preview Content */,
);
path = ${moduleName};
sourceTree = "<group>";
};
47729E1922F447CA00B9B36B /* ${moduleName}Tests */ = {
7555FF86242A565B00829871 /* Preview Content */ = {
isa = PBXGroup;
children = (
47729E1A22F447CA00B9B36B /* ${moduleName}Tests.swift */,
47729E1C22F447CA00B9B36B /* Info.plist */,
7555FF87242A565B00829871 /* Preview Assets.xcassets */,
);
path = "Preview Content";
sourceTree = "<group>";
};
7555FF94242A565B00829871 /* ${moduleName}Tests */ = {
isa = PBXGroup;
children = (
7555FF95242A565B00829871 /* ${moduleName}Tests.swift */,
7555FF97242A565B00829871 /* Info.plist */,
);
path = ${moduleName}Tests;
sourceTree = "<group>";
};
47729E2422F447CA00B9B36B /* ${moduleName}UITests */ = {
7555FF9F242A565B00829871 /* ${moduleName}UITests */ = {
isa = PBXGroup;
children = (
47729E2522F447CA00B9B36B /* ${moduleName}UITests.swift */,
47729E2722F447CA00B9B36B /* Info.plist */,
7555FFA0242A565B00829871 /* ${moduleName}UITests.swift */,
7555FFA2242A565B00829871 /* Info.plist */,
);
path = ${moduleName}UITests;
sourceTree = "<group>";
};
#if($sharedModuleName)
7555FFB0242A642200829871 /* Frameworks */ = {
isa = PBXGroup;
children = (
7555FFB1242A642300829871 /* ${sharedModuleName}.framework */,
);
name = Frameworks;
sourceTree = "<group>";
};
#end
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
47729E0122F447C800B9B36B /* ${moduleName} */ = {
7555FF7A242A565900829871 /* ${moduleName} */ = {
isa = PBXNativeTarget;
buildConfigurationList = 47729E2A22F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}" */;
buildConfigurationList = 7555FFA5242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}" */;
buildPhases = (
47729E7122F480EB00B9B36B /* ShellScript */,
47729DFE22F447C800B9B36B /* Sources */,
47729DFF22F447C800B9B36B /* Frameworks */,
47729E0022F447C800B9B36B /* Resources */,
47729E7022F4806C00B9B36B /* Embed Frameworks */,
7555FF77242A565900829871 /* Sources */,
7555FF78242A565900829871 /* Frameworks */,
7555FF79242A565900829871 /* Resources */,
#if($sharedModuleName)
7555FFB4242A642300829871 /* Embed Frameworks */,
7555FFB5242A651A00829871 /* ShellScript */,
#end
);
buildRules = (
);
@@ -163,69 +197,69 @@
);
name = ${moduleName};
productName = ${moduleName};
productReference = 47729E0222F447C800B9B36B /* ${moduleName}.app */;
productReference = 7555FF7B242A565900829871 /* ${moduleName}.app */;
productType = "com.apple.product-type.application";
};
47729E1522F447CA00B9B36B /* ${moduleName}Tests */ = {
7555FF90242A565B00829871 /* ${moduleName}Tests */ = {
isa = PBXNativeTarget;
buildConfigurationList = 47729E2D22F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}Tests" */;
buildConfigurationList = 7555FFA8242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}Tests" */;
buildPhases = (
47729E1222F447CA00B9B36B /* Sources */,
47729E1322F447CA00B9B36B /* Frameworks */,
47729E1422F447CA00B9B36B /* Resources */,
7555FF8D242A565B00829871 /* Sources */,
7555FF8E242A565B00829871 /* Frameworks */,
7555FF8F242A565B00829871 /* Resources */,
);
buildRules = (
);
dependencies = (
47729E1822F447CA00B9B36B /* PBXTargetDependency */,
7555FF93242A565B00829871 /* PBXTargetDependency */,
);
name = ${moduleName}Tests;
productName = ${moduleName}Tests;
productReference = 47729E1622F447CA00B9B36B /* ${moduleName}Tests.xctest */;
productReference = 7555FF91242A565B00829871 /* ${moduleName}Tests.xctest */;
productType = "com.apple.product-type.bundle.unit-test";
};
47729E2022F447CA00B9B36B /* ${moduleName}UITests */ = {
7555FF9B242A565B00829871 /* ${moduleName}UITests */ = {
isa = PBXNativeTarget;
buildConfigurationList = 47729E3022F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}UITests" */;
buildConfigurationList = 7555FFAB242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}UITests" */;
buildPhases = (
47729E1D22F447CA00B9B36B /* Sources */,
47729E1E22F447CA00B9B36B /* Frameworks */,
47729E1F22F447CA00B9B36B /* Resources */,
7555FF98242A565B00829871 /* Sources */,
7555FF99242A565B00829871 /* Frameworks */,
7555FF9A242A565B00829871 /* Resources */,
);
buildRules = (
);
dependencies = (
47729E2322F447CA00B9B36B /* PBXTargetDependency */,
7555FF9E242A565B00829871 /* PBXTargetDependency */,
);
name = ${moduleName}UITests;
productName = ${moduleName}UITests;
productReference = 47729E2122F447CA00B9B36B /* ${moduleName}UITests.xctest */;
productReference = 7555FF9C242A565B00829871 /* ${moduleName}UITests.xctest */;
productType = "com.apple.product-type.bundle.ui-testing";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
47729DFA22F447C800B9B36B /* Project object */ = {
7555FF73242A565900829871 /* Project object */ = {
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 1030;
LastUpgradeCheck = 1030;
ORGANIZATIONNAME = "Evgeny Petrenko";
LastSwiftUpdateCheck = 1130;
LastUpgradeCheck = 1130;
ORGANIZATIONNAME = orgName;
TargetAttributes = {
47729E0122F447C800B9B36B = {
CreatedOnToolsVersion = 10.3;
7555FF7A242A565900829871 = {
CreatedOnToolsVersion = 11.3.1;
};
47729E1522F447CA00B9B36B = {
CreatedOnToolsVersion = 10.3;
TestTargetID = 47729E0122F447C800B9B36B;
7555FF90242A565B00829871 = {
CreatedOnToolsVersion = 11.3.1;
TestTargetID = 7555FF7A242A565900829871;
};
47729E2022F447CA00B9B36B = {
CreatedOnToolsVersion = 10.3;
TestTargetID = 47729E0122F447C800B9B36B;
7555FF9B242A565B00829871 = {
CreatedOnToolsVersion = 11.3.1;
TestTargetID = 7555FF7A242A565900829871;
};
};
};
buildConfigurationList = 47729DFD22F447C800B9B36B /* Build configuration list for PBXProject "${moduleName}" */;
buildConfigurationList = 7555FF76242A565900829871 /* Build configuration list for PBXProject "${moduleName}" */;
compatibilityVersion = "Xcode 9.3";
developmentRegion = en;
hasScannedForEncodings = 0;
@@ -233,37 +267,37 @@
en,
Base,
);
mainGroup = 47729DF922F447C800B9B36B;
productRefGroup = 47729E0322F447C800B9B36B /* Products */;
mainGroup = 7555FF72242A565900829871;
productRefGroup = 7555FF7C242A565900829871 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
47729E0122F447C800B9B36B /* ${moduleName} */,
47729E1522F447CA00B9B36B /* ${moduleName}Tests */,
47729E2022F447CA00B9B36B /* ${moduleName}UITests */,
7555FF7A242A565900829871 /* ${moduleName} */,
7555FF90242A565B00829871 /* ${moduleName}Tests */,
7555FF9B242A565B00829871 /* ${moduleName}UITests */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
47729E0022F447C800B9B36B /* Resources */ = {
7555FF79242A565900829871 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
47729E1022F447CA00B9B36B /* LaunchScreen.storyboard in Resources */,
47729E0D22F447CA00B9B36B /* Assets.xcassets in Resources */,
47729E0B22F447C800B9B36B /* Main.storyboard in Resources */,
7555FF8B242A565B00829871 /* LaunchScreen.storyboard in Resources */,
7555FF88242A565B00829871 /* Preview Assets.xcassets in Resources */,
7555FF85242A565B00829871 /* Assets.xcassets in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1422F447CA00B9B36B /* Resources */ = {
7555FF8F242A565B00829871 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1F22F447CA00B9B36B /* Resources */ = {
7555FF9A242A565B00829871 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
@@ -272,8 +306,9 @@
};
/* End PBXResourcesBuildPhase section */
#if($sharedModuleName)
/* Begin PBXShellScriptBuildPhase section */
47729E7122F480EB00B9B36B /* ShellScript */ = {
7555FFB5242A651A00829871 /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
@@ -288,64 +323,58 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "# Type a script or drag a script file from your workspace to insert its path.\n\ncd \"$SRCROOT/../../${sharedModuleName}/build/xcode-frameworks\"\n./gradlew :${sharedModuleName}:packForXCode -PXCODE_CONFIGURATION=${CONFIGURATION}\n";
shellScript = "cd \"$SRCROOT/..\"\n./gradlew :${sharedModuleName}:packForXCode -PXCODE_CONFIGURATION=${CONFIGURATION}\n";
};
/* End PBXShellScriptBuildPhase section */
#end
/* Begin PBXSourcesBuildPhase section */
47729DFE22F447C800B9B36B /* Sources */ = {
7555FF77242A565900829871 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
47729E0822F447C800B9B36B /* ViewController.swift in Sources */,
47729E0622F447C800B9B36B /* AppDelegate.swift in Sources */,
7555FF7F242A565900829871 /* AppDelegate.swift in Sources */,
7555FF81242A565900829871 /* SceneDelegate.swift in Sources */,
7555FF83242A565900829871 /* ContentView.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1222F447CA00B9B36B /* Sources */ = {
7555FF8D242A565B00829871 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
47729E1B22F447CA00B9B36B /* ${moduleName}Tests.swift in Sources */,
7555FF96242A565B00829871 /* ${moduleName}Tests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
47729E1D22F447CA00B9B36B /* Sources */ = {
7555FF98242A565B00829871 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
47729E2622F447CA00B9B36B /* ${moduleName}UITests.swift in Sources */,
7555FFA1242A565B00829871 /* ${moduleName}UITests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
47729E1822F447CA00B9B36B /* PBXTargetDependency */ = {
7555FF93242A565B00829871 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 47729E0122F447C800B9B36B /* ${moduleName} */;
targetProxy = 47729E1722F447CA00B9B36B /* PBXContainerItemProxy */;
target = 7555FF7A242A565900829871 /* ${moduleName} */;
targetProxy = 7555FF92242A565B00829871 /* PBXContainerItemProxy */;
};
47729E2322F447CA00B9B36B /* PBXTargetDependency */ = {
7555FF9E242A565B00829871 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 47729E0122F447C800B9B36B /* ${moduleName} */;
targetProxy = 47729E2222F447CA00B9B36B /* PBXContainerItemProxy */;
target = 7555FF7A242A565900829871 /* ${moduleName} */;
targetProxy = 7555FF9D242A565B00829871 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin PBXVariantGroup section */
47729E0922F447C800B9B36B /* Main.storyboard */ = {
7555FF89242A565B00829871 /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
47729E0A22F447C800B9B36B /* Base */,
);
name = Main.storyboard;
sourceTree = "<group>";
};
47729E0E22F447CA00B9B36B /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
47729E0F22F447CA00B9B36B /* Base */,
7555FF8A242A565B00829871 /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "<group>";
@@ -353,7 +382,7 @@
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
47729E2822F447CA00B9B36B /* Debug */ = {
7555FFA3242A565B00829871 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
@@ -385,7 +414,6 @@
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
@@ -404,7 +432,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
IPHONEOS_DEPLOYMENT_TARGET = 13.2;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
@@ -414,7 +442,7 @@
};
name = Debug;
};
47729E2922F447CA00B9B36B /* Release */ = {
7555FFA4242A565B00829871 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
@@ -446,7 +474,6 @@
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
@@ -459,7 +486,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
IPHONEOS_DEPLOYMENT_TARGET = 13.2;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
@@ -469,55 +496,64 @@
};
name = Release;
};
47729E2B22F447CA00B9B36B /* Debug */ = {
7555FFA6242A565B00829871 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)/../../${sharedModuleName}/build/xcode-frameworks";
DEVELOPMENT_ASSET_PATHS = "\"${moduleName}/Preview Content\"";
ENABLE_PREVIEWS = YES;
#if($sharedModuleName)
FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)/../${sharedModuleName}/build/xcode-frameworks";
#end
INFOPLIST_FILE = ${moduleName}/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName};
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName};
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
47729E2C22F447CA00B9B36B /* Release */ = {
7555FFA7242A565B00829871 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)/../../${sharedModuleName}/build/xcode-frameworks";
DEVELOPMENT_ASSET_PATHS = "\"${moduleName}/Preview Content\"";
ENABLE_PREVIEWS = YES;
#if($sharedModuleName)
FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)/../${sharedModuleName}/build/xcode-frameworks";
#end
INFOPLIST_FILE = ${moduleName}/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName};
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName};
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
47729E2E22F447CA00B9B36B /* Debug */ = {
7555FFA9242A565B00829871 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
INFOPLIST_FILE = ${moduleName}Tests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 13.2;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName}Tests;
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName}Tests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -525,19 +561,20 @@
};
name = Debug;
};
47729E2F22F447CA00B9B36B /* Release */ = {
7555FFAA242A565B00829871 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
INFOPLIST_FILE = ${moduleName}Tests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 13.2;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName}Tests;
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName}Tests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -545,7 +582,7 @@
};
name = Release;
};
47729E3122F447CA00B9B36B /* Debug */ = {
7555FFAC242A565B00829871 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
@@ -556,7 +593,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName}UITests;
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName}UITests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -564,7 +601,7 @@
};
name = Debug;
};
47729E3222F447CA00B9B36B /* Release */ = {
7555FFAD242A565B00829871 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
@@ -575,7 +612,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.jetbrains.handson.mpp.mobile.${moduleName}UITests;
PRODUCT_BUNDLE_IDENTIFIER = orgIdentifier.${moduleName}UITests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -586,43 +623,43 @@
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
47729DFD22F447C800B9B36B /* Build configuration list for PBXProject "${moduleName}" */ = {
7555FF76242A565900829871 /* Build configuration list for PBXProject "${moduleName}" */ = {
isa = XCConfigurationList;
buildConfigurations = (
47729E2822F447CA00B9B36B /* Debug */,
47729E2922F447CA00B9B36B /* Release */,
7555FFA3242A565B00829871 /* Debug */,
7555FFA4242A565B00829871 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
47729E2A22F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}" */ = {
7555FFA5242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}" */ = {
isa = XCConfigurationList;
buildConfigurations = (
47729E2B22F447CA00B9B36B /* Debug */,
47729E2C22F447CA00B9B36B /* Release */,
7555FFA6242A565B00829871 /* Debug */,
7555FFA7242A565B00829871 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
47729E2D22F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}Tests" */ = {
7555FFA8242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}Tests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
47729E2E22F447CA00B9B36B /* Debug */,
47729E2F22F447CA00B9B36B /* Release */,
7555FFA9242A565B00829871 /* Debug */,
7555FFAA242A565B00829871 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
47729E3022F447CA00B9B36B /* Build configuration list for PBXNativeTarget "${moduleName}UITests" */ = {
7555FFAB242A565B00829871 /* Build configuration list for PBXNativeTarget "${moduleName}UITests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
47729E3122F447CA00B9B36B /* Debug */,
47729E3222F447CA00B9B36B /* Release */,
7555FFAC242A565B00829871 /* Debug */,
7555FFAD242A565B00829871 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 47729DFA22F447C800B9B36B /* Project object */;
rootObject = 7555FF73242A565900829871 /* Project object */;
}
@@ -0,0 +1,29 @@
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
return true
}
// MARK: UISceneSession Lifecycle
func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration {
// Called when a new scene session is being created.
// Use this method to select a configuration to create the new scene with.
return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role)
}
func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set<UISceneSession>) {
// Called when the user discards a scene session.
// If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions.
// Use this method to release any resources that were specific to the discarded scenes, as they will not return.
}
}
@@ -13,7 +13,7 @@
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color key="backgroundColor" xcode11CocoaTouchSystemColor="systemBackgroundColor" cocoaTouchSystemColor="whiteColor"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
@@ -0,0 +1,13 @@
import SwiftUI
struct ContentView: View {
var body: some View {
Text("Hello, World!")
}
}
struct ContentView_Previews: PreviewProvider {
static var previews: some View {
ContentView()
}
}
@@ -13,17 +13,32 @@
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIApplicationSceneManifest</key>
<dict>
<key>UIApplicationSupportsMultipleScenes</key>
<false/>
<key>UISceneConfigurations</key>
<dict>
<key>UIWindowSceneSessionRoleApplication</key>
<array>
<dict>
<key>UISceneConfigurationName</key>
<string>Default Configuration</string>
<key>UISceneDelegateClassName</key>
<string>$(PRODUCT_MODULE_NAME).SceneDelegate</string>
</dict>
</array>
</dict>
</dict>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
@@ -0,0 +1,64 @@
//
// SceneDelegate.swift
// appName
//
// Created by Ilya Kirillov on 3/24/20.
// Copyright © 2020 orgName. All rights reserved.
//
import UIKit
import SwiftUI
class SceneDelegate: UIResponder, UIWindowSceneDelegate {
var window: UIWindow?
func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
// Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
// If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
// This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead).
// Create the SwiftUI view that provides the window contents.
let contentView = ContentView()
// Use a UIHostingController as window root view controller.
if let windowScene = scene as? UIWindowScene {
let window = UIWindow(windowScene: windowScene)
window.rootViewController = UIHostingController(rootView: contentView)
self.window = window
window.makeKeyAndVisible()
}
}
func sceneDidDisconnect(_ scene: UIScene) {
// Called as the scene is being released by the system.
// This occurs shortly after the scene enters the background, or when its session is discarded.
// Release any resources associated with this scene that can be re-created the next time the scene connects.
// The scene may re-connect later, as its session was not neccessarily discarded (see `application:didDiscardSceneSessions` instead).
}
func sceneDidBecomeActive(_ scene: UIScene) {
// Called when the scene has moved from an inactive state to an active state.
// Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
}
func sceneWillResignActive(_ scene: UIScene) {
// Called when the scene will move from an active state to an inactive state.
// This may occur due to temporary interruptions (ex. an incoming phone call).
}
func sceneWillEnterForeground(_ scene: UIScene) {
// Called as the scene transitions from the background to the foreground.
// Use this method to undo the changes made on entering the background.
}
func sceneDidEnterBackground(_ scene: UIScene) {
// Called as the scene transitions from the foreground to the background.
// Use this method to save data, release shared resources, and store enough scene-specific state information
// to restore the scene back to its current state.
}
}
@@ -13,7 +13,7 @@
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
@@ -1,7 +1,7 @@
import XCTest
@testable import ${moduleName}
@testable import appName
class KotlinIOSTests: XCTestCase {
class appNameTests: XCTestCase {
override func setUp() {
// Put setup code here. This method is called before the invocation of each test method in the class.
@@ -13,7 +13,7 @@
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
@@ -1,6 +1,6 @@
import XCTest
class KotlinIOSUITests: XCTestCase {
class appNameUITests: XCTestCase {
override func setUp() {
// Put setup code here. This method is called before the invocation of each test method in the class.
@@ -8,9 +8,6 @@ class KotlinIOSUITests: XCTestCase {
// In UI tests it is usually best to stop immediately when a failure occurs.
continueAfterFailure = false
// UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method.
XCUIApplication().launch()
// In UI tests its important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
}
@@ -19,8 +16,21 @@ class KotlinIOSUITests: XCTestCase {
}
func testExample() {
// UI tests must launch the application that they test.
let app = XCUIApplication()
app.launch()
// Use recording to get started writing UI tests.
// Use XCTAssert and related functions to verify your tests produce the correct results.
}
func testLaunchPerformance() {
#set( $hash = "#" )
if ${hash}available(macOS 10.15, iOS 13.0, tvOS 13.0, *) {
// This measures how long it takes to launch your application.
measure(metrics: [XCTOSSignpostMetric.applicationLaunch]) {
XCUIApplication().launch()
}
}
}
}
@@ -1,38 +0,0 @@
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
return true
}
func applicationWillResignActive(_ application: UIApplication) {
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game.
}
func applicationDidEnterBackground(_ application: UIApplication) {
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}
func applicationWillEnterForeground(_ application: UIApplication) {
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background.
}
func applicationDidBecomeActive(_ application: UIApplication) {
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
}
func applicationWillTerminate(_ application: UIApplication) {
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}
}
@@ -1,24 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13122.16" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13104.12"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" customClass="ViewController" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
</document>
@@ -1,8 +0,0 @@
import UIKit
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
}
}
@@ -32,18 +32,10 @@ data class BuildFileIR(
modules.withModulesUpdated(updater).map { newModules -> copy(modules = newModules) }
private fun distinctRepositories(): List<RepositoryIR> =
irsOfType<RepositoryIR>()
.distinctBy(RepositoryIR::repository)
.sortedBy { repositoryIR ->
if (repositoryIR.repository is DefaultRepository) 0 else 1
}
irsOfType<RepositoryIR>().distinctAndSorted()
private fun distinctPluginRepositories(): List<PluginRepositoryMavenIR> =
irsOfType<PluginRepositoryMavenIR>()
.distinctBy(PluginRepositoryMavenIR::repository)
.sortedBy { repositoryIR ->
if (repositoryIR.repository is DefaultRepository) 0 else 1
}
irsOfType<PluginRepositoryMavenIR>().distinctAndSorted()
private fun distinctImportsOrNull(): List<GradleImportIR>? =
irsOfTypeOrNull<GradleImportIR>()
@@ -2,6 +2,7 @@ package org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem
import org.jetbrains.kotlin.tools.projectWizard.ir.IR
import org.jetbrains.kotlin.tools.projectWizard.plugins.printer.BuildFilePrinter
import kotlin.reflect.KClass
interface BuildSystemIR : IR {
fun BuildFilePrinter.render()
@@ -11,8 +12,25 @@ interface BuildSystemIR : IR {
// In any place of the parent IR
interface FreeIR : BuildSystemIR
interface SingleIR : BuildSystemIR
interface KotlinIR : BuildSystemIR
fun List<BuildSystemIR>.removeSingleIRDuplicates(): List<BuildSystemIR> {
if (none { it is SingleIR }) return this
val result = mutableListOf<BuildSystemIR>()
val met = mutableSetOf<KClass<out BuildSystemIR>>()
for (ir in this) {
if (ir is SingleIR) {
if (ir::class !in met) {
result += ir
met += ir::class
}
} else result += ir
}
return result
}
fun BuildSystemIR.render(printer: BuildFilePrinter) {
with(printer) { render() }
}
@@ -7,13 +7,14 @@ package org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.GradleIR
import org.jetbrains.kotlin.tools.projectWizard.plugins.printer.GradlePrinter
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.Repository
import org.jetbrains.kotlin.tools.projectWizard.settings.version.Version
interface PluginManagementIR : GradleIR
data class AndroidResolutionStrategyIR(
val androidGradlePluginVersion: Version
) : PluginManagementIR, FreeIR {
) : PluginManagementIR, FreeIR, SingleIR {
override fun GradlePrinter.renderGradle() {
sectionCall("resolutionStrategy", needIndent = true) {
sectionCall("eachPlugin", needIndent = true) {
@@ -35,8 +36,11 @@ data class AndroidResolutionStrategyIR(
}
}
data class PluginManagementRepositoryIR(val repositoryIR: RepositoryIR) : PluginManagementIR {
data class PluginManagementRepositoryIR(val repositoryIR: RepositoryIR) : PluginManagementIR, RepositoryWrapper {
override fun GradlePrinter.renderGradle() {
repositoryIR.render(this)
}
override val repository: Repository
get() = repositoryIR.repository
}
@@ -7,7 +7,17 @@ import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.CustomMaven
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.DefaultRepository
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.Repository
data class RepositoryIR(val repository: Repository) : BuildSystemIR {
interface RepositoryWrapper {
val repository: Repository
}
fun <W : RepositoryWrapper> List<W>.distinctAndSorted() =
distinctBy(RepositoryWrapper::repository)
.sortedBy { wrapper ->
if (wrapper.repository is DefaultRepository) 0 else 1
}
data class RepositoryIR(override val repository: Repository) : BuildSystemIR, RepositoryWrapper {
override fun BuildFilePrinter.render() = when (this) {
is GradlePrinter -> when (repository) {
is DefaultRepository -> {
@@ -52,11 +52,17 @@ class CreateGradleValueIR(val name: String, val body: GradleIR) : GradleIR {
data class GradleCallIr(
val name: String,
val parameters: List<BuildSystemIR> = emptyList()
val parameters: List<BuildSystemIR> = emptyList(),
val isConstructorCall: Boolean = false,
) : GradleIR {
constructor(name: String, vararg parameters: BuildSystemIR) : this(name, parameters.toList())
constructor(
name: String,
vararg parameters: BuildSystemIR,
isConstructorCall: Boolean = false
) : this(name, parameters.toList(), isConstructorCall)
override fun GradlePrinter.renderGradle() {
if (isConstructorCall && dsl == GradlePrinter.GradleDsl.GROOVY) +"new "
call(name, forceBrackets = true) {
parameters.list { it.render(this) }
}
@@ -82,6 +88,11 @@ data class GradleSectionIR(
val name: String,
val body: BodyIR
) : GradleIR, FreeIR {
constructor(name: String, bodyBuilder: MutableList<BuildSystemIR>.() -> Unit) : this(
name,
BodyIR(mutableListOf<BuildSystemIR>().apply(bodyBuilder))
)
override fun GradlePrinter.renderGradle() {
+name
+" "
@@ -21,11 +21,11 @@ data class SettingsGradleFileIR(
sectionCall("pluginManagement", needIndent = true) {
pluginManagementIrs.irsOfTypeOrNull<PluginManagementRepositoryIR>()?.let { repositories ->
sectionCall("repositories") {
repositories.listNl()
repositories.distinctAndSorted().listNl()
}
}
nl()
freeIrs().listNl()
freeIrs().removeSingleIRDuplicates().listNl()
}
}
nl()
@@ -6,6 +6,7 @@
package org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.maven
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.BuildSystemIR
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.RepositoryWrapper
import org.jetbrains.kotlin.tools.projectWizard.plugins.printer.BuildFilePrinter
import org.jetbrains.kotlin.tools.projectWizard.plugins.printer.MavenPrinter
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.Repository
@@ -19,8 +20,8 @@ interface MavenIR : BuildSystemIR {
}
data class PluginRepositoryMavenIR(
val repository: Repository
) : MavenIR {
override val repository: Repository
) : MavenIR, RepositoryWrapper {
override fun MavenPrinter.renderMaven() {
node("pluginRepository") {
singleLineNode("id") { +repository.idForMaven }
@@ -142,7 +142,7 @@ object AndroidTargetConfigurator : TargetConfigurator,
modulePath: Path
): TaskResult<Unit> = computeM {
val javaPackage = module.javaPackage(configurationData.pomIr)
val settings = mapOf("package" to javaPackage)
val settings = mapOf("package" to javaPackage.asCodePackage())
TemplatesPlugin::addFileTemplates.execute(
listOf(
FileTemplate(AndroidModuleConfigurator.FileTemplateDescriptors.androidanifestForLibraryXml, modulePath, settings)
@@ -71,7 +71,7 @@ object AndroidSinglePlatformModuleConfigurator :
modulePath: Path
): TaskResult<Unit> = computeM {
val javaPackage = module.javaPackage(configurationData.pomIr)
val settings = mapOf("package" to javaPackage)
val settings = mapOf("package" to javaPackage.asCodePackage())
TemplatesPlugin::addFileTemplates.execute(
listOf(
FileTemplate(AndroidModuleConfigurator.FileTemplateDescriptors.activityMainXml, modulePath, settings),
@@ -8,11 +8,9 @@ package org.jetbrains.kotlin.tools.projectWizard.moduleConfigurators
import org.jetbrains.kotlin.tools.projectWizard.core.*
import org.jetbrains.kotlin.tools.projectWizard.phases.GenerationPhase
import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.ModulesToIrConversionData
import org.jetbrains.kotlin.tools.projectWizard.plugins.templates.TemplatesPlugin
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.*
import org.jetbrains.kotlin.tools.projectWizard.templates.FileTemplate
import org.jetbrains.kotlin.tools.projectWizard.templates.FileTemplateDescriptor
import java.io.File
import java.nio.file.Path
object IOSSinglePlatformModuleConfigurator : SinglePlatformModuleConfigurator, ModuleConfiguratorSettings() {
@@ -29,7 +27,7 @@ object IOSSinglePlatformModuleConfigurator : SinglePlatformModuleConfigurator, M
module: Module,
modulePath: Path
): List<FileTemplate> {
val settings = createTemplatesSettingValues(module, configurationData)
val settings = createTemplatesSettingValues(module)
fun fileTemplate(path: Path) = FileTemplate(descriptor(path, module.name), modulePath, settings)
@@ -37,14 +35,15 @@ object IOSSinglePlatformModuleConfigurator : SinglePlatformModuleConfigurator, M
+fileTemplate("$DEFAULT_APP_NAME.xcodeproj" / "project.pbxproj")
+fileTemplate(DEFAULT_APP_NAME / "AppDelegate.swift")
+fileTemplate(DEFAULT_APP_NAME / "ViewController.swift")
+fileTemplate(DEFAULT_APP_NAME / "ContentView.swift")
+fileTemplate(DEFAULT_APP_NAME / "SceneDelegate.swift")
+fileTemplate(DEFAULT_APP_NAME / "Info.plist")
+fileTemplate(DEFAULT_APP_NAME / "Base.lproj" / "LaunchScreen.storyboard")
+fileTemplate(DEFAULT_APP_NAME / "Base.lproj" / "Main.storyboard")
+fileTemplate(DEFAULT_APP_NAME / "Assets.xcassets" / "Contents.json")
+fileTemplate(DEFAULT_APP_NAME / "Assets.xcassets" / "AppIcon.appiconset" / "Contents.json")
+fileTemplate(DEFAULT_APP_NAME / "Preview_Content" / "Preview_Assets.xcassets" / "Contents.json")
+fileTemplate("${DEFAULT_APP_NAME}Tests" / "Info.plist")
+fileTemplate("${DEFAULT_APP_NAME}Tests" / "${DEFAULT_APP_NAME}Tests.swift")
@@ -54,33 +53,28 @@ object IOSSinglePlatformModuleConfigurator : SinglePlatformModuleConfigurator, M
}
}
private fun Reader.createTemplatesSettingValues(
module: Module,
configurationData: ModulesToIrConversionData
): Map<String, Any?> {
private fun Reader.createTemplatesSettingValues(module: Module): Map<String, Any?> {
val dependentModule = withSettingsOf(module) {
dependentModule.reference.notRequiredSettingValue?.module
}
val dependentModulePath = dependentModule
?.path
?.considerSingleRootModuleMode(configurationData.isSingleRootModuleMode)
?.asString(separator = File.separator)
?.asPath()
return mapOf(
"moduleName" to module.name,
"sharedModuleName" to dependentModule?.name,
"pathToSharedModule" to dependentModulePath
"sharedModuleName" to dependentModule?.name
)
}
private fun descriptor(path: Path, moduleName: String) =
FileTemplateDescriptor(
"ios/singleplatformProject/$path",
path.toString().removeSuffix(".vm").replace(DEFAULT_APP_NAME, moduleName).asPath()
path.toString()
.removeSuffix(".vm")
.replace(DEFAULT_APP_NAME, moduleName)
.replace('_', ' ')
.asPath()
)
private const val DEFAULT_APP_NAME = "moduleName"
private const val DEFAULT_APP_NAME = "appName"
val dependentModule by valueSetting<DependentModuleReference>(
"",
@@ -5,14 +5,13 @@ import org.jetbrains.kotlin.tools.projectWizard.core.Reader
import org.jetbrains.kotlin.tools.projectWizard.core.buildList
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.BuildSystemIR
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.CreateGradleValueIR
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.GradleImportIR
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.RawGradleIR
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.*
import org.jetbrains.kotlin.tools.projectWizard.ir.buildsystem.gradle.multiplatform.NonDefaultTargetConfigurationIR
import org.jetbrains.kotlin.tools.projectWizard.plugins.buildSystem.BuildSystemType
import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.ModulesToIrConversionData
import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.ModuleSubType
import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.ModuleType
import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.isIOS
import org.jetbrains.kotlin.tools.projectWizard.plugins.printer.GradlePrinter
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.Module
@@ -21,6 +20,18 @@ interface NativeTargetConfigurator : TargetConfigurator
class RealNativeTargetConfigurator private constructor(
override val moduleSubType: ModuleSubType
) : NativeTargetConfigurator, SimpleTargetConfigurator {
override fun createInnerTargetIrs(reader: Reader, module: Module): List<BuildSystemIR> = if (moduleSubType.isIOS) {
listOf(
GradleSectionIR("binaries") {
add(
GradleSectionIR("framework") {
add(GradleAssignmentIR("baseName", GradleStringConstIR(module.parent!!.name)))
}
)
}
)
} else emptyList()
companion object {
val configurators = ModuleSubType.values()
.filter { it.moduleType == ModuleType.native }
@@ -341,7 +341,7 @@ object MPPMobileApplication : ProjectTemplate() {
sourcesets = createDefaultSourcesets(),
subModules = emptyList()
).withConfiguratorSettings(AndroidTargetConfigurator) {
configurator.androidPlugin withValue AndroidGradlePlugin.APPLICATION
configurator.androidPlugin withValue AndroidGradlePlugin.LIBRARY
},
Module(
"ios",
@@ -98,10 +98,10 @@ sealed class ModuleDependencyType(
CreateGradleValueIR(
"framework",
RawGradleIR {
+"kotlin.targets"
+"kotlin.targets."
when (dsl) {
GradlePrinter.GradleDsl.KOTLIN -> +""".getByName<KotlinNativeTarget>("$iosTargetName")"""
GradlePrinter.GradleDsl.GROOVY -> +"['$iosTargetName']"
GradlePrinter.GradleDsl.KOTLIN -> +"""getByName<KotlinNativeTarget>("$iosTargetName")"""
GradlePrinter.GradleDsl.GROOVY -> +iosTargetName
}
+".binaries.getFramework(mode)"
@@ -113,19 +113,14 @@ sealed class ModuleDependencyType(
add(
CreateGradleValueIR(
"targetDir",
GradleCallIr("File", rawIR("buildDir"), GradleStringConstIR("xcode-frameworks"))
GradleCallIr("File", rawIR("buildDir"), GradleStringConstIR("xcode-frameworks"), isConstructorCall = true)
)
)
addRawIR { "from({ framework.outputDirectory })" }
addRawIR { "into(targetDir)" }
}
val dependency = rawIR {
when (dsl) {
GradlePrinter.GradleDsl.KOTLIN -> """tasks.getByName("build").dependsOn(packForXcode)"""
GradlePrinter.GradleDsl.GROOVY -> "tasks['build'].dependsOn(packForXcode)"
}
}
val dependency = rawIR { """tasks.getByName("build").dependsOn(packForXcode)""" }
return buildList {
add(packForXcodeTask)