From dfc4eb26e58f17987d67e34d66d769eada2042e8 Mon Sep 17 00:00:00 2001 From: "K. Shankari" Date: Fri, 21 Apr 2023 15:55:57 -0700 Subject: [PATCH] Set the expected number of plugins to 23 ``` $ npx cordova plugin list | wc -l (node:49489) [DEP0128] DeprecationWarning: Invalid 'main' field in '/Users/kshankar/in-house/openpath-phone/node_modules/objectorarray/package.json' of 'dist/index.js'. Please either fix that or report it to the module author (Use `node --trace-deprecation ...` to show where the warning was created) 23 ``` ``` >>> import json >>> package = json.load(open("/Users/kshankar/e-mission/native_code_upgrade/package.cordovabuild.json")) >>> package.keys() dict_keys(['name', 'version', 'displayName', 'license', 'repository', 'devDependencies', 'cordova', 'dependencies']) >>> len(package["dependencies"].keys()) 25 >>> len(package["cordova"]["plugins"]) 21 ``` Dependencies include ``` "fs-extra": "^9.0.1", "klaw-sync": "^6.0.0", ``` Plugins include the following, which are not included in the package.json ``` cordova-plugin-badge-fix 0.8.10 "Badge" es6-promise-plugin 4.2.2 "Promise" ``` So the correct number that we expect is indeed 23 --- setup/setup_shared_native.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup/setup_shared_native.sh b/setup/setup_shared_native.sh index 22f7ca72a..382289001 100644 --- a/setup/setup_shared_native.sh +++ b/setup/setup_shared_native.sh @@ -26,7 +26,7 @@ sed -i -e "s|/usr/bin/env node|/usr/bin/env node --unhandled-rejections=strict|" npx cordova prepare -EXPECTED_COUNT=24 +EXPECTED_COUNT=23 INSTALLED_COUNT=`npx cordova plugin list | wc -l` echo "Found $INSTALLED_COUNT plugins, expected $EXPECTED_COUNT" if [ $INSTALLED_COUNT -lt $EXPECTED_COUNT ];