Giter Site home page Giter Site logo

time-tracker's Introduction

Working Time Tracker

A simple script to track how much time you spend near the computer in the office.

Requirements

The script uses xscreensaver-command -watch output so xscreensaver is required as a screen locking framework. Notifications are shown by notify-send. And Ruby (tested on v2.2.3) is needed to be able to run the script.

Also it assumes that you do not work at nights and do not turn off your PC.

Before first run all dependencies should be installed:

bundle install

Usage

This script should be run during the whole session so it can be executed from .profile file or as a service.

To run the script from terminal emulator:

time-tracker ~/time.txt

It generates a report file (in this case ~/time.txt), for example:

11.01    Started: 09:34    Finished: 17:35    Delta: 08:00    Total per week: 08:00
12.01    Started: 10:35    Finished: 18:29    Delta: 07:54    Total per week: 15:54
13.01    Started: 09:01    Finished: 17:20    Delta: 08:19    Total per week: 24:13

Also it creates a file (~/time.txt.current) which contains working time for the current day. You can use this file wherever you want. And it is used by Generic Monitor plugin.

For more information about options:

time-tracker --help

Generic Monitor plugin

Additionally the script can be used with dnschneid/xfce4-genmon-plugin to display a progress bar on the panel.

time-tracker --genmon ~/time.txt

Notification

There is a notification if you have already been 8 hours at the office - it's time to go home.

TeamViewer

This script doesn't treat TeamViewer sessions as working time. So any screen lock/unlock under TeamViewer will be ignored and will not be taken into account.

time-tracker's People

Contributors

phts avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.