Cordova ios add extension - Error: could not find the -Info.plist file or config.xml file

I recently encountered a problem in Cordova with the addition of a new extension to the target application. I have a Cordova application and a custom Cordova plugin that I created. When I add the extension to my iOS application (with Xcode → file → new → target ... Application Extension: Custom keyboard) And then I try to install my plugin, I get the following error:

Failed to install "paykey-plugin": CordovaError: could not find the -Info.plist file or config.xml file. in Object.parseProjectFile [as parsing] (/Users/Yariv/Development/workspace/paykey/paykeyCordova/platforms/ios/cordova/lib/projectFile.js:50:15) in Plugman.addPlugin (/ Users / Yariv / Development / workspace / paykey / paykeyCordova / platforms / ios / cordova / lib / plugman / Plugman.js: 68: 31) in Api.addPlugin (/ Users / Yariv / Development / workspace / paykey / paykeyCordova / platforms / ios / cordova / Api.js: 202: 40) on handleInstall (/ Users / Yariv / npm / lib / node_modules / cordova / node_modules / cordova-lib / src / plugman / install.js: 605: 6) in / Users / Yariv / npm / lib / node_modules / cordova / node_modules / cordova-lib / src / plugman / install.js: 403: 28 on _fulfilled (/Users/Yariv/npm/lib/node_modules/cordova/node_modules/q/q.js:787:54 ) on self.promiseDispatch.done (/Users/Yariv/npm/lib/node_modules/cordova/node_modules/q/q.js:816:30) in Promise.promise.promiseDispatch (/ Users / Yariv / npm / lib / node_modules /cordova/node_modules/q/q.js:749:13) in / Users / Yariv / n pm / lib / node_modules / cordova / node_modules / q / q.js: 509: 49 on a flash (/Users/Yariv/npm/lib/node_modules/cordova/node_modules/q/q.js:108:17) Error: not could find -Info.plist file or config.xml file. [12:38:19] InstallPlugins installation error after 1.39 s [12:38:19] Error: cordova plugin add ../paykeyCordovaPlugin failed with exit code 1 in ChildProcess.exithandler (child_process.js: 203: 12) on emitTwo (events.js: 87: 13) at ChildProcess.emit (events.js: 172: 7) at maybeClose (internal / child_process.js: 818: 16) in Socket. (Internal / child_process.js: 319: 11) on emitOne (events.js: 77: 13) on Socket.emit (events.js: 169: 7) on Pipe._onclose (net.js: 469: 12)

Thank you in advance

+6
source share
1 answer

This may happen because your plugin does not use the correct path for * -Info.plist.

try removing or adding "$ (SRCROOT)" before the project name in project.pbxproj, which is located in platform / ios / YourAppName.xcodeproj / project.pbxproj when you open it in a text editor, for example, "Subline Text".

eg:

INFOPLIST_FILE = "$ (SRCROOT) / YourAppName / YourAppName -Info.plist";

try removing "$ (SRCROOT) /" or adding "$ (SRCROOT) /"

0
source

All Articles