Andrea Ganduglia wrote:

On 10/5/05, Maurizio Manetti <[EMAIL PROTECTED]> wrote:
Andrea Ganduglia wrote:

Ciao, avrei la necessita` di scrivere uno script di bash che faccia questo:

if [ IL FILE http://www.qualchesito.com/file.ext ESISTE? ]; then

wget file_remoto

elif [ IL MIRROR DI QUESTO FILE ESISTE? ]; then

wget file_mirror

fi

man wget

--spider
When invoked with this option, Wget will behave as a Web spider,
which means that it will not download the pages, just check that
they are there. For example, you can use Wget to check your book‐
marks:

wget --spider --force-html -i bookmarks.html


qui lo script da adattare
----------------------------------------------------------------------------------------------

if [ `wget --spider http://www.qualchesito.com/file.ext` ]; then

        wget http://www.qualchesito.com/file.ext

elif [ `wget --spider http://www.qualchesito.com/Mirror` ]; then

        wget http://www.qualchesito.com/Mirror

fi
--------------------------------------------------------------------

ciao
MaX





                
______________________________________________ Renovamos el Correo Yahoo! Nuevos servicios, m�s seguridad http://correo.yahoo.es


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Rispondere a