Pagina 1 di 1

Slackware mirror with Wget?

Inviato: dom 5 mar 2006, 16:57
da victorche
I have a simple question... I have a local mirror of Slackware Current on my HDD. For personal use ;)
It was made with wget, using this command:

Codice: Seleziona tutto

wget -rL -nH --cut-dirs=3 -N http://mirrors.easynews.com/linux/slackware/slackware-current/ -R "*.htm*","*.php" -X/linux/slackware/slackware-current/pasture,/linux/slackware/slackware-current/source
These wget options are OK and I've found the right opcions after one hour of trying. The problem is...
Where there is an updated package, wget finds it and downloads it.
But it doesn't remove the old one.

Any ideas?
:roll:

Re: Slackware mirror with Wget?

Inviato: dom 5 mar 2006, 19:40
da absinthe
victorche ha scritto:I have a simple question... I have a local mirror of Slackware Current on my HDD. For personal use ;)
It was made with wget, using this command:

Codice: Seleziona tutto

wget -rL -nH --cut-dirs=3 -N http://mirrors.easynews.com/linux/slackware/slackware-current/ -R "*.htm*","*.php" -X/linux/slackware/slackware-current/pasture,/linux/slackware/slackware-current/source
These wget options are OK and I've found the right opcions after one hour of trying. The problem is...
Where there is an updated package, wget finds it and downloads it.
But it doesn't remove the old one.

Any ideas?
:roll:
use a bash script that runs wget, scans the local mirror for new packages, searches an old version of a package and deletes it.

M

Inviato: dom 5 mar 2006, 22:29
da victorche
Thanks!
But if you type
wget --help
You'll see one option there:
--mirror
It means that wget should be able to do this. And to do this automatically. Removing of old packages I mean.
Maybe you'll ask why I am not using this option... Well, I am not using --mirror because I want some fine tuning here... Like removing of all .html files. They are useless in my case. Also I don't need /pasture and /source directories... And I want to run wget in one directory which I want to be the top-level directory of my mirror. That's why I am using --cut-dirs=3 option.
If not, wget will make a directory like mirrors.name_of_the_domain.com, then a subdirectory named linux, then another one named slackware etc.
My point was.... Having the option --mirror makes me think there is a way to make wget to delete old packages and replace them with the new ones.
To delete the old packages one by one manually makes this wget option useless :/