pytracediff: implement pager ('less') invocation internally
authorMatti Hamalainen <ccr@tnsp.org>
Mon, 20 Jun 2022 11:20:09 +0000 (14:20 +0300)
committerMatti Hämäläinen <ccr@tnsp.org>
Tue, 28 Jun 2022 11:40:58 +0000 (11:40 +0000)
commitaab5d176b83fe8d5bbf5502c38c4aa0a8558a22f
tree83bbc125dd9261d470cf81b573da1660b39b6607
parent95fc0e1b7c5f8c8df7b4b3c719597e595d331725
pytracediff: implement pager ('less') invocation internally

In order to get rid of the ntracediff.sh wrapper script, implement
invocation of 'less' internally, if the stdout is determined to
be a tty. Otherwise just print out normally.

Signed-off-by: Matti Hamalainen <ccr@tnsp.org>
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17135>
src/gallium/tools/trace/pytracediff.py