feature request for a wget -r like implementation in python3

alex23 wuwei23 at gmail.com
Thu Apr 15 21:41:11 EDT 2010


On Apr 16, 5:37 am, gert <gert.cuyk... at gmail.com> wrote:
> So I can make a recursive http download script
> My goal is a one click instruction to install and launch my projecthttp://code.google.com/p/appwsgi/

Here's Guido's take on wget:

    import sys, urllib
    def reporthook(*a): print a
    for url in sys.argv[1:]:
         i = url.rfind('/')
         file = url[i+1:]
         print url, "->", file
         urllib.urlretrieve(url, file, reporthook)

If you extend this, you can offer an easy-download-and-run python
script that does the installation you want.

But why duplicate existing effort? Why not pip[1]?

1: http://pypi.python.org/pypi/pip



More information about the Python-list mailing list