ptyme-track


Nameptyme-track JSON
Version 0.3.0 PyPI version JSON
download
home_page
SummaryThe obnoxiously named time tracking based on file modifications and signed reporting. The P is silent like in Pterodactyl
upload_time2023-06-27 01:19:43
maintainer
docs_urlNone
authorJames Hutchison
requires_python>=3.8,<4.0
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Ptyme Track
![versions](https://img.shields.io/pypi/pyversions/ptyme-track)

The obnoxiously hard to spell time tracking based on file modifications and signed time reporting. The P is silent like in Pterodactyl

## Usage

### Installation
`pip install ptyme-track`

### Server / client
For the server, generate a secret first with `ptyme-track --ensure-secret`

Simply run the server with `ptyme_track --server`

For the client, use `ptyme_track --client`

### Running locally
Run `ptyme-track --ensure-secret` to generate a secret and update the .gitignore file.

Simply run `ptyme_track --standalone` in the background.

### Setting directories to watch
By default, the current working directory is used and hidden directories are ignored. To manually set paths, use the `PTYME_WATCHED_DIRS` environment variable.

## Cementing work
To cement your time record, use `ptyme_track --cement <name>`. It is recommended name is your github name. Note this is a filename so it needs to be filename safe (and unique from others). This will create a file `.ptyme_track/<name>`


## Getting a time summary
To get a time summary enter the path to the file. For example, `ptyme_track --time-blocks .ptyme_track/JamesHutchison` will give you a summary of the time blocks for JamesHutchison.

```
...
{"start": "2023-05-30 19:00:34", "end": "2023-05-30 19:10:34", "duration": "0:10:00"}
{"start": "2023-05-31 04:02:31", "end": "2023-05-31 04:20:31", "duration": "0:18:00"}
{"start": "2023-05-31 04:20:31", "end": "2023-05-31 04:32:32", "duration": "0:12:01"}
{"start": "2023-05-31 04:30:32", "end": "2023-05-31 04:40:32", "duration": "0:10:00"}
{"start": "2023-05-31 04:56:33", "end": "2023-05-31 05:08:33", "duration": "0:12:00"}
{"start": "2023-05-31 05:03:51", "end": "2023-05-31 05:17:50", "duration": "0:13:59"}
Total duration:  11:47:22
```

## Adding to the CI

Add this workflow:

```yaml
name: Get logged time
on:
  pull_request:
    paths:
      - '.ptyme_track/*'

jobs:
  track-time:
    uses: JamesHutchison/ptyme-track/.github/workflows/time_tracking.yaml@main
    permissions:
      pull-requests: write
    with:
      base-branch: origin/${{ github.event.pull_request.base.ref }}
      pr-number: ${{ github.event.pull_request.number }}
```


            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "ptyme-track",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<4.0",
    "maintainer_email": "",
    "keywords": "",
    "author": "James Hutchison",
    "author_email": "JamesGHutchison@proton.me",
    "download_url": "https://files.pythonhosted.org/packages/1d/6b/479ca99e64c4dad62ca08b4cddad9d8e0ceee0a3dd166a38d54b5dbd2aa9/ptyme_track-0.3.0.tar.gz",
    "platform": null,
    "description": "# Ptyme Track\n![versions](https://img.shields.io/pypi/pyversions/ptyme-track)\n\nThe obnoxiously hard to spell time tracking based on file modifications and signed time reporting. The P is silent like in Pterodactyl\n\n## Usage\n\n### Installation\n`pip install ptyme-track`\n\n### Server / client\nFor the server, generate a secret first with `ptyme-track --ensure-secret`\n\nSimply run the server with `ptyme_track --server`\n\nFor the client, use `ptyme_track --client`\n\n### Running locally\nRun `ptyme-track --ensure-secret` to generate a secret and update the .gitignore file.\n\nSimply run `ptyme_track --standalone` in the background.\n\n### Setting directories to watch\nBy default, the current working directory is used and hidden directories are ignored. To manually set paths, use the `PTYME_WATCHED_DIRS` environment variable.\n\n## Cementing work\nTo cement your time record, use `ptyme_track --cement <name>`. It is recommended name is your github name. Note this is a filename so it needs to be filename safe (and unique from others). This will create a file `.ptyme_track/<name>`\n\n\n## Getting a time summary\nTo get a time summary enter the path to the file. For example, `ptyme_track --time-blocks .ptyme_track/JamesHutchison` will give you a summary of the time blocks for JamesHutchison.\n\n```\n...\n{\"start\": \"2023-05-30 19:00:34\", \"end\": \"2023-05-30 19:10:34\", \"duration\": \"0:10:00\"}\n{\"start\": \"2023-05-31 04:02:31\", \"end\": \"2023-05-31 04:20:31\", \"duration\": \"0:18:00\"}\n{\"start\": \"2023-05-31 04:20:31\", \"end\": \"2023-05-31 04:32:32\", \"duration\": \"0:12:01\"}\n{\"start\": \"2023-05-31 04:30:32\", \"end\": \"2023-05-31 04:40:32\", \"duration\": \"0:10:00\"}\n{\"start\": \"2023-05-31 04:56:33\", \"end\": \"2023-05-31 05:08:33\", \"duration\": \"0:12:00\"}\n{\"start\": \"2023-05-31 05:03:51\", \"end\": \"2023-05-31 05:17:50\", \"duration\": \"0:13:59\"}\nTotal duration:  11:47:22\n```\n\n## Adding to the CI\n\nAdd this workflow:\n\n```yaml\nname: Get logged time\non:\n  pull_request:\n    paths:\n      - '.ptyme_track/*'\n\njobs:\n  track-time:\n    uses: JamesHutchison/ptyme-track/.github/workflows/time_tracking.yaml@main\n    permissions:\n      pull-requests: write\n    with:\n      base-branch: origin/${{ github.event.pull_request.base.ref }}\n      pr-number: ${{ github.event.pull_request.number }}\n```\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "The obnoxiously named time tracking based on file modifications and signed reporting. The P is silent like in Pterodactyl",
    "version": "0.3.0",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "15733a70e3139b9105894a00cd32a17f49f2c021237f0d6b178f15da3f3e9de2",
                "md5": "e94045c10742f6c5bc3bfd91891e8ced",
                "sha256": "c6c3d17ac975d77bc9c3778d55a6f1c59feb7663ae2e754a361a828c7a83a49a"
            },
            "downloads": -1,
            "filename": "ptyme_track-0.3.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "e94045c10742f6c5bc3bfd91891e8ced",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<4.0",
            "size": 14127,
            "upload_time": "2023-06-27T01:19:42",
            "upload_time_iso_8601": "2023-06-27T01:19:42.620379Z",
            "url": "https://files.pythonhosted.org/packages/15/73/3a70e3139b9105894a00cd32a17f49f2c021237f0d6b178f15da3f3e9de2/ptyme_track-0.3.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1d6b479ca99e64c4dad62ca08b4cddad9d8e0ceee0a3dd166a38d54b5dbd2aa9",
                "md5": "e89d9d5241e2fa52d387b8e80bbcb5a6",
                "sha256": "5ce93443f68a436a0d589aa9e4026e4a24a7077afdc63de41674ee1062f6817b"
            },
            "downloads": -1,
            "filename": "ptyme_track-0.3.0.tar.gz",
            "has_sig": false,
            "md5_digest": "e89d9d5241e2fa52d387b8e80bbcb5a6",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<4.0",
            "size": 10779,
            "upload_time": "2023-06-27T01:19:43",
            "upload_time_iso_8601": "2023-06-27T01:19:43.984571Z",
            "url": "https://files.pythonhosted.org/packages/1d/6b/479ca99e64c4dad62ca08b4cddad9d8e0ceee0a3dd166a38d54b5dbd2aa9/ptyme_track-0.3.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-06-27 01:19:43",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "ptyme-track"
}
        
Elapsed time: 0.28049s