SourceFiles.org - Use the Source, Luke
Home | Register | News | Forums | Guide | MyLinks | Bookmark

Related Sites

Latest News
  General News
  Reviews
  Press Releases
  Software
  Hardware
  Security
  Tutorials
  Off Topic


Back to files

Keypress

Overview

Keypress is a program that enables it's user to monitor the usage of his computer. Keypress is intended as an overall worktime monitoring program, the user can follow his worktime on monthly basis. It creates reports of when the user started to use the computer and when he stopped using it.

Keypress is divided into two parts, the daemon and the utilities/gui. The deamon is responsible of collecting the data from /proc/interrupts and storing that. The utilities are small commands that the user can run.

Keypress works only for local users, i.e., it measures how much the local keyboard has been used. No remote user activity is included.

Features

The main features of keypress are:

  • Tracks the beginning and end of keyboard activity each day
  • Very lightweight daemon
  • Email report each month to a configurable address
  • Work time calculation and overtime calculations per day/month
  • Configurable weekly working days
  • Working days can be marked as being holidays, vacations, sick days, exluding them from overtime calculations

The main features of keypress ui are:

  • Uses GTK 2 to look good
  • Categorization of days with just a right click with mouse
  • Counting of vacation days
  • Printing support

Extra features:

  • gDesklet to display crucial statistics
  • Possibility to add public holiday data packages so that all public holidays (christmas, easter, midsummer, independence day, whatnot) are automatically categorized as holidays. (Currently Finland 2004 is provided)

Installation

You can download the debian package and install it. OR by downloading the source package and running

make install
cp server/etc/keypress.conf /etc/

NOTE: if you install from source, you have to include the starting of the keypress daemon to your system start scripts.

Configuration

Keypress is configured via /etc/keypress.conf file. It has the following configuration options:

DATA_DIR - Where data from the deamon is stored (/var/lib/keypress) DAILY_WORKHOURS - How many hours one should work each day. (8:00)

WEEK_END        - Which days are considered weekend and not working days.
MAIL_USER       - To which email address to send the monthly report to

Internals

Keypress daemon works following:

read /proc/interrupts
get current keyboard interrupts
put interrupt count to logfile with datestamp sleep for 1 minute and start again

Besides this, each month it will create a report which is mailed to the configured user.

Utilities

Keypress has the following utility programs included with it:

  1. keypress-summarize

usage: keypress-summarize <yyyymmdd>

Displays the daily summary of the given day

2. keypress-workhours

usage: keypress-workhours <yyyymm>

Displays a report of the given month

3. keypress-comment

usage: keypress-comment <yyymmdd> <comment>

Adds a comment to the given day. When a day is commented, it's hour saldo isn't included in the monthly worktime/overtime calculations.

Graphical UI

Keypress also includes a Gnome ui to view and edit the keypress data. The ui is fairly commonplace and should be intuitive to use. Always when making changes, you must click save afterwards. Day categorization can be done via menu or right-click pop-up menu.

Keypress ui is build on top of GTK2, Glade and perl. Hence the following library requirements exist:

  • Gtk2
  • keypress

The following packages you can get from http://gtk2-perl.sourceforge.net/

  • libextutils-pkgconfig-perl (>= 1.02-1)
  • libglib-perl (>= 1.011-1)
  • libgnome2-perl (>= 0.38-1)
  • libgtk2-gladexml-perl (>=0.94-1),
  • libgtk2-perl (>=1.011-1)
  • libextutils-depends-perl

COPYRIGHT

This software is LGPL. Use for what ever you please, send me comments if you find it useful or you have ideas to develop it further.

Keypress web: http://keypress.sourceforge.net/ Author: Petri Vakevainen <Petri.Vakevainen@hut.fi>


Other Sites

Discussion Groups
  Beginners
  Distributions
  Networking / Security
  Software
  PDAs

About | FAQ | Privacy | Awards | Contact
Comments to the webmaster are welcome.
Copyright 2006 Sourcefiles.org All rights reserved.