diff --git a/Cookbook.md b/Cookbook.md index d3dd495..59b7b18 100644 --- a/Cookbook.md +++ b/Cookbook.md @@ -1,3 +1,11 @@ +* bad code search tool: + +```bash +bcs() { for file in `grep -l $1 $(git ls-tree -r master --name-only)`; do echo $file: ; highlight --force --line-numbers -O xterm256 --stdout $file | grep -C 5 $1 --label=$file | perl -pne s%^--\$%$file:%; done } + +bcs Player +``` + * sizes of things in C#: ``` sizeof(Vector2) = 8