From 460d8870ec370e4e0bbf83cd7358c7175def6f37 Mon Sep 17 00:00:00 2001 From: Christopher Haster Date: Mon, 17 Mar 2025 13:08:50 -0500 Subject: [PATCH] scripts: Adopted -c for --cat shortform This avoids conflicts with -z/--depth, which will likely be an issue for dbgbmap.py. --- scripts/codemap.py | 2 +- scripts/plot.py | 3 ++- scripts/tailpipe.py | 2 +- scripts/tracebd.py | 2 +- scripts/treemap.py | 3 ++- scripts/watch.py | 2 +- 6 files changed, 8 insertions(+), 6 deletions(-) diff --git a/scripts/codemap.py b/scripts/codemap.py index bb8fe06e..f0d997aa 100755 --- a/scripts/codemap.py +++ b/scripts/codemap.py @@ -1523,7 +1523,7 @@ if __name__ == "__main__": action='store_true', help="Show the first n lines.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument( diff --git a/scripts/plot.py b/scripts/plot.py index 05055972..ed89abc4 100755 --- a/scripts/plot.py +++ b/scripts/plot.py @@ -143,6 +143,7 @@ def openio(path, mode='r', buffering=-1): else: return open(path, mode, buffering) +# keep-open stuff if inotify_simple is None: Inotify = None else: @@ -2006,7 +2007,7 @@ if __name__ == "__main__": action='store_true', help="Show the first n lines.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument( diff --git a/scripts/tailpipe.py b/scripts/tailpipe.py index 48f21efc..72029558 100755 --- a/scripts/tailpipe.py +++ b/scripts/tailpipe.py @@ -178,7 +178,7 @@ if __name__ == "__main__": help="Show this many lines of history. 0 uses the terminal " "height. Defaults to 5.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument( diff --git a/scripts/tracebd.py b/scripts/tracebd.py index 2214e41f..67d7a329 100755 --- a/scripts/tracebd.py +++ b/scripts/tracebd.py @@ -1200,7 +1200,7 @@ if __name__ == "__main__": action='store_true', help="Show the first n lines.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument( diff --git a/scripts/treemap.py b/scripts/treemap.py index ef896273..938e5ee5 100755 --- a/scripts/treemap.py +++ b/scripts/treemap.py @@ -53,6 +53,7 @@ def openio(path, mode='r', buffering=-1): else: return open(path, mode, buffering) +# keep-open stuff if inotify_simple is None: Inotify = None else: @@ -1374,7 +1375,7 @@ if __name__ == "__main__": action='store_true', help="Show the first n lines.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument( diff --git a/scripts/watch.py b/scripts/watch.py index 59024e04..de540b14 100755 --- a/scripts/watch.py +++ b/scripts/watch.py @@ -285,7 +285,7 @@ if __name__ == "__main__": action='store_true', help="Show the first n lines.") parser.add_argument( - '-z', '--cat', + '-c', '--cat', action='store_true', help="Pipe directly to stdout.") parser.add_argument(