git-time-metric / gtm

Simple, seamless, lightweight time tracking for Git

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

What does `[m]` and `[r]` mean ?

chenbotao828 opened this issue · comments

Hi everybody! I have one simple question about gtm output, in codes below:

$ gtm status

       20m 40s  53% [m] plugin/gtm.vim
       18m  5s  46% [r] Terminal
           15s   1% [m] .gitignore
       39m  0s          gtm-vim-plugin 

What does [m] and [r] mean ?
Thanks if anyone can explain that!

Good question, m is for modified and r is for read.

Thanks
Another question:
Why a file ,untracked by git, have a '[r]' sign, which means read ,is this a bug?
For example:

$ gtm status
$ gtm status

       20m 40s  53% [r] plugin/gtm.vim
       18m  5s  46% [r] T
in/gtm.vim
       18m  5s  46% [r] Terminal
           15s   1% [m] .gitignore
       39m  0s          gtm-vim-plugin 

'plugin/gtm.vim' is untracked

That's by design. We use git to determine the file status. If it's not in the git repo we default to r.