намиране на текст в папка
grep -rnw '/path/to/somewhere/' -e 'pattern'
как да се намери файл в Linux терминала.
find /path/to/folder/ -iname *file_name_portion*
linux намерете файл, съдържащ текст
# syntax
# find *</path/to/dir> -name '*<file(s)-to-search>' -exec grep '*<string-to-find>' {} /dev/null \;
# example
find 'C:/Users/JacquesK' -name '*.*' -exec grep 'Random text to find' {} /dev/null \;
намиране на текст във файл linux
grep 'word' filename
grep 'word' file1 file2 file3
grep 'string1 string2' filename
cat otherfile | grep 'something'
command | grep 'something'
command option1 | grep 'data'
grep --color 'data' fileName
намери във файла linux
grep -rnw '/path/to/somewhere/' -e 'pattern'
търсене на файлове в Linux терминала.
find /path/to/folder/ -iname *file_name_portion*
#Example
find / -iname *test*
#Output
/downloads/test_2.txt
/downloads/test_1.csv
/home/ubuntu/first_test.txt