internal/rosa: force output colouring
Test / Create distribution (push) Successful in 58s
Test / Sandbox (push) Successful in 3m0s
Test / Hakurei (push) Successful in 4m45s
Test / Sandbox (race detector) (push) Successful in 6m0s
Test / Hakurei (race detector) (push) Successful in 7m16s
Test / ShareFS (push) Successful in 7m47s
Test / Flake checks (push) Successful in 2m56s
Test / Create distribution (push) Successful in 58s
Test / Sandbox (push) Successful in 3m0s
Test / Hakurei (push) Successful in 4m45s
Test / Sandbox (race detector) (push) Successful in 6m0s
Test / Hakurei (race detector) (push) Successful in 7m16s
Test / ShareFS (push) Successful in 7m47s
Test / Flake checks (push) Successful in 2m56s
This sets known de facto standard environment variables to enable colours during builds. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -173,6 +173,7 @@ make \
|
|||||||
scriptMake += attr.ScriptCheckEarly + `make \
|
scriptMake += attr.ScriptCheckEarly + `make \
|
||||||
` + jobsFlagE + ` \
|
` + jobsFlagE + ` \
|
||||||
` + loadFlagE + ` \
|
` + loadFlagE + ` \
|
||||||
|
AM_COLOR_TESTS=always \
|
||||||
`
|
`
|
||||||
if len(attr.Check) > 0 {
|
if len(attr.Check) > 0 {
|
||||||
scriptMake += strings.Join(attr.Check, " \\\n\t")
|
scriptMake += strings.Join(attr.Check, " \\\n\t")
|
||||||
|
|||||||
@@ -322,6 +322,8 @@ type PackageAttr struct {
|
|||||||
|
|
||||||
// Hint for an early variant of toybox to be used when available.
|
// Hint for an early variant of toybox to be used when available.
|
||||||
Early bool
|
Early bool
|
||||||
|
// Whether to omit output colour environment variables.
|
||||||
|
NoColor bool
|
||||||
// Exclude the LLVM toolchain.
|
// Exclude the LLVM toolchain.
|
||||||
NoToolchain bool
|
NoToolchain bool
|
||||||
// Whether the resulting [pkg.Artifact] is exclusive.
|
// Whether the resulting [pkg.Artifact] is exclusive.
|
||||||
@@ -399,6 +401,12 @@ func (t Toolchain) New(
|
|||||||
const lcMessages = "LC_MESSAGES=C.UTF-8"
|
const lcMessages = "LC_MESSAGES=C.UTF-8"
|
||||||
srn := rn
|
srn := rn
|
||||||
env := slices.Clone(attr.Env)
|
env := slices.Clone(attr.Env)
|
||||||
|
if !attr.NoColor {
|
||||||
|
env = append(env,
|
||||||
|
"CLICOLOR_FORCE=1",
|
||||||
|
"FORCE_COLOR=1",
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
var extraBoot []ArtifactH
|
var extraBoot []ArtifactH
|
||||||
switch t.stage {
|
switch t.stage {
|
||||||
|
|||||||
Reference in New Issue
Block a user