Closed imrranbadshah closed 3 years ago
It's depends on your internet and your PC environment.
The dependency plugin https://github.com/mapsplugin/cordova-plugin-googlemaps-sdk takes long time for some people.
Please install it from local first, then install this plugin.
$ git clone git@github.com:mapsplugin/cordova-plugin-googlemaps-sdk.git
$ cordova plugin add (path to)/cordova-plugin-googlemaps-sdk
$ cordova plugin add https://github.com/mapsplugin/cordova-plugin-googlemaps#multiple_maps
Hi, I have experienced the same issue. The installation process is not stuck but takes a long time.
This was really annoying for us because when building from the CI, we need to rebuild our Cordova workspace. This means: running cordova prepare
to download and install plugins defined in our package.json
.
Despite a good bandwith (3Mb/s), more than 5 minutes of the whole cordova prepare
process was spent on the line
Installing "cordova-plugin-googlemaps" for ios
This is barely acceptable.
But we eventually found the culprit: the size of the git history of cordova-plugin-googlemaps-sdk
(a dependency of cordova-plugin-googlemaps
) is more than 500Mb (!).
Our workaround:
cordova-plugin-googlemaps-sdk
. Do not fork it but copy it: you just copy all the source files (without the big 500Mb .git directory), git add all those files and commit thoses files, in a kind of a squashed commit. (We set the project number version in our commit message, such as v3.9.0
).mapsplugin/cordova-plugin-googlemaps
project cordova-plugin-googlemaps
, update the plugin.xml
file to point toward your new repo containing the version of the cordova-plugin-googlemaps-sdk
:<dependency id="com.googlemaps.ios" url="https://github.com/mapsplugin/cordova-plugin-googlemaps-sdk" />
becomes something like:
<dependency id="com.googlemaps.ios" url="https://github.com/your_company/squashed-cordova-plugin-googlemaps-ios-sdk#3.9.0" />
package.json
dependency of cordova-plugin-googlemaps
to point towards your forked repo🚀 Now, the whole cordova prepare
process takes about 1 minute (instead of 6 minutes before) 🚀
@wf9a5m75 you could save a lot of required bandwith if you could just clean up the git history (500Mb) of cordova-plugin-googlemaps-sdk
. It'd avoid doing this workaround.
Thank you for your tips. It seems the hashtag is the best way. I can specify latest
tag on the SDK repo, and add #latest
in the plugin.xml file
I don't know if this will prevent from downloading the whole SDK repo but indeed, it's a straightforward modification with no side effects, it's worth giving it a try!
I'm submitting a ... (check one with "x")
If you choose 'problem or bug report', please select OS: (check one with "x")
cordova information: (run
$> cordova plugin list
)If you use
@ionic-native/google-maps
, please tell the package.json (only@ionic-native/core
and@ionic-native/google-maps
are fine mostly)Current behavior:
Installing "cordova-plugin-googlemaps" for ios
gets stuck at this line and returns no error or success message for ionic 4-iOS in MacOs Mojave when installing or adding ios platformExpected behavior: The Plugin should install successfully
Screen capture or video record:![Screenshot 2020-07-14 at 9 14 19 PM](https://user-images.githubusercontent.com/45847711/87447400-2cb81e00-c618-11ea-9a34-186eece41cdc.png)