https://github.com/muety/gitcount
A command-line tool to estimate the time spent on a git project, based on a very simple heuristic
https://github.com/muety/gitcount
devtools git golang
Last synced: 7 months ago
JSON representation
A command-line tool to estimate the time spent on a git project, based on a very simple heuristic
- Host: GitHub
- URL: https://github.com/muety/gitcount
- Owner: muety
- License: mit
- Created: 2018-09-28T04:49:31.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-02T07:45:13.000Z (almost 7 years ago)
- Last Synced: 2025-03-27T11:21:10.244Z (8 months ago)
- Topics: devtools, git, golang
- Language: Go
- Size: 11.7 KB
- Stars: 24
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# gitcount
[](https://saythanks.io/to/n1try)
A command-line tool to estimate the time spent on a git project, based on a very simple heuristic, inspired by [kimmobrunfeldt/git-hours](https://github.com/kimmobrunfeldt/git-hours).
### Assumptions:
* Commits with a time difference less than 2 hours are considered to be in one coding session
* A multiple (x3) of the average time between commits in all sessions is added to the very first commit of every session
## Example
```sh
$ gitcount -dir .
Project root: /home/ferdinand/dev/mininote
mail@ferdinand-muetsch.de: 13.06 hours
exorcismo@gmail.com: 0.95 hours
noreply@github.com: 3.80 hours
btbtravis@gmail.com: 1.11 hours
kiantrue@gmail.com: 0.95 hours
fmuetsch@inovex.de: 0.00 hours
---------
Total: 19.86 hours
```
## Example using Docker
```sh
$ docker run --rm -it -v `pwd`:/repo gitcount/gitcount:0.0.2
Project root: /repo
mail@ferdinand-muetsch.de: 1.73 hours
noreply@github.com: 0.65 hours
u5.horie@gmail.com: 0.65 hours
---------
Total: 3.03 hours
```
## Requirements
* Go to be installed
## How to use?
1. `go get github.com/n1try/gitcount`
2. `gitcount` or `gitcount -dir /some/project/path`
## License
MIT @ [Ferdinand Mütsch](https://muetsch.io)