Merge pull request #176 from SA7BNT/patch-1

Update dbupdate.sh
This commit is contained in:
Kim - DG9VH 2018-05-15 21:43:38 +02:00 committed by GitHub
commit 363fac1718
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,6 +1,6 @@
#!/bin/bash
echo Downloading DMR-IDs from MARC-database
curl 'https://www.dmr-marc.net/static/users.csv' 2>/dev/null | sed -e 's/\t//g' | awk -F"," '/,/{gsub(/ /, "", $2); printf "%s;%s;%s\n", $1, $2, $3}' | sed -e 's/\(.\) .*/\1/g' > dmrids.dat
curl 'https://radioid.net/static/users.csv' 2>/dev/null | sed -e 's/\t//g' | awk -F"," '/,/{gsub(/ /, "", $2); printf "%s;%s;%s\n", $1, $2, $3}' | sed -e 's/\(.\) .*/\1/g' > dmrids.dat
echo Removing IDs from local database
echo -e 'delete from callsign where 1;' | sqlite3 callsigns.db