Reputation: 101
I'm attempting to download the Mapbox Maps SDK for iOS but I'm having trouble understanding how to create a .netrc file. I'm supposed to store my secret token to download the SDK and I can't add the SDK dependency with CocoaPods until I do this first. Anyone know how to go about this?
Here's the installation page for reference.
https://docs.mapbox.com/ios/maps/guides/install/#add-the-dependency
The format for the .netrc file is as follows:
machine api.mapbox.com
login mapbox
password <INSERT SECRET API TOKEN>
Upvotes: 9
Views: 45978
Reputation: 1790
CD to $HOME directory
$ cd ~
Create .netrc file
$ vi .netrc
Then use vi or any other editor and change the content of the file .netrc
to
machine api.mapbox.com
login mapbox
password <YOUR SECRET TOKEN>
Make sure to replace <YOUR SECRET TOKEN>
Upvotes: 4
Reputation: 602
Instruction how to install Mapbox into you system
If you have problems with installation Mapbox regarding official guide https://docs.mapbox.com/ios/maps/guides/install/
You can use next tips.
To create .netrc file do next
.netrc file should be like this
machine api.mapbox.com
login mapbox
password <secret_key_created_from_your_mapbox_account>
If you created .netrc
file regarding this instruction, mapbox cocoapods should install.
Upvotes: 22