You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+56-18Lines changed: 56 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,10 @@ GTM is automatic, seamless and lightweight. There is no need to remember to sta
9
9
10
10
Your time metrics are stored locally with the repository as [Git notes](https://git-scm.com/docs/git-notes). If you want to share your data, it can be pushed and fetched to and from the remote repository. Other GTM users on your team can do the same. This provides you the ability to see time metrics for the entire team.
11
11
12
+
Here are some examples of insights GTM can provide you.
13
+
14
+
**Git commits with time spent**
15
+
12
16
```
13
17
9361c18 Rename packages
14
18
Sun Jun 19 09:56:40 2016 -0500 Michael Schenk 34m 30s
@@ -19,6 +23,9 @@ Sun Jun 19 09:43:47 2016 -0500 Michael Schenk 1h 16m 0s
19
23
792ba19 Require a 40 char SHA commit hash
20
24
Thu Jun 16 22:28:45 2016 -0500 Michael Schenk 1h 1m 0s
21
25
```
26
+
27
+
**Git commits with detailed time spent by file**
28
+
22
29
```
23
30
b2d16c8 Refactor discovering of paths when recording events
24
31
Thu Jun 16 11:08:47 2016 -0500 Michael Schenk
@@ -32,6 +39,9 @@ Thu Jun 16 11:08:47 2016 -0500 Michael Schenk
32
39
20s [r] metric/manager.go
33
40
49m 0s
34
41
```
42
+
43
+
**Timeline of time spent by day**
44
+
35
45
```
36
46
0123456789012345678901234
37
47
Fri Jun 24 * 22m 0s
@@ -41,19 +51,20 @@ Mon Jun 27 * 4m 0s
41
51
Tue Jun 28 ** 1h 36m 0s
42
52
6h 58m 0s
43
53
```
54
+
44
55
# Getting Started
45
56
46
-
####Install the latest GTM release
57
+
## Install the latest GTM release
47
58
48
-
**Mac OS X***
59
+
**Mac OS X**
49
60
50
-
The simplest way to install is to use [Homebrew](http://brew.sh).
61
+
The simplest way to install is to use [Homebrew](http://brew.sh) - *Recommended*.
51
62
```
52
63
brew tap git-time-metric/gtm
53
64
brew install gtm
54
65
```
55
66
56
-
**Linux or Mac OS X***
67
+
**Linux or Mac OS X**
57
68
58
69
- Download the pre-build executable from [here](https://github.com/git-time-metric/gtm/releases/latest)
59
70
- Extract the tar file to /usr/local/bin, `tar -C /usr/local/bin -zxf <file.tar.gz>`
@@ -62,9 +73,9 @@ brew install gtm
62
73
- Stay tuned, we will soon be distributing Linux packages
63
74
64
75
65
-
**Windows***
76
+
**Windows**
66
77
67
-
*Option 1*
78
+
*Option 1 - Recommended*
68
79
69
80
- Download and run the windows installer from [here](https://github.com/git-time-metric/gtm/releases/latest)
70
81
@@ -75,30 +86,53 @@ brew install gtm
75
86
- Extract the tar file and install the `gtm.exe` in `c:\Program Files (x86)\gtm`
76
87
- The release archive is in a tar format, here are some options documented on the Haskell site for [unpacking in Windows](https://wiki.haskell.org/How_to_unpack_a_tar_file_in_Windows)
77
88
78
-
**Note** - when running GTM in Windows, Mac OS X or Linux, if you recieve an error about something related to [libssh2](https://www.libssh2.org), please create an issue so we can look into it.
79
-
80
-
#### Install a GTM plug-in for your favorite editor
89
+
## Install a GTM plug-in for your favorite editor
81
90
82
-
Currently we have plug-ins for Atom, Sublime and Vim. More will be added shortly and we are looking for others to contribute plug-ins.
91
+
Currently there are plug-ins for Atom, Sublime and Vim. More will be added shortly and we are looking for others to contribute plug-ins.
Spend some time editing your files. Check your progress with `gtm status`.
98
116
99
-
#### Commit your work
117
+
```
118
+
> gtm status
119
+
120
+
36m 0s [m] README.md
121
+
36m 0s
122
+
```
123
+
124
+
## Commit your work
100
125
101
126
When you are ready, commit your work like you usually do. GTM will automatically save the time spent associated with your commit. To check the time of the last commit type `gtm report`.
127
+
```
128
+
> gtm report
129
+
130
+
6620f55 Add more help content to README
131
+
Sun Jul 03 16:57:15 2016 -0500 Michael Schenk
132
+
133
+
40m 0s [m] README.md
134
+
40m 0s
135
+
```
102
136
103
137
# Command Line Interface
104
138
@@ -134,7 +168,7 @@ status
134
168
135
169
For general help `gtm --help` and for help on a command `gtm --help <command>`
git log --pretty=%H --since="8 days ago" | gtm report
161
195
```
162
196
163
-
**Pushing and fetching notes to and from the remote repository**
197
+
The `git log` command provides some nice options for [limiting and filtering output](https://git-scm.com/book/en/v2/Git-Basics-Viewing-the-Commit-History#Limiting-Log-Output). You can use all these options as long as the output format is set to `--pretty=%H`.
198
+
199
+
200
+
## Pushing and fetching notes to and from the remote repository
164
201
165
202
GTM adds a couple of [git aliases](https://git-scm.com/book/en/v2/Git-Basics-Git-Aliases) to make this easy. It defaults to origin for the remote repository.
166
203
167
204
```
168
205
git fetchgtm
169
206
git pushgtm
170
207
```
208
+
171
209
Note - if you don't push your notes to the remote repository you will lose them if you delete and re-clone a repository.
0 commit comments