1 | <project name="potlatch2styles_mod" basedir=".">
|
---|
2 | <!--
|
---|
3 |
|
---|
4 | The potlatch 2 styles need to be patched in order to work with the JOSM MapCSS implementation.
|
---|
5 | When updating from the potlatch2 repository, the workflow can be like this:
|
---|
6 | * copy files from 'patched' to 'source'
|
---|
7 | * cd source && svn up
|
---|
8 | * solve possible conflicts
|
---|
9 | * modify the new sections, such that they work with josm
|
---|
10 | * create potlatch2.mapcss (ant assemble)
|
---|
11 | * copy files from 'source' to 'patched'
|
---|
12 | * update externals definition to the current revision (ant update-externals)
|
---|
13 | * commit everything (style, patches and externals definition)
|
---|
14 |
|
---|
15 | -->
|
---|
16 |
|
---|
17 | <!-- concatinate the files to one mapcss style file -->
|
---|
18 | <target name="assemble">
|
---|
19 | <concat destfile="../../styles/standard/potlatch2.mapcss">
|
---|
20 | <filelist dir="." files="prelude.css"/>
|
---|
21 | <filelist dir="patched" files="core_ways.css,core_pois.css,core_landuse.css,potlatch.css"/>
|
---|
22 | </concat>
|
---|
23 | </target>
|
---|
24 |
|
---|
25 |
|
---|
26 | <target name="copy-patched-to-source">
|
---|
27 | <copy todir="source" overwrite="true">
|
---|
28 | <fileset dir="patched"/>
|
---|
29 | </copy>
|
---|
30 | </target>
|
---|
31 |
|
---|
32 | <target name="copy-source-to-patched">
|
---|
33 | <copy todir="patched" overwrite="true">
|
---|
34 | <filelist dir="source" files="core_ways.css,core_pois.css,core_landuse.css,potlatch.css"/>
|
---|
35 | </copy>
|
---|
36 | </target>
|
---|
37 |
|
---|
38 | <!-- Update the explicit revision number in the externals definition to the current revision. -->
|
---|
39 | <target name="update-externals" depends="source-revision">
|
---|
40 | <exec executable="svn">
|
---|
41 | <arg value="propset"/>
|
---|
42 | <arg value="svn:externals"/>
|
---|
43 | <arg value="source -r ${version.entry.commit.revision} http://svn.openstreetmap.org/applications/editors/potlatch2/resources/stylesheets"/>
|
---|
44 | <arg value="."/>
|
---|
45 | </exec>
|
---|
46 | </target>
|
---|
47 |
|
---|
48 | <!-- Determine revision and save in ${version.entry.commit.revision}-->
|
---|
49 | <target name="source-revision">
|
---|
50 | <exec append="false" output="REVISION.XML" executable="svn" dir="source" failifexecutionfails="true">
|
---|
51 | <env key="LANG" value="C"/>
|
---|
52 | <arg value="info"/>
|
---|
53 | <arg value="--xml"/>
|
---|
54 | <arg value="."/>
|
---|
55 | </exec>
|
---|
56 | <xmlproperty file="REVISION.XML" prefix="version" keepRoot="false" collapseAttributes="true"/>
|
---|
57 | <delete file="REVISION.XML" />
|
---|
58 | </target>
|
---|
59 |
|
---|
60 | </project>
|
---|
61 |
|
---|