Skip to content

Commit

Permalink
Merge pull request #77 from sbrunner/git-attributes
Browse files Browse the repository at this point in the history
Add, check and fix git attributes
  • Loading branch information
sbrunner committed Apr 12, 2016
2 parents 42c8b72 + 801b4e9 commit 2ebce07
Show file tree
Hide file tree
Showing 12 changed files with 206 additions and 204 deletions.
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
* text whitespace=trailing-space,tab-in-indent,cr-at-eol,tabwidth=4 eol=lf
.gitmodules text whitespace=indent-with-non-tab,tabwidth=2
Makefile text whitespace=indent-with-non-tab,tabwidth=2
*.rst tex conflict-marker-size=100
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ script:
- make pep8
- make pyflakes
- make test
- if [ ${TRAVIS_PULL_REQUEST} != "false" ] ; then git diff --check ${TRAVIS_BRANCH} -- ; fi

after_success:
# Report coverage results to coveralls.io
Expand Down
2 changes: 0 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -476,5 +476,3 @@ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
OF THE POSSIBILITY OF SUCH DAMAGE.

vim: set filetype=rst spell spelllang=en textwidth=0:


12 changes: 6 additions & 6 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,13 @@ htmlhelp:
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in $(BUILDDIR)/htmlhelp."
".hhp project file in $(BUILDDIR)/htmlhelp."

qthelp:
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/TileCloud.qhcp"
@echo "To view the help file:"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/TileCloud.qhc"
Expand All @@ -100,7 +100,7 @@ latex:
@echo
@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
@echo "Run \`make' in that directory to run these through (pdf)latex" \
"(use \`make latexpdf' here to do that automatically)."
"(use \`make latexpdf' here to do that automatically)."

latexpdf:
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
Expand All @@ -123,7 +123,7 @@ texinfo:
@echo
@echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
@echo "Run \`make' in that directory to run these through makeinfo" \
"(use \`make info' here to do that automatically)."
"(use \`make info' here to do that automatically)."

info:
$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
Expand All @@ -145,9 +145,9 @@ linkcheck:
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
@echo
@echo "Link check complete; look for any errors in the above output " \
"or in $(BUILDDIR)/linkcheck/output.txt."
"or in $(BUILDDIR)/linkcheck/output.txt."

doctest:
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
@echo "Testing of doctests in the sources finished, look at the " \
"results in $(BUILDDIR)/doctest/output.txt."
"results in $(BUILDDIR)/doctest/output.txt."
1 change: 0 additions & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,3 @@ Indices and tables
* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

78 changes: 39 additions & 39 deletions views/googlemaps.tpl
Original file line number Diff line number Diff line change
@@ -1,50 +1,50 @@
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>Google Maps - TileCloud</title>
</head>
<body>
<div id="map" style="width: 100%; height: 100%;">
</div>
<script type="text/javascript">
var mapTypes = [], mapTypeIds = [];
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>Google Maps - TileCloud</title>
</head>
<body>
<div id="map" style="width: 100%; height: 100%;">
</div>
<script type="text/javascript">
var mapTypes = [], mapTypeIds = [];
%for index, (name, tilestore) in enumerate(tilestores):
%if tilestore.content_type is None or tilestore.content_type.startswith('image/'):
mapTypes.push(new google.maps.ImageMapType({
alt: '{{index}}',
getTileUrl: function(coord, zoom) {
return '/tiles/{{index}}/tiles/' + zoom + '/' + coord.x + '/' + coord.y;
},
name: '{{index}}',
tileSize: new google.maps.Size(256, 256),
maxZoom: 32
}));
mapTypeIds.push('{{index}}');
mapTypes.push(new google.maps.ImageMapType({
alt: '{{index}}',
getTileUrl: function(coord, zoom) {
return '/tiles/{{index}}/tiles/' + zoom + '/' + coord.x + '/' + coord.y;
},
name: '{{index}}',
tileSize: new google.maps.Size(256, 256),
maxZoom: 32
}));
mapTypeIds.push('{{index}}');
%end
%end
var map = new google.maps.Map(document.getElementById('map'), {
center: new google.maps.LatLng(0, 0),
mapTypeControlOptions: {
mapTypeIds: mapTypeIds
},
mapTypeId: mapTypeIds[0],
zoom: 0
});
var map = new google.maps.Map(document.getElementById('map'), {
center: new google.maps.LatLng(0, 0),
mapTypeControlOptions: {
mapTypeIds: mapTypeIds
},
mapTypeId: mapTypeIds[0],
zoom: 0
});
%for index, (name, tilestore) in enumerate(tilestores):
%if tilestore.content_type is None or tilestore.content_type.startswith('image/'):
map.mapTypes.set(mapTypeIds[{{index}}], mapTypes[{{index}}]);
map.mapTypes.set(mapTypeIds[{{index}}], mapTypes[{{index}}]);
%end
%end
</script>
</body>
</script>
</body>
</html>
28 changes: 14 additions & 14 deletions views/index.tpl
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<!doctype html>
<html>
<head>
<title>TileCloud</title>
</head>
<body>
<ul>
<li><a href="/openlayers">OpenLayers</a></li>
<li><a href="/googlemaps">Google Maps</a></li>
<li><a href="/jquerygeo">jQuery Geo</a></li>
<li><a href="/leaflet">Leaflet</a></li>
<li><a href="/modestmaps">Modest Maps</a></li>
<li><a href="/polymaps">Polymaps</a></li>
<li><a href="/openwebglobe">OpenWebGlobe</a></li>
</ul>
</body>
<head>
<title>TileCloud</title>
</head>
<body>
<ul>
<li><a href="/openlayers">OpenLayers</a></li>
<li><a href="/googlemaps">Google Maps</a></li>
<li><a href="/jquerygeo">jQuery Geo</a></li>
<li><a href="/leaflet">Leaflet</a></li>
<li><a href="/modestmaps">Modest Maps</a></li>
<li><a href="/polymaps">Polymaps</a></li>
<li><a href="/openwebglobe">OpenWebGlobe</a></li>
</ul>
</body>
</html>
68 changes: 34 additions & 34 deletions views/jquerygeo.tpl
Original file line number Diff line number Diff line change
@@ -1,43 +1,43 @@
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script src="http://code.jquerygeo.com/jquery.geo-1.0a4.min.js"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>jQueryGeo - TileCloud</title>
</head>
<body>
<div id="map" style="width: 100%; height: 100%;">
</div>
<script>
$(function () {
var services = [];
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script src="http://code.jquerygeo.com/jquery.geo-1.0a4.min.js"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>jQueryGeo - TileCloud</title>
</head>
<body>
<div id="map" style="width: 100%; height: 100%;">
</div>
<script>
$(function () {
var services = [];
%for index, (name, tilestore) in enumerate(tilestores):
%if tilestore.content_type is None or tilestore.content_type.startswith('image/'):
services.push({
id: "{{name}}",
services.push({
id: "{{name}}",
%if getattr(tilestore, 'attribution', None):
attr: '{{!tilestore.attribution}}',
attr: '{{!tilestore.attribution}}',
%end
src: function( view ) {
return "/tiles/{{index}}/tiles/" + view.zoom + "/" + view.tile.column + "/" + view.tile.row;
},
type: "tiled"
});
src: function( view ) {
return "/tiles/{{index}}/tiles/" + view.zoom + "/" + view.tile.column + "/" + view.tile.row;
},
type: "tiled"
});
%end
%end
var map = $( "#map" ).geomap( {
services: services
} );
});
</script>
</body>
var map = $( "#map" ).geomap( {
services: services
} );
});
</script>
</body>
</html>
44 changes: 22 additions & 22 deletions views/modestmaps.tpl
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script type="text/javascript" src="https://raw.github.com/stamen/modestmaps-js/master/modestmaps.min.js"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>Modest Maps - TileCloud</title>
</head>
<body>
<div id="map" class="map" style="width: 100%; height: 100%;">
</div>
<script type="text/javascript">
var layers = [];
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<script type="text/javascript" src="https://raw.github.com/stamen/modestmaps-js/master/modestmaps.min.js"></script>
<style type="text/css">
html, body, #map {
margin: 0;
padding: 0;
height: 100%;
}
</style>
<title>Modest Maps - TileCloud</title>
</head>
<body>
<div id="map" class="map" style="width: 100%; height: 100%;">
</div>
<script type="text/javascript">
var layers = [];
%for index, (name, tilestore) in enumerate(tilestores):
%if tilestore.content_type is None or tilestore.content_type.startswith('image/'):
layers.push(new MM.Layer(new MM.TemplatedMapProvider('/tiles/{{index}}/tiles/{Z}/{X}/{Y}')));
layers.push(new MM.Layer(new MM.TemplatedMapProvider('/tiles/{{index}}/tiles/{Z}/{X}/{Y}')));
%end
%end
var map = new MM.Map('map', layers);
</script>
</body>
var map = new MM.Map('map', layers);
</script>
</body>
</html>
Loading

0 comments on commit 2ebce07

Please sign in to comment.