summaryrefslogtreecommitdiffhomepage
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/changeset30
1 files changed, 30 insertions, 0 deletions
diff --git a/scripts/changeset b/scripts/changeset
new file mode 100755
index 0000000..d3dee3d
--- /dev/null
+++ b/scripts/changeset
@@ -0,0 +1,30 @@
1#! /bin/bash
2
3OSM_USER_PASSWD=$(cat ~/git/settings/token/osm)
4#server=https://master.apis.dev.openstreetmap.org
5server=https://api.openstreetmap.org
6comment="change is_in format"
7
8for i in "$@"
9do
10case $i in
11 -s)
12 lon_col=0; lat_col=1
13 shift;;
14
15 *)
16 csv=$i
17 shift;;
18esac
19done
20
21info="<osm>
22 <changeset>
23 <tag k='comment' v='$comment'/>
24 </changeset>
25 </osm>
26 "
27
28echo $info |\
29curl -u $OSM_USER_PASSWD -i --upload-file - $server/api/0.6/changeset/create
30