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

Output to computer-readable formats #33

Open
dmaljovec opened this issue Jul 1, 2023 · 0 comments · May be fixed by #34
Open

Output to computer-readable formats #33

dmaljovec opened this issue Jul 1, 2023 · 0 comments · May be fixed by #34

Comments

@dmaljovec
Copy link

I was pointed at this project by a colleague, and I think it is a really cool idea! I am wanting to integrate this into a continuous integration build system that shoves a bunch of reports to a bucket to be consumed by another service in our ecosystem to track organization-wide metrics about our various codebases. Would you be open to a contribution that uses this feature from prettytable to output the data to a json format that is more machine-readable?

I am thinking it is just a refactor of these lines of code:

libyear/libyear/libyear

Lines 40 to 44 in ecbacf9

if total_days == 0:
print("Your system is up-to-date!")
else:
print(pt)
print("Your system is %s libyears behind" % str(round(total_days / 365, 2)))
and maybe sending these lines:
print(f'Latest version of {name!r} has no upload time.')
and
print(f'Used release of {name}=={version} has no upload time.')
, to stderr rather than stdout. What do you think?

Also, thanks for building this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant