-
Notifications
You must be signed in to change notification settings - Fork 1
Tutorial
First of all you need to setup your credentials on onetime:
onetime init harvest
onetime init tp
second command is not required if you do not wish to use target-process.
Now you are ready to capture time.
onetime time start
System will ask you a series of questions. Some of them explained here:
- Target process task: If you wish to log your time against target-process, you need to specify the task ID here. System will confirm whether the task exists and shows you a summary.
- //TODO: add more...
After you finished adding your time. You should be able to see is:
onetime time list
You can pause and un-pause your times at any time:
onetime time pause
onetime time resume
You can alternatively use
t
as an alias totime
, i.e. all of the above commands can be run likeonetime t ...
Finalising a time means, stopping it (if running) and logging the time against it's task on target-process (if any). -- this is usually done once at the end of the day.
onetime time finish --all
If you wish to finalise only one certain time
onetime time finish
in case you forgot to finalise your time on a specific day, you can do so by running one of the following commands:
onetime time finish -d 2015-10-01
onetime time finish -o 1
where
-o
is day offset relative today -- e.g.-o 1
means yesterday.
In case you want to start an exact time from another day, you can do so by either of these commands:
onetime time restart -d 2015-10-01
onetime time restart -o 1
often happens that there are certain tasks that you typically do on various days (for example
admin
ordeployment
, etc). For these you can define an alias and avoid entering the same information every time.
onetime time alias add <name-of-your-alias>
Then you can do:
onetime time start -a <name-of-your-alias>
In order to manage your aliases:
onetime time alias list
onetime time alias remove <name-of-your-alias>
Use the following command to define a mapping:
onetime project map
Then if you start a time by a target project task, you wouldn't have to enter the harvest project.
Also in order to list and remove mappings, do:
onetime project map list
onetime project map remove
In order to view your configuration:
onetime config show
and to clear it:
onetime config clear
To avoid double entries in target process you need to configure where time is recorded (default is both):
onetime config set tp bug-time where value: ['both', 'bug', 'user-story', 'both']
Note: We no longer need to configure bug-time in onetime. This is being replaced by TP's custom field where we can set the values for bug-time there and onetime will read that value.
Setting the story-time
option to true will allow you to log time directly to a user-story. If it is false (default), you will only be able to log time to a task/bug on a story.
onetime config set tp story-time <value> where value: ['true', 'false']
In case you want to avoid selecting the project every time you add a time from a specific directory you can add a .onetime
file to the directory with the following content:
{
"project": <id-of-project>
}
where <id-of-project>
is the under-the-hoods id that harvest holds for your project.
In order to discover what is is:
onetime project list