linux - Linux 使用“watch”和 tqdm 进行日志监控
问题描述
这是一个正常的输出:
$grep -E '.*status' api_logging.log | tqdm --total=808 --desc='TOTAL'|wc -l
TOTAL: 100%|█████████████████████████████████████████| 808/808 [00:00<00:00, 529365.45it/s]
808
但我想继续监控:如何隐藏第一行输出?
$watch -n 1 grep -E '.*status' api_logging.log | tqdm --total=808 --desc='TOTAL'|wc -l
TOTAL: 0%| | 0/808 [00:00<?, ?it/s]
TOTAL: 100%|████████████████████████████████████| 808/808 [00:00<00:00, 327466.81it/s]
解决方案
推荐阅读
- sql - 来自不同行的两个值之间的差异按列分组
- excel - VBA过滤带有变量的列
- sql - 通过输入字符串 SQL 查找电话号码
- c# - Visual Studio 2019 C# Hotkey 用于查看函数的应用
- java - 空布局未显示在 Java 中的边框布局上
- azure - 如何在 Azure DevOps Pipelines 的另一个存储库中使用引用脚本的模板?
- assembly - 为什么引导加载程序的编译提到错误 TIMES 值 -9 为负数?
- sql - 如何在 (hive) sql 中获取最小/最大值_within_ ntile(10)?
- flutter - 如何用墨水瓶包装,这样一排中的每个单独的按钮都可以在颤动中工作
- javascript - 将进度条值添加到进度条元素的中心