Welcome to the Linux Foundation Forum!

command line to search files and save output to a file

Hi all,

Please advise the command line to find all files containing a string "Deny from all" on ./ and save all files found to a file (which not created yet)




  • I think try:

    grep -l 'Deny from all' /home/ > /tmp/list.txt

    /tmp/list.txt is of course can be changed to any file name or folder name you wish

Sign In or Register to comment.