Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

linux find text in files recursively -include

# look for airflow Variable usage recursively in it's homepath
# include only python and sql files in the search
grep --include=*.{py,sql} -rnw /home/airflow -e 'Variable'

# shows how to use exclude... it'll skip data or log files
grep --exclude=*.{data,log} -rnw . -e 'Variable'
Comment

linux search for a given string in all files recursively

$ grep -r "String to be searched goes here" *
Comment

find file with text recursively

grep --include=*.{c,h} -rnw '/path/to/somewhere/' -e "pattern"
Comment

PREVIOUS NEXT
Code Example
Shell :: git diff only file names 
Shell :: Undo commit and keep all files staged 
Shell :: adonis migration run 
Shell :: Viewing content in files with dashed filenames 
Shell :: how to install steam on fedora 
Shell :: certbot expand certificate 
Shell :: install node js from ubuntu 
Shell :: install cpanm 
Shell :: powershell connect to serial port 
Shell :: Failed to start firewalld - dynamic firewall daemon. 
Shell :: foreach powershell 
Shell :: install bootstrap angular 
Shell :: start docker in fedora 
Shell :: git pull remote branch 
Shell :: expo upgrade reset 
Shell :: elevated privileges windows 10 
Shell :: switch zsh to bash 
Shell :: unstage staged files git 
Shell :: ssh no strict checking 
Shell :: how to delete a non empty directory in linux 
Shell :: wsl restart 
Shell :: tailwind nodejs 
Shell :: powershell make file 
Shell :: add local project to bitbucket 
Shell :: renaming a docker container 
Shell :: permission exec linux 
Shell :: docker logs last few lines 
Shell :: powershell delete folder contents 
Shell :: install rsync 
Shell :: install leafpad ubuntu 2021 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =