function cheat-grep(){
if [[ $1 == "" ]]; then
echo "nothing to search"
return;
fi
search_line=""
for each_input_arg in "$@"; do
if [[ $search_line == "" ]]; then
search_line=$each_input_arg
else
search_line=$search_line".*"$each_input_arg
fi
done
grep -r $search_line -i -A 2 $HOME_PROJECTS/cheat-sheet/*.md $HOME_PROJECTS/bash-example/*
}
forked from cherkavi/cheat-sheet
-
Notifications
You must be signed in to change notification settings - Fork 0
khahoangvan/cheat-sheet
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
collection of cheat sheets
Resources
Security policy
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published