Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into salt-pond
Browse files Browse the repository at this point in the history
  • Loading branch information
jeisenbe committed Mar 22, 2020
2 parents f0b1f2d + 6db6b4a commit 75b6deb
Show file tree
Hide file tree
Showing 11 changed files with 193 additions and 220 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: CI
on:
- push
- pull_request
jobs:
syntax:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Set up Python
run: |
python -m pip install pyyaml colormath
- name: Set up xmllint
run: sudo apt-get install -qq --no-install-recommends libxml2-utils
- name: Set up shell
run: set -o pipefail
- name: Validate YAML files
run: |
find . \( -type f -name '*.yaml' -o -name '*.yml' -o -name '*.mml' \) \
-exec python -c "from yaml import safe_load; safe_load(file('{}'))" \;
- name: Validate SVGs for valid XML
run: find symbols/ -name '*.svg' | xargs xmllint --noout
- name: Check indexes are up to date
run: diff -qu <(scripts/indexes.py) indexes.sql
- name: Check road colours are up to date
run: diff -qu <(scripts/generate_road_colours.py) style/road-colors-generated.mss
- name: Check for unsupported class usage
run: '! grep "class:" project.mml > /dev/null'
4 changes: 3 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@ addons:
packages:
- lua5.1
- libxml2-utils
- python3-pip
- python3-setuptools
- python-yaml
- postgresql-9.5-postgis-2.4
- osm2pgsql
env:
- CARTO=1.2.0 MAPNIK='3.0.0 3.0.12'
install:
- npm install carto@$CARTO
- pip install --user colormath
- pip3 install --user colormath
- mkdir -p data/simplified-water-polygons-split-3857 data/ne_110m_admin_0_boundary_lines_land data/water-polygons-split-3857
- touch data/simplified-water-polygons-split-3857/simplified_water_polygons.shp data/ne_110m_admin_0_boundary_lines_land/ne_110m_admin_0_boundary_lines_land.shp data/water-polygons-split-3857/water_polygons.shp
- createdb -w -E utf8 -U postgres gis && psql -Xq -d gis -U postgres -w -c "CREATE EXTENSION postgis; CREATE EXTENSION hstore;"
Expand Down
23 changes: 22 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,25 @@
## [Unreleased](https://github.com/gravitystorm/openstreetmap-carto/compare/v4.25.0...master)
## [Unreleased](https://github.com/gravitystorm/openstreetmap-carto/compare/v5.0.0...master)

### Changes
- Remove way_area filtering for low zoom water (#4060)
- Move small amenities to z18 (#4044)
- Remove duplicate selection of natural = cave_entrance, peak, volcano, saddle (#4068)
- Change quarry outline to 10% darkened quarry color (#4063)

## [v5.0.0](https://github.com/gravitystorm/openstreetmap-carto/compare/v4.25.0...v5.0.0) - 2020-03-18

### Major changes
- Update Lua tag transforms. (#4032)
Linestring and polygon decisions have changed and a database reload is required for this update.

### Changes
- Added upper way_area limits to most features using ST_PointOnSurface to avoid performance problems from large polygons (#4042)
- Moved MSS files into their own directory (#4047)
- Update index for route=ferry (#3909)
- Removed rendering of power=cable features (#4045)
- Removed overlay pattern for natural=sand (#3855)
- Reduced landcover fading at mid-low zoom levels (#3952)
- Update scripts to use Python3 (#4062, #4029, #4033)

## [v4.25.0](https://github.com/gravitystorm/openstreetmap-carto/compare/v4.24.1...v4.25.0) - 2020-02-01
### Changes
Expand Down
27 changes: 15 additions & 12 deletions openstreetmap-carto.lua
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ local delete_tags = {
-- Tags generally dropped by editors, not otherwise covered
'created_by',
'odbl',
'odbl:note',
-- Lots of import tags
-- EUROSHA (Various countries)
'project:eurosha_2012',
Expand All @@ -80,7 +79,6 @@ local delete_tags = {

-- NHN (CA)
'accuracy:meters',
'sub_sea:type',
'waterway:type',
-- StatsCan (CA)
'statscan:rbuid',
Expand All @@ -96,17 +94,14 @@ local delete_tags = {

-- GST (DK)
'gst:feat_id',
-- osak (DK)
'osak:identifier',

-- Maa-amet (EE)
'maaamet:ETAK',
-- FANTOIR (FR)
'ref:FR:FANTOIR',

-- 3dshapes (NL)
'3dshapes:ggmodelk',
-- AND (NL)
'AND_nosr_r',

-- OPPDATERIN (NO)
'OPPDATERIN',
-- Various imports (PL)
Expand All @@ -119,6 +114,9 @@ local delete_tags = {

-- RABA (SK)
'raba:id',

-- LINZ (NZ)
'linz2osm:objectid',
-- DCGIS (Washington DC, US)
'dcgis:gis_id',
-- Building Identification Number (New York, US)
Expand Down Expand Up @@ -149,8 +147,6 @@ delete_prefixes = {
-- Geobase (CA)
'geobase:',

-- osak (DK)
'osak:',
-- kms (DK)
'kms:',

Expand All @@ -169,7 +165,6 @@ delete_prefixes = {

-- LINZ (NZ)
'LINZ2OSM:',
'linz2osm:',
'LINZ:',

-- WroclawGIS (PL)
Expand Down Expand Up @@ -215,8 +210,7 @@ local roads_info = {
bridleway = {z = 100, roads = false},
cycleway = {z = 100, roads = false},
steps = {z = 90, roads = false},
platform = {z = 90, roads = false},
construction = {z = 10, roads = false}
platform = {z = 90, roads = false}
},
railway = {
rail = {z = 440, roads = true},
Expand Down Expand Up @@ -257,6 +251,15 @@ function z_order(tags)
z = math.max(z, roads_info[k][v].z)
end
end

if tags["highway"] == "construction" then
if tags["construction"] and roads_info["highway"][tags["construction"]] then
z = math.max(z, roads_info["highway"][tags["construction"]].z/10)
else
z = math.max(z, 33)
end
end

return z ~= 0 and z or nil
end

Expand Down
Loading

0 comments on commit 75b6deb

Please sign in to comment.