Compare commits
No commits in common. "892049ea1568c6dd70c9ac9cfd3591e82bac4bc5" and "b58a02bf4a15bbb0ec18cbd1ea92094d63ffaf02" have entirely different histories.
892049ea15
...
b58a02bf4a
@ -3,7 +3,7 @@
|
|||||||
# WARNING: This script is not yet production ready. The slightest error in the wikipage can throw it off. Handle with care.
|
# WARNING: This script is not yet production ready. The slightest error in the wikipage can throw it off. Handle with care.
|
||||||
|
|
||||||
json=`curl 'https://wiki.linux-forks.de/mediawiki/api.php?action=query&prop=revisions&rvprop=content&format=json&titles=Maps:Streets'`
|
json=`curl 'https://wiki.linux-forks.de/mediawiki/api.php?action=query&prop=revisions&rvprop=content&format=json&titles=Maps:Streets'`
|
||||||
data=`echo $json | json_reformat | sed -e 's/\\\\n//g' -n -e 's/begin:mapdata\([^}]\+\)/\1/gp' | sed -e "s/|-|/}/g"`
|
data=`echo $json | json_reformat | sed -e 's/\\\\n//g' -n -e 's/.*begin:mapdata\([^}]\+\).*/\1/p' | sed -e "s/|-|/}/g"`
|
||||||
|
|
||||||
echo "["
|
echo "["
|
||||||
export IFS="}"
|
export IFS="}"
|
||||||
@ -24,6 +24,5 @@ for entry in $data; do
|
|||||||
},"
|
},"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
export IFS=" "
|
|
||||||
echo "{}"
|
echo "{}"
|
||||||
echo "]"
|
echo "]"
|
||||||
|
Loading…
Reference in New Issue
Block a user