interceptty-nicedump
来自「intercept tty is using for listening a U」· 代码 · 共 57 行
TXT
57 行
#!/usr/bin/perl# $Id: interceptty-nicedump,v 7.1 2000/05/03 04:41:24 sgifford Exp $#| = 1;while (<>){ chomp; s/^(.)\s+//; if ($1 eq "<") { if ($dumpdir eq ">") { &dumpnow; } $dumpdir = $1; } elsif ($1 eq ">") { if ($dumpdir eq "<") { &dumpnow; } $dumpdir = $1; } /^..(..)/; $hexchar = $1; $bufhex .= " ".$hexchar; if (/\((.*)\)/) { $bufasc .= "$1"; } else { $bufasc .= " "; } $bufchars++; if ($hexchar eq "0a") { &dumpnow }# print "Char $bufchars: hex is '$bufhex', asc is '$bufasc', dumpdir is '$dumpdir'\n"; if ($bufchars >= 10) { &dumpnow; }}&dumpnow;sub dumpnow{ return if ($bufchars == 0); printf "%-s %-30s | %-10s\n",$dumpdir,$bufhex,$bufasc; $bufchars=0; $bufhex=""; $bufasc="";}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?