2017-12-13 3 views
1

PhoneGap CLI를 통해 항상 잘 작성된 앱이 있습니다.플러그인 오류로 인해 PhoneGap이 작성되지 않습니다.

나는 몇 주를 남겨두고 오늘 (코드 변경 없음) 다시 작성하려고 시도했지만 오류가 발생했습니다.

Error - Plugin error (you probably need to remove plugin files from your app): Fetching plugin "[email protected]^1.6.3" via npm Installing "cordova-plugin-file-transfer" at "1.7.0" for android Failed to install 'cordova-plugin-file-transfer': CordovaError: Version of installed plugin: "[email protected]" does not satisfy dependency plugin requirement "[email protected]^5.0.0". Try --force to use installed plugin as dependency. at /home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/pgb-cordova-lib/src/plugman/install.js:581:33 at _fulfilled (/home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/q/q.js:787:54) at self.promiseDispatch.done (/home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/q/q.js:816:30) at Promise.promise.promiseDispatch (/home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/q/q.js:749:13) at /home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/q/q.js:509:49 at flush (/home/ec2-user/.npm/lib/node_modules/pgb-plugman/node_modules/q/q.js:108:17) at _combinedTickCallback (internal/process/next_tick.js:67:7) at process._tickCallback (internal/process/next_tick.js:98:9) Version of installed plugin: "[email protected]" does not satisfy dependency plugin requirement "[email protected]^5.0.0". Try --force to use installed plugin as dependency. - You can fix this here

는 "현재이 문제를 해결할 수 있습니다"이 날 리드 :이 무엇을 의미하는지 모르는

The most likely cause for this error is error is that you have included plugin javascript files in your app package, such as barcodescanner.js, GAPlugin.js, cdv-plugin-fb-connect.js, or any other plugin files such as the childbrowser assets directory.

Previously we used pluginstall to install plugins, which would simply overwrite files in your app. However we recently migrated to plugman, which will not overwrite these files and instead fails. So make sure you remove them! [my bold]

. 플러그인이 필요할 때 플러그인 파일을 제거하는 이유는 무엇입니까? 왠지 내 모든 플러그인을 다시 설치해야합니까, 아니면 모든 것이 실행될 때 이전 PG 버전으로 되돌릴 수있는 방법이 있습니까? (이것은 PG가 어떻게 작동하는지에 대한 최근의 변경 때문에 일어나는 것으로 가정합니다.) 누구든지이 거대한 두통으로부터 올바른 방향으로 나를 가리킬 수 있다면, 그것은 고맙겠습니다!

답변

0

이렇게 많은 파기가 끝나면 config XML 파일을 특정 버전의 플러그인을 사용하도록 설정해야합니다.

이렇게하면, 의존하고있는 기능이 플러그인의 한 버전에서만 사용 가능하지만 다른 플러그인에서는 사용할 수 없다면 앱이 계속 작동 할 것이라고 보장 할 수 없기 때문에 미친 것처럼 보입니다.

<plugin name="cordova-plugin-camera" spec="~2.4.1" /> 
<plugin name="cordova-plugin-file" spec="~4.3.1" /> 
<plugin name="cordova-plugin-file-transfer" spec="~1.6.1" /> 

이 빌드 프로세스를지나 내 애플 리케이션을 얻을하지 않습니다, 그것은 표면 상 최소한의 확인 후, 수행, 여전히 작동하는 것,하지만 여전히 꽤 보인다 :

그럼에도 불구하고, this post이를 알려준 무서운 일을해야합니다. 누군가를 도울 수 있기를 바랍니다.

관련 문제