Feb-09-2017, 02:25 PM
I have tried to search a string from a file and it worked.
>>> if 'finish' in open('/home/user/python/drsync-test-aix.log').read():
... print "true"
...
true
But I am unable to find how to search the same string in multiple files that end with .log extension, can someone help me
>>> if 'finish' in open('/home/user/python/drsync-test-aix.log').read():
... print "true"
...
true
But I am unable to find how to search the same string in multiple files that end with .log extension, can someone help me