Skip to main content

Clock in, clock out, track your working hours.

Project description

clocky

CLI for tracking hours worked

This was the first "installable" package I ever made. The code is very messy. It was originally used with easy install and I have used it for work every day since its conception. This is a great little program for keeping record of your punches in the event your company's system fails or you forget to punch-out at the end of the day. I have decided to publish the code and refactor it to be installable with pip.

Install

Requires Python >= 3.8

pip install clocky-cli

Features

  • clocking in and out
  • break timer that auto clocks back in
  • output punches from timelog (similar to tail on Linux)
  • output timecard for a given week
  • various charts
  • edit dates if you forget a punch
  • configurable settings (stored at ~/.config/clocky/clocky.ini)

Usage

usage: clocky [-?] [-d] [-v | -i | -o | -t | -b [M] | -l [N] | -s [N] | -g [N] | -c [N] | -gc [N] | -h
              I [N ...] | --edit [D]]

Clocky: A timecard program! Arguments are mutually exclusive. (Except --debug)

options:
  -?, --help                Show this help message and exit.
  -d, --debug               Print debug information.
  -v, --version             show program's version number and exit
  -i, --in                  Clock in.
  -o, --out                 Clock out.
  -t, --toggle              Clock in if out, clock out if in.
  -b [M], --break [M]       Clock out for [M] minutes and clock back in. (default: 30)
  -l [N], --log [N]         Print log for last [N] days. (default: 7)
  -s [N], --sum [N]         Print summary for [N]th week ago. (default: 0)
  -g [N], --graph [N]       Print graphical summary for [N]th week ago. (default: 0)
  -c [N], --chart [N]       Print chart summary for [N]th week ago. (default: 0)
  -gc [N], -cg [N]          Combines graph and chart for [N]th week ago. (default: 0)
  -h I [N], --hist I [N]    Chart history for last [N] [I]ntervals. (D=days W=weeks)  ← Not yet implemented 
  --edit [D]                Edit timecard for [D]ate. (YYYY-MM-DD)

Try 'clocky --demo' for demonstrations.

Example Images

Issues

  • Be very careful about adding a clocky -i to your shell's profile. Sometimes shell profiles are reloaded which will cause unwanted punches. I experienced this firsthand in PowerShell: Took me way too long to debug. It's better to add clocky -i to a startup script that you run manually.

  • If you are using Nerd Fonts or other fonts that support ligatures, you may experience rendering issues with some of the charts. (See Issue #13)

Author

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clocky-cli-2.2.tar.gz (15.9 kB view details)

Uploaded Source

Built Distribution

clocky_cli-2.2-py3-none-any.whl (14.5 kB view details)

Uploaded Python 3

File details

Details for the file clocky-cli-2.2.tar.gz.

File metadata

  • Download URL: clocky-cli-2.2.tar.gz
  • Upload date:
  • Size: 15.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for clocky-cli-2.2.tar.gz
Algorithm Hash digest
SHA256 0d4c758df129741044905d199e13df77bbb8c86ac4022386e4da97b07385eb40
MD5 0d7ea633b6281edfe72dbc616aacc58d
BLAKE2b-256 057554f596426476b9516c83e39380c8c6e148d090b9e4eafa03c839bfd6c177

See more details on using hashes here.

File details

Details for the file clocky_cli-2.2-py3-none-any.whl.

File metadata

  • Download URL: clocky_cli-2.2-py3-none-any.whl
  • Upload date:
  • Size: 14.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for clocky_cli-2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a9090f6dd5bbb40a40174b25dcde08abd085c1fc6934f3aa3ed0718d98d49376
MD5 4a96d013e1ff59852d36956d67d235ff
BLAKE2b-256 14304dc5b2406ac32ee29296b27ef1bf626364a8a2c0645735709afc50580cbe

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page