Skip to content
Artem Svetlov edited this page Oct 21, 2016 · 12 revisions

In this document, we will show step-by-step example on how to add a new service (data_source). If you want to add it just for yourself, skip git commands.

If you'd like to use more user-friendly (read GUI) approach, use tools for services creation provided by the plugin and than send the service description to us by email (info@nextgis.com).

Create and contribute with Github

*. Fork quickmapservices_contrib repo.

*. Clone it with:

git clone https://github.com/yourgithubname/quickmapservices_contrib.git

*. Go to folder where all the data_sources are stored

cd quickmapservices_contrib/data_sources

*. Make copy of one of the existing data_sources, for example osm_tracks (let's say we creating a new one - mapquest_osm).

cp -R osm_tracks mapquest_osm
cd mapquest_osm

*. Edit metadata.ini to add all necessary details, you can skip some of those if you're not sure, but try to add as many as you can:

[general]
id = mapquest_osm
type = TMS
is_contrib = False

[ui]
group = mapquest
alias = MapQuest OSM
icon = mapquest.svg

[license]
name = Community Edition License
link = http://developer.mapquest.com/web/info/terms-of-use
copyright_text =Tiles Courtesy of MapQuest, © OpenStreetMap contributors
copyright_link = http://www.mapquest.com/
terms_of_use = http://developer.mapquest.com/web/products/open/map#terms

[tms]
url = http://otile1.mqcdn.com/tiles/1.0.0/map/${z}/${x}/${y}.jpg
zmax = 19

*. Copy results to your live QGIS installation for testing:

cp -R mapquest_osm ~/.qgis2/QuickMapServices/Contribute/data_sources

*. If it works fine - commit new data source and make pull-request against our repo for review!

*. If everything is correct, we will add it to the next build of contributed pack.

##Notes

  • If adding WMS, using ids for layer doesn't always work, use layer names instead (Get them in QGIS)
Clone this wiki locally