Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: time commands #19

Merged
merged 14 commits into from
May 2, 2024
Merged

Feat: time commands #19

merged 14 commits into from
May 2, 2024

Conversation

thekaveman
Copy link
Member

@thekaveman thekaveman commented Apr 22, 2024

Making #17 into reusable modules and CLI commands

Usage

$ compiler-admin time -h
usage: compiler-admin time [-h] {convert} ...

positional arguments:
  {convert}   The time command to run.
    convert   Convert a time report from one format into another.

options:
  -h, --help  show this help message and exit
$ compiler-admin time convert -h
usage: compiler-admin time convert [-h] [--input INPUT] [--output OUTPUT] [--client CLIENT]

options:
  -h, --help       show this help message and exit
  --input INPUT    The path to the source data for conversion. Defaults to stdin.
  --output OUTPUT  The path to the file where converted data should be written. Defaults to stdout.
  --client CLIENT  The name of the client to use in converted data.

time convert --input can source from either Harvest data or Toggl data, and converts to the opposite format given.

Copy link

github-actions bot commented Apr 22, 2024

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  compiler_admin
  main.py
  compiler_admin/commands/time
  __init__.py
  convert.py
  compiler_admin/commands/user
  __init__.py
  compiler_admin/services
  files.py
  harvest.py
  toggl.py
Project Total  

This report was generated by python-coverage-comment-action

@thekaveman thekaveman self-assigned this Apr 22, 2024
@thekaveman thekaveman force-pushed the feat/time branch 4 times, most recently from 3228a88 to c97c9e4 Compare April 24, 2024 17:42
@thekaveman thekaveman added the enhancement New feature or request label Apr 25, 2024
@thekaveman thekaveman marked this pull request as ready for review April 25, 2024 15:56
@thekaveman
Copy link
Member Author

Waiting to merge this until I run the April hours conversion, I'll do that both with the existing Google Apps script and this new command and compare results.

of course! locals() inside the context of the function scope
only contains the function params and local variables!
@thekaveman
Copy link
Member Author

Few small fixes needed, but otherwise it worked out pretty well 👍

@thekaveman thekaveman merged commit 543a2af into main May 2, 2024
1 check passed
@thekaveman thekaveman deleted the feat/time branch May 2, 2024 23:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant