@@ -39,13 +39,7 @@ public struct RswiftCore {
3939 let ignoreFile = ( try ? IgnoreFile ( ignoreFileURL: callInformation. rswiftIgnoreURL) ) ?? IgnoreFile ( )
4040
4141 let buildConfigurations = try xcodeproj. buildConfigurations ( forTarget: callInformation. targetName)
42- let infoPlists = buildConfigurations. compactMap {
43- return loadPropertyList ( name: $0. name, path: $0. infoPlistPath, callInformation: callInformation)
44- }
45- let entitlements = buildConfigurations. compactMap {
46- return loadPropertyList ( name: $0. name, path: $0. entitlementsPath, callInformation: callInformation)
47- }
48-
42+
4943 let resourceURLs = try xcodeproj. resourcePaths ( forTarget: callInformation. targetName)
5044 . map { path in path. url ( with: callInformation. urlForSourceTreeFolder) }
5145 . compactMap { $0 }
@@ -86,9 +80,19 @@ public struct RswiftCore {
8680 structGenerators. append ( AccessibilityIdentifierStructGenerator ( nibs: resources. nibs, storyboards: resources. storyboards) )
8781 }
8882 if callInformation. generators. contains ( . info) {
83+
84+ let infoPlists = buildConfigurations. compactMap {
85+ return loadPropertyList ( name: $0. name, path: $0. infoPlistPath, callInformation: callInformation)
86+ }
87+
8988 structGenerators. append ( PropertyListGenerator ( name: " info " , plists: infoPlists, toplevelKeysWhitelist: infoPlistWhitelist) )
9089 }
9190 if callInformation. generators. contains ( . entitlements) {
91+
92+ let entitlements = buildConfigurations. compactMap {
93+ return loadPropertyList ( name: $0. name, path: $0. entitlementsPath, callInformation: callInformation)
94+ }
95+
9296 structGenerators. append ( PropertyListGenerator ( name: " entitlements " , plists: entitlements, toplevelKeysWhitelist: nil ) )
9397 }
9498
0 commit comments