Skip to main content

Command line interface for interacting with Tempo.

Project description

TempoCLI

Command line interface for interacting with Tempo.

PyPI version Python Versions Build Status License Docker Pulls

Introduction

Ease repetitive Tempo tasks by using templates to fill in recurring items without having to use web interface. Templates are yaml formatted files that are semi-flexible in allowing what can be created.

The author_account_id can be obtained by going to your profile in JIRA and copying the ID from the URL.

----
author_account_id: foo

issues:
  # Will use current date if one can't be determined.
  - issue: INT-8
    time_spent: 30m
    start_time: "9:30AM"

  # Can specify day of week easily.
  - issue: INT-10
    time_spent: 1h
    start_time: Monday at 9AM

  # Full on datetime with override.
  - issue: INT-11
    time_spent: 90s
    start_time: "2018-08-05 11:00:00"
    author_account_id: bar

  # Pass in extras that aren't exposed in DSL.
  # https://tempo-io.github.io/tempo-api-docs/#worklogs
  - issue: INT-11
    time_spent: 1h
    start_time: 8am
    extras:
      remainingEstimateSeconds: 300

Installation

$ pip install tempocli

Running

$ tempocli --config <config> create --template <template>

Configuration

By default, ~/.tempocli.yml is the path used for the configuration file but that can be changed with the --config option during invocation. The configuration file should look like this:

---
token: <token>

It is also possible to specify the token using the TEMPOCLI_TOKEN environment variable.

Docker

DockerHub

$ docker run \
    --rm \
    --tty \
    --interactive \
    --volume ~/.tempocli.yml:/home/tempocli/.tempocli.yml:ro \
    --volume /some/dir/with/templates:/templates:ro \
    awiddersheim/tempocli \
    create --template /templates/template.yml

Development

$ pip install -e .
$ tempocli --help

Testing

# Install development packages (preferably in a virtualenv)
$ pip install --editable .[dev]

# Run tests
$ pytest

# Run tests for all available Python interpreters
$ tox

# Linting
$ flake8

# Can also lint in tox as well
$ tox -e flake8

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

tempocli-0.2.4.dev16.tar.gz (10.1 kB view details)

Uploaded Source

Built Distribution

tempocli-0.2.4.dev16-py2.py3-none-any.whl (7.9 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file tempocli-0.2.4.dev16.tar.gz.

File metadata

  • Download URL: tempocli-0.2.4.dev16.tar.gz
  • Upload date:
  • Size: 10.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.2

File hashes

Hashes for tempocli-0.2.4.dev16.tar.gz
Algorithm Hash digest
SHA256 d07b684e751e60be66bdaf7059644f777244074bc492b2d208cc243bc794d5cd
MD5 aae5624c1a64b3ad0d8fe0e546da3f7e
BLAKE2b-256 1dde6b5b29fde094daf58bdb818719e1dd909556a5a02422210ae28cf81348b6

See more details on using hashes here.

File details

Details for the file tempocli-0.2.4.dev16-py2.py3-none-any.whl.

File metadata

  • Download URL: tempocli-0.2.4.dev16-py2.py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.2

File hashes

Hashes for tempocli-0.2.4.dev16-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 1802f58690a37d08655ca27b091cfcfd8deaae62e2ba79f7c5e203b7d12a0dae
MD5 c40c97513078ef5d010da5329d632c76
BLAKE2b-256 1c12d65918af862a3cec4164898355fb19aa35ce785e287301d6ec22df875836

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