# HG changeset patch # User Jeff Hammel # Date 1471034689 25200 # Node ID d2585c78e70fb19f3e82814127b78290f2f897c3 # Parent 194a66d765ae1ae719b4b6e6c4b2c28d61bf0e2e make -d actually work diff -r 194a66d765ae -r d2585c78e70f requestdumpster/dumpster.py --- a/requestdumpster/dumpster.py Wed Jun 01 09:09:28 2016 -0700 +++ b/requestdumpster/dumpster.py Fri Aug 12 13:44:49 2016 -0700 @@ -36,6 +36,11 @@ lines.append(request.body) body = '\r\n'.join(lines) + if self.directory: + filename = '{0}'.format(time.time()) + with open(os.path.join(self.directory, filename), 'w') as f: + f.write(body) + response = Response(content_type='text/plain', body=body) return response(environ, start_response) diff -r 194a66d765ae -r d2585c78e70f setup.py --- a/setup.py Wed Jun 01 09:09:28 2016 -0700 +++ b/setup.py Fri Aug 12 13:44:49 2016 -0700 @@ -4,7 +4,7 @@ import os -version = "0.1" +version = "0.2" dependencies = ['webob'] # allow use of setuptools/distribute or distutils