git-time-metric / gtm

Simple, seamless, lightweight time tracking for Git
MIT License
969 stars 52 forks source link

Report by branches #90

Open morsedev opened 5 years ago

morsedev commented 5 years ago

It is possible to see a report by branches?, I mean, I want to know how much time I spent in a branch.

mschenk42 commented 5 years ago

You can pipe git log into gtm like this git log --pretty=%H |gtm report. If you can figure out how to properly filter git log for the branch you can pipe that into gtm. Looks a little tricky to narrow git log down to just branch changes. See here https://stackoverflow.com/questions/4649356/how-do-i-run-git-log-to-see-changes-only-for-a-specific-branch#4649377

fatlinesofcode commented 4 years ago

+1 for this feature