1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

tools: make the v REPL help screen look nicer (#10833)

This commit is contained in:
William Gooch
2021-07-17 04:23:29 -04:00
committed by GitHub
parent 355f46f475
commit 51dd8304bb
3 changed files with 17 additions and 6 deletions

View File

@@ -5,6 +5,7 @@ module util
import os
import time
import term
import v.pref
import v.vmod
import v.util.recompilation
@@ -569,3 +570,9 @@ pub fn find_all_v_files(roots []string) ?[]string {
}
return files
}
// Highlight a command with an on-brand background to make CLI
// commands immediately recognizable.
pub fn pretty_print(command string) string {
return term.bright_white(term.bg_cyan(' $command '))
}