Code review comments

This commit is contained in:
Franz Busch
2019-10-22 10:39:42 +02:00
parent b5773eff6a
commit cb2ee6cbaa
4 changed files with 26 additions and 24 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ public class FileWriter {
for target in project.targets {
// write Info.plist
if let plist = target.info {
let properties = infoPlistGenerator.generateProperties(target: target).merged(plist.properties)
let properties = infoPlistGenerator.generateProperties(for: target).merged(plist.properties)
try writePlist(properties, path: plist.path)
}
+3 -3
View File
@@ -8,7 +8,7 @@ public class InfoPlistGenerator {
Default info plist attributes taken from:
/Applications/Xcode.app/Contents/Developer/Library/Xcode/Templates/Project Templates/Base/Base_DefinitionsInfoPlist.xctemplate/TemplateInfo.plist
*/
private func generateDefaultInfoPlist(target: Target) -> [String: Any] {
private func generateDefaultInfoPlist(for target: Target) -> [String: Any] {
var dictionary: [String: Any] = [:]
dictionary["CFBundleIdentifier"] = "$(PRODUCT_BUNDLE_IDENTIFIER)"
dictionary["CFBundleInfoDictionaryVersion"] = "6.0"
@@ -26,8 +26,8 @@ public class InfoPlistGenerator {
return dictionary
}
public func generateProperties(target: Target) -> [String: Any] {
var targetInfoPlist = generateDefaultInfoPlist(target: target)
public func generateProperties(for target: Target) -> [String: Any] {
var targetInfoPlist = generateDefaultInfoPlist(for: target)
switch target.type {
case .uiTestBundle,
.unitTestBundle: