Last active
January 7, 2021 08:16
-
-
Save rasmusmerzin/f22469037999c35cce1319f33d8880d4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# inspect codebase for occurances | |
keyword=$1 | |
shift | |
eval $( | |
grep "$keyword" "$@" -n | while read -r line | |
do | |
fl=${line%%:*} | |
ln=${line#*:} | |
ln=${ln%%:*} | |
echo "vim +$ln $fl -R" | |
done | paste -sd';' | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment