Tim Brigham
Tim Brigham

Reputation: 574

Select a single file history out of Git?

I use Git to keep a version history of config files. For this purpose there are no branches. I keep a ton of these in the same repository, some of which have sensitive data. I need to zip up and send a history of a single file out of this repository to a vendor to diagnose a problem. How do I do so?

Upvotes: 2

Views: 42

Answers (1)

blr
blr

Reputation: 968

  • git log -p <file> generates all the patches used for a file.
  • git blame <file> shows what revision and author last modified each line of a file. docs
  • gitk <file> gives you better visualization of the changes. docs

Upvotes: 2

Related Questions