• Stars
    star
    137
  • Rank 265,336 (Top 6 %)
  • Language
    Python
  • Created about 10 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A simple Taskwarrior hook allowing one to track total time spent on a task.

Taskwarrior Time Tracking Hook

Ensure you have taskwarrior 2.4.x or higher.

Install

Install using pip:

pip install taskwarrior-time-tracking-hook

And add it to your Taskwarrior hooks:

mkdir -p ~/.task/hooks
ln -s $(which taskwarrior_time_tracking_hook) ~/.task/hooks/on-modify.timetracking

(if ~/.local/bin is not in your path, this last command will not work. In this case, replace $(which taskwarrior_time_tracking_hook) by ~/.local/bin/taskwarrior_time_tracking_hook)

Add the totalactivetime user defined attribute configuration:

task config uda.totalactivetime.type duration
task config uda.totalactivetime.label Total active time
task config uda.totalactivetime.values ''

Add to reports (replace list with whichever report type you want to modify):

task show report.list.labels
    ID,Active,Age,...,Urg
task show report.list.columns
    id,start.age,entry.age,...,urgency

task config report.list.labels 'ID,Active,Age,Time Spent,...,Urg'
task config report.list.columns 'id,start.age,entry.age,totalactivetime,...,urgency'

Usage

Use task <TASK ID> start and task <TASK ID> stop to record when you have started and stopped working on tasks.

Tracked time is stored in a task duration attribute named totalactivetime holding the total number of seconds that the task was active.

By default, this plugin allows you to have one task active at a time. You can change this by setting max_active_tasks in taskrc to a value greater than 1.

Un-install

Delete the hook:

rm ~/.task/hooks/on-modify.timetracking

Remove the User Defined Attribute (UDA) configuration:

task config uda.totalactivetime.values
task config uda.totalactivetime.label
task config uda.totalactivetime.type

Remove the Python program:

pip uninstall taskwarrior-time-tracking-hook

More Repositories

1

task-git

Backup Taskwarrior database to a git repository
Shell
24
star
2

harvest.el

Work with Harvest App time entries from Emacs
Emacs Lisp
20
star
3

subDrush

Drush integration for Sublime Text 3 to facilitate Drupal development.
PHP
17
star
4

sublime-taskwarrior

Taskwarrior integration for Sublime Text 2
Python
12
star
5

Urban-Airship-API

Drupal module that provides an API for Urban Airship
PHP
7
star
6

taskwarrior-time-report

Time reports on tasks in Taskwarrior
Python
6
star
7

dotfiles

Emacs Lisp
6
star
8

rebuild

Mirror of Drush Rebuild from https://drupal.org/project/rebuild . Submit patches on drupal.org
PHP
3
star
9

ac-task-php

ActiveCollab and Taskwarrior integration.
PHP
3
star
10

LibTask

PHP library for interacting with Taskwarrior 2.x
PHP
3
star
11

sonarqubebot

Mirror of https://gerrit.wikimedia.org/g/labs/tools/sonarqubebot
PHP
3
star
12

emacs-and-php

A collection of tips & tricks for writing PHP in Emacs
2
star
13

pyac

Python module for integration with activeCollab 3.x/4.x
Python
2
star
14

occupy_usa

Map of #Occupy protests across the USA
2
star
15

.spacemacs.d

Emacs Lisp
2
star
16

mw

Go
2
star
17

ActiveCollabApi

NO LONGER MAINTAINED! See https://github.com/activecollab/activecollab-sdk
PHP
2
star
18

safe_formats

PHP
1
star
19

psysh-debug-mode.el

Emacs minor mode for debugging PHP scripts with Psysh
Emacs Lisp
1
star
20

mediawiki-dev-env

Experiment in simplfying local development environment for MediaWiki
PHP
1
star
21

poll_blocks

By default, Drupal's poll.module only creates a Block for the most recent Poll. This simple Drupal module generates Blocks for every Poll.
PHP
1
star
22

dotvim

Vim Script
1
star
23

todo.txt-ac

activeCollab integration for todo.txt
Shell
1
star
24

geo_tools

Geo Tools is a module and set of drush scripts to facilitate exporting Drupal data to CSVs with latitude and longitude data. **It needs work and will not work for you without modification.**
1
star
25

feeds_salesforce

Feeds Salesforce is a Drupal module that provides a Fetcher and Parser to the Feeds module (http://drupal.org/project/feeds). The module depends on Salesforce API (http://drupal.org/project/salesforce)
1
star