re: How do you make it easier to search through version control for deleted code? VIEW POST


Oh man, this is a tough one. I don't know how to make it easier. I think @kimberlypilbeam has outlined some really good thoughts. I especially like the thoughts on tagging. As I've used that approach when pushing out weekly builds of an application.

What I can share are some things I do in my own workflow. While I mainly use git on the command line, searching for specific commits is just easier visually. For this, I use a git app called GitUp on macOS. Super lightweight and open source. It's also has a command line tool to quickly start it up.

Other than that, if I know the specific file the code was deleted on and just want to see the history of that file to track down the code, I run git log -p path/to/filename which helps isolate my search down to at least the file.

code of conduct - report abuse