basalt-rs/bedrock

Force ANSI colour output when possible

オープン

#44 opened on 2025/10/10

 (0 件のコメント) (0 件のリアクション) (0 人の担当者)Rust (0 件のフォーク)auto 404
enhancementgood first issue

Repository metrics

Stars
 (0 個のスター)
PR merge metrics
 (PR metrics pending)

説明

Many compilers/runtimes will automatically strip colour when the program detects that it's not in a terminal. Often, we can get around this by specifying a flag like --color=always so it will print things like errors in colour. Since our frontend supports ANSI colour codes, we should have the built-in commands attempt to do this.

For example, with rust:

rustc -o solution solution.rs
# becomes
rustc -o solution --color=always solution.rs

コントリビューターガイド