Frequently when I’m writing code I want to quickly find all references to a particular function/method/class/variable within the entire code base. Many IDEs provide this feature, but most of those programs are too bulky for me, I typically program in Vim or Gedit. So I wrote this bash script which greps all the files in the current directory for a specific term and pretty prints the output with filename and line numbers. It lets you limit your search to files with a specific extension with the -e option, or a different directory with the -d option. Anyway, this is all very simple, what I want to talk about is running this straight from Gedit with a single key press and getting sexy output, like this:
Running tool: GrepAll ./Connecter.py: 352: self.encoder.add_neighbor(self.id, AESKey(key, iv)) 356: self.encoder.add_neighbor(self.id, self.tmp_aes) ./Encoder.py: 154: def add_neighbor(self, nid, aeskey):
Right there in the bottom pane.
(more…)


