Rozdiely pre scripts/php/sk-nic/download.sh medzi verziami 1.3 a 1.4
| verzia 1.3, 2006/08/16 12:12:20 |
verzia 1.4, 2007/03/14 00:31:13 |
|
|
| # 2006-08-13 - created |
# 2006-08-13 - created |
| # |
# |
| |
|
| # $Platon$ |
# $Platon: scripts/php/sk-nic/download.sh,v 1.3 2006-08-16 12:12:20 nepto Exp $ |
| |
|
| # |
# |
| # Put this into your crontab, it will run this script every morning at 6:15 am: |
# Put this into your crontab, it will run this script every morning at 6:15 am: |
| Riadok 32 INPUT_FILE="https://www.sk-nic.sk/docume |
|
| Riadok 32 INPUT_FILE="https://www.sk-nic.sk/docume |
|
| OUTPUT_FILE="data/sk-nic.`date '+%F'`.csv"; |
OUTPUT_FILE="data/sk-nic.`date '+%F'`.csv"; |
| WORK_FILE="domeny.tgz"; |
WORK_FILE="domeny.tgz"; |
| WGET="`which wget`"; |
WGET="`which wget`"; |
| |
PHP="`which php`"; |
| |
|
| cd "`dirname $0`"; |
cd "`dirname $0`"; |
| |
|
| Riadok 55 if [ "$?" -ne 0 ]; then |
|
| Riadok 56 if [ "$?" -ne 0 ]; then |
|
| exit $?; |
exit $?; |
| fi; |
fi; |
| |
|
| |
if [ -z "$PHP" ]; then |
| |
echo "$PREFIX_ERR: php binary not found, no import was done"; |
| |
exit 4; |
| |
fi; |
| |
|
| |
# and now real import |
| |
$PHP sk-nic.php "$OUTPUT_FILE" |
| |
|
Platon Group <platon@platon.sk> http://platon.sk/
|
|