aboutsummaryrefslogtreecommitdiffhomepage
path: root/scripts/osm/osm.api.changeset.create
blob: 1f17334d8520a6ff1343156be50acb53e767e13e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh

echo -n "type comment: "
read comment

info="<osm>
        <changeset>
          <tag k='comment' v='$comment'/>
          <tag k='bot' v='yes'/>
        </changeset>
      </osm>
     "

echo $info |\
curl -u $OSM_USER_PASSWD --upload-file - $OSM_API/changeset/create |\
tee /dev/tty |\
tail -1 | read changeset_id

echo " copied into clipboard"
echo "changeset created, check $OSM_SERVER/changeset/$changeset_id"
echo $changeset_id | xsel -ib