Skip to content
Myr

Fixed a bug in tempfile pager. This fixes #107

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Armin Ronacher · committed by Armin Ronacher · parent 3982fbe · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:click/_termui_impl.py+1 added-1 removed
277 unmodified lines
278def _tempfilepager(text, cmd):279 """Page through text by invoking a program on a temporary file."""280 import tempfile281 filename = tempfile.mktemp()282 with open_stream(filename, 'w')[1] as f:282 with open_stream(filename, 'w')[0] as f:283 f.write(text)284 try:285 os.system(cmd + ' "' + filename + '"')286 finally:
185 unmodified lines