mirror of
https://github.com/tj/git-extras.git
synced 2026-09-10 15:36:21 -04:00
21 lines
408 B
Bash
Executable file
21 lines
408 B
Bash
Executable file
#!/bin/sh
|
|
|
|
files=`git ls-files`
|
|
|
|
echo
|
|
echo " file commits"
|
|
echo
|
|
|
|
for file in $files; do
|
|
commits=`git log --oneline $file | wc -l`
|
|
color='90'
|
|
|
|
test $commits -gt 10 && color='33'
|
|
test $commits -gt 25 && color='93'
|
|
test $commits -gt 50 && color='32'
|
|
test $commits -gt 100 && color='92'
|
|
|
|
printf " \033[${color}m%-45s %d\033[0m\n" $file $commits
|
|
done
|
|
echo
|