# # # patch "TODO" # from [3b9eeae8ebfbf95f7a2c47507f315c2c88255d90] # to [a09b5e19f815c53e0e1b3c2458cece5169fddae5] # # patch "monotone.py" # from [fe810be90d92a76684a2035d9e7aa6b1a77347c9] # to [a42bedb3c12adf7755c278bacf305396d5029055] # # patch "wrapper.py" # from [7444ff00e621412e16056b61cc1e9663219b417b] # to [801e35f2ddfbe6604b69ae4222c4ae6e91f5dbc8] # ============================================================ --- TODO 3b9eeae8ebfbf95f7a2c47507f315c2c88255d90 +++ TODO a09b5e19f815c53e0e1b3c2458cece5169fddae5 @@ -5,6 +5,8 @@ a link to each ancestor in which the file is different from the revision we are displaying + * getfile.py is setting the wrong content-disposition header + TODO: * monotone automate stdio client ============================================================ --- monotone.py fe810be90d92a76684a2035d9e7aa6b1a77347c9 +++ monotone.py a42bedb3c12adf7755c278bacf305396d5029055 @@ -38,7 +38,6 @@ self.mt = mt self.dbfile = dbfile self.command = "%s --db=%s automate stdio" % (self.mt, pipes.quote(self.dbfile)) - #self.command = "/bin/cat" self.process = None def __del__(self): if self.process: ============================================================ --- wrapper.py 7444ff00e621412e16056b61cc1e9663219b417b +++ wrapper.py 801e35f2ddfbe6604b69ae4222c4ae6e91f5dbc8 @@ -1,9 +1,10 @@ from mod_python import apache,psp,util import config import monotone import mimetypes import urllib +import os.path from monotone import Monotone import template import tarfile @@ -27,7 +28,7 @@ mime_type = None if form.has_key('path'): if mime_type == None: mime_type = mimetypes.guess_type(form['path'])[0] - req.headers_out["Content-Disposition"] = "attachment; filename=%s" % urllib.quote(form['path']) + req.headers_out["Content-Disposition"] = "attachment; filename=%s" % urllib.quote(os.path.split(form['path'])[-1]) if mime_type == None: mime_type = "text/plain" req.content_type = mime_type req.write(mt.file(id))