Skip to content

Commit

Permalink
pkg: improve readability of progress messages (ocaml#10836)
Browse files Browse the repository at this point in the history
Two tweaks to improve readability:
- Use the `Success` colour (bright green) rather than the `Ok`
  colour (basic green) as some light-themed terminals seem to display
  basic green as too light to read. This also happens to match the
  colour with the corresponding messages printed by `cargo`.
- Pad the status component of the messages so that all package names
  are aligned.

Signed-off-by: Stephen Sherratt <[email protected]>
  • Loading branch information
gridbugs authored Aug 20, 2024
1 parent 2c811fe commit b962278
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dune_rules/pkg_build_progress.ml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ module Message = struct
}

let user_message { package_name; package_version; status } =
let status_tag = User_message.Style.Ok in
let status_tag = User_message.Style.Success in
User_message.make
[ Pp.concat
[ Pp.tag status_tag (Pp.text (Status.to_string status))
[ Pp.tag status_tag (Pp.textf "%12s" (Status.to_string status))
; Pp.textf
" %s.%s"
(Package.Name.to_string package_name)
Expand Down

0 comments on commit b962278

Please sign in to comment.