Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

monitor log file for string

tail -fn0 logfile | 
while read line ; do
        echo "$line" | grep "pattern"
        if [ $? = 0 ]
        then
                ... do something ...
        fi
done
Comment

PREVIOUS NEXT
Code Example
Shell :: windows git bash gradle bad characters 
Shell :: Running setup.py install for pyahocorasick ... error 
Shell :: ubuntu aide compare file structure 
Shell :: bash search multiple string in on line 
Shell :: start cinnamon from command line redhat 7 
Shell :: windows connect to github using putty agent 
Shell :: fslmaths masking 
Shell :: fslmaths edge outline 
Shell :: Could NOT find Boost (missing: filesystem) 
Shell :: tableview javafx mysql repeats data 
Shell :: allocate memeory in hpc 
Shell :: git murge branch with master 
Shell :: camera from usb pi 3 
Shell :: npm unpublish versino 
Shell :: how to install asterisk 16 on debian 10 
Shell :: how to count size dir with cli linux 
Shell :: copy specific files only from directories 
Shell :: publish repositry 
Shell :: $OuTree = Get-ADOrganizationalUnit -Filter * -SearchBase 
Shell :: install kivyMD from git 
Shell :: vmware mukesh003 
Shell :: Não é possível excluir uma partição protegida sem o parâmetro de proteção forçada definido. 
Shell :: linux verzeichnis erstellen 
Shell :: osp it digital solutions 
Shell :: how to know tachyons version 
Shell :: remove deb repository 
Shell :: logstash automatic config reload 
Shell :: anydesk upgrade sources list 
Shell :: ASUS Router NVRAM script 
Shell :: remove white space from file and display result 
ADD CONTENT
Topic
Content
Source link
Name
2+7 =