(Arne Babenhauserheide)
2011-10-20: --force also forces a full reupload. --force also forces a full reupload.
diff --git a/static.py b/static.py --- a/static.py +++ b/static.py @@ -323,7 +323,7 @@ def addrepo(ui, repo, target): ui.popbuffer() -def upload(ui, repo, target, ftpstring): +def upload(ui, repo, target, ftpstring, force): """upload the repo to the FTP server identified by the ftp string.""" user, password = ftpstring.split("@")[0].split(":") serverandpath = "@".join(ftpstring.split("@")[1:]) @@ -395,7 +395,7 @@ def upload(ui, repo, target, ftpstring): else: _ftpdircache.add(sd) - if not serverfile in ftp.nlst(serverdir): + if not serverfile in ftp.nlst(serverdir) or force: ui.status("uploading ", serverfile, " because it is not yet online.\n") ftp.storbinary("STOR "+ serverfile, f) else: @@ -423,7 +423,7 @@ def static(ui, repo, target=None, **opts addrepo(ui, repo, target) if opts["upload"]: # upload the repo - upload(ui, repo, target, opts["upload"]) + upload(ui, repo, target, opts["upload"], opts["force"])