-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
colorama: standardize and apply output message colors #2784
Comments
Good catch @jorgeorpinel !
It is used in |
Thanks. Should probably use it more or remove it? |
@jorgeorpinel Hm, why remove it? But yeah, could definitely use it more :) |
Idk. It only knows 4 colors rn, and the resulting syntax is not that easy to read, at least in "{border}{space}{border}\n".format(
border=colorize(chars["vertical"], color=border_color),
space=chars["empty"] * box_size_horizontal, vs. something like "{blue}text{nc}\n".format(blue=colorama.Fore.BLUE... |
When there are no stages in the repo, show a friendly message to that effect and display a getting-started URL. Fixes iterative#2784.
Closing as stale. |
I just recently discovered we're using
colorama
when reviewing https://github.com/iterative/dvc/pull/2765/files but haven't really noticed it much in most DVC output.Current use I can see now:
colorama.Fore.BLUE
is used for some URLs. I like this, should check it's ALL URLs.RED
andGREEN
are used in the updater. This seems OK.BLUE
,RED
, andYELLOW
in the logger.CYAN
(calledblue
) is used for the man.dvc.org URLs here and here. Not sure we need this per the first bullet (BLUE
).MAGENTA
for 2 "HINT" messages here and here. Should check it's used in all such hints, and that other "SOMETHING:" messages always have heir own colors.colorize
function in dvc/dvc/utils/init.py:dvc/dvc/utils/__init__.py
Lines 349 to 359 in cfc442e
but doesn't seem to be in use. Use it or lose it.only used in boxify. Use it more (or remove it).LockError
message #2765 may introduceBLUE
for sample commands in the output (those surrounded with back ticksfor example. Should we apply this everywhere? (Also "dynamic" commands, printed inside single quotes
'`.)The text was updated successfully, but these errors were encountered: