Skip to main content

Synchronize gTimeLog to Tick

https://github.com/minddistrict/gtimelog2tick/actions/workflows/build.yml/badge.svg

This script will read your timelog.txt file populated by gtimelog and will submit work log entries to Tick, via Tick API.

It is based on https://github.com/ProgrammersOfVilnius/gtimelog2jira.

Installation

Installation with pipx

pipx install gtimelog2tick

Usage

In order to synchronize your most recent entries to Tick, simply run:

gtimelog2tick

By default, this command will synchronize entries created 7 days ago up to now.

You can control what time period you want to synchronize using the --since and/or --until parameters:

gtimelog2tick --since 2023-12-01 --until 2023-12-24

If you want to test things, without creating work log entries in Tick, you can use the --dry-run flag:

gtimelog2tick --dry-run

This way nothing will be sent to Tick, the script will instead show what it would do.

Configuration

By default, gtimelog2tick reads configuration from the ~/.gtimelog/gtimelogrc file. Configuration file example:

[gtimelog2tick]
subscription_id = 234234
token = a343jk34s
user_id = 12323
email = user@example.com
timelog = ~/.gtimelog/timelog.txt
ticklog = ~/.gtimelog/tick.log
projects =
  FOO
  BAR
  BAZ

Use the Subscription ID as value for the subscription_id field and the API Token for the token field. Both can be looked up at your personal profile page in the web UI.

The value for user_id can be found in the URL of the personal profile page. It is the number between users/ and /edit.

Use your actual email address as otherwise requests might be refused.

timelog is the path where the gtimelog time log file is stored. The default should be okay. ticklog: this file is used to write a line for each action which is done via the Tick API. When using --dry-run, this file is also filled.

projects option should list all project prefixes for upload. These prefixes will be used to identify tick projects. If the script for an entry does not find a matching tick project, it will skip that entry. Caution: This option can be empty or omitted to upload all projects.

Change log

0.2.2 (2023-12-21)

  • Do not break if a day only contains a single line.

  • Render a better error message if an entry cannot be parsed.

0.2.1 (2023-12-11)

  • Streamline command line arguments and documentation.

0.2 (2023-12-11)

  • Prefer exact matches in case of multiple ones.

  • Fetch all projects, not just the first 100.

  • If the config option projects is empty, upload all possible entries.

  • Improve formatting to have always a precision of 2 for floats.

  • No longer ignore entries with negative time.

Release files for gtimelog2tick 0.2.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gtimelog2tick 0.2.2
File Size Uploaded
gtimelog2tick-0.2.2.tar.gz 27.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for gtimelog2tick 0.2.2
File Interpreter ABI Platform
gtimelog2tick-0.2.2-py3-none-any.whl Python 3 none any Details

Total release size: 47.4 kB

Release files / gtimelog2tick-0.2.2.tar.gz

Download URL gtimelog2tick-0.2.2.tar.gz
Size 27.1 kB
Tags Source
SHA-256 checksum
How to use checksums
736f9ae7c5632851e25efe08eec690766584b796e95367dce3bc43b248ffb711
BLAKE2b-256 checksum
How to use checksums
7a5972b427268abf30a2f3539b63351de0cd6d30e1b8b16a632a902048a2c341
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.7

Release files / gtimelog2tick-0.2.2-py3-none-any.whl

Download URL gtimelog2tick-0.2.2-py3-none-any.whl
Size 20.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
68a336292cb0826714a27de05cb960e570c3c217171971094f10ee45939d0200
BLAKE2b-256 checksum
How to use checksums
d50a5f96bd14f5d461aa13d2fed5c47699d6941a6196e5b896eb9ebf2b03c7ab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.7

Release history Release notifications | RSS feed

This release

0.2.2 This release

2 release files

0.2.1

2 release files

0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page