Last updated January 20, 2013.
The git blame command can be used to determine when a certain change was made. This document will explain how to use this functionality on the commandline and on Drupal's git repository browser at drupalcode.org.
Using git blame on the commandline
(Add instructions here)
Using git blame on drupalcode.org
- Go to http://drupalcode.org/project/drupal.git.
- Click on "tree."
- Browse the file tree to the file where your function or hook definition lives, e.g. field.api.php. (You can see this information on api.d.o if you are not sure.)
- Click the "blame" link at the top.
- Use browser to search on the page for the name of your hook or function, e.g.
- Click on the commit reference in the margin near the lines you wish to investigate.
- This will take you to the commit where these lines were last changed. For Drupal core, the commit message will include the issue ID, so you can look up that issue to learn more about the change.
- If that commit doesn't include the change you are looking for, continue browsing through the git history by navigating to the parent commit using the link at the top of the page.
- Click on the "tree" link for that parent and then repeat from step 3.