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

Add output flag #823

Merged
merged 1 commit into from
Jan 30, 2023
Merged

Add output flag #823

merged 1 commit into from
Jan 30, 2023

Conversation

gandarez
Copy link
Member

@gandarez gandarez commented Jan 29, 2023

This PR adds new output flag to change output from raw string to json or vice-versa. The default value is text. Only --today and --today-goal can benefit from this flag yet. In addition today-hide-categories has been changed from bool to string to fully support taking precedence over any other setting as it's a known bug.

Testing

# print today as json
./build/wakatime-cli-darwin-amd64 --output json --today

# print today as raw-json (original payload)
./build/wakatime-cli-darwin-amd64 --output raw-json --today

# print today as text
./build/wakatime-cli-darwin-amd64 --output text --today
# or without flag
./build/wakatime-cli-darwin-amd64 --today

@gandarez gandarez self-assigned this Jan 29, 2023
@gandarez gandarez merged commit 254324a into develop Jan 30, 2023
@gandarez gandarez deleted the feature/output-json branch January 30, 2023 19:43
@gandarez gandarez mentioned this pull request Jan 30, 2023
@alanhamlett alanhamlett mentioned this pull request Feb 3, 2023
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 this pull request may close these issues.

2 participants