79110296

Date: 2024-10-21 13:41:19
Score: 1
Natty:
Report link

What you can try to use a combination of grep and sed in a shell script to get the value of PID from your txt file.

#!/bin/bash

grep -o 'pid: [0-9]\+' /tmp/log.txt | while read -r line; do
  echo "$line"
done
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Starts with a question (0.5): What you can
  • Low reputation (0.5):
Posted by: Shelton Liu