added --color flag to force color even if stdout is a tty #439
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This option was inspired by @strk comment:
#422 (comment)
Now there is a
--color
option that works exactly like (but opposite to) the--no-color
option.There are other ways to implement this, possibly by replacing
--no-color
with something like--color
with values likeyes
,no
,auto
(auto being default and what the app currently does if no flag passed).If you'd rather see the flag implemented that way, I can change the code. Otherwise, this is good to go and allows things like
toot timeline --count 20 --color | less -R
to display timeline output, properly paged, in color.