3 rm -f osmmap_def.h.wiki
5 for file in item_def.h.wiki osmmap_def.h.wiki
9 * Navit, a modular navigation system.
10 * Copyright (C) 2005-2008 Navit Team
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU Library General Public License
14 * version 2 as published by the Free Software Foundation.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Library General Public License for more details.
21 * You should have received a copy of the GNU Library General Public
22 * License along with this program; if not, write to the
23 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
24 * Boston, MA 02110-1301, USA.
27 /* This file is generated from http://wiki.navit-project.org/index.php/Item_def.h, do not edit it, edit the wiki page instead */
31 wget -O - "http://wiki.navit-project.org/index.php/Item_def.h?action=edit" |
32 awk '/<textarea/,/<\/textarea/ { print $0 }' |
34 sed -e 's/^| *//' -e 's/ *$//' -e 's/ *|/|/g' -e 's/| */|/g' -e 's/||/|/g' |
35 while read id item description osmtags dummy
37 if [[ "$id" == colspan=* ]]
39 echo "/* $item */" >>item_def.h.wiki
44 echo "ITEM($item)" >>item_def.h.wiki
46 echo "ITEM2($id,$item)" >>item_def.h.wiki
47 if [ "$id" == "0x80000000" ]
52 if [[ -n "$osmtags" ]]
54 for osmtag in $(echo "$osmtags" | sed 's/<br\/>/|/g')
56 printf '"%s\t%s\t%s\t%s\\n"\n' $type $osmtag $item >> osmmap_def.h.wiki