Skip to content

Add --color option to command line arguments#106868

Open
Cykyrios wants to merge 1 commit intogodotengine:masterfrom
Cykyrios:cli-color-option
Open

Add --color option to command line arguments#106868
Cykyrios wants to merge 1 commit intogodotengine:masterfrom
Cykyrios:cli-color-option

Conversation

@Cykyrios
Copy link
Copy Markdown
Contributor

Closes godotengine/godot-proposals#12507.

This PR adds the --color commandline option to always include colors in stdout/stderr, so colored output can be printed from another process (e.g. OS.execute or OS.execute_with_pipe calling a Godot script with godot --headless --color -s my_script.gd).

Tested on Linux with an editor build, untested on Windows. Not implemented for Apple devices as MacOS seems to always include colors, and Apple Embedded never does.

If the principle is accepted, I will need to add the option to godot --help, and I assume the online documentation will need its own update.

@Calinou
Copy link
Copy Markdown
Member

Calinou commented May 27, 2025

I already opened a PR for this a while ago: #77261

@Cykyrios
Copy link
Copy Markdown
Contributor Author

I completely forgot to check for existing PRs, yours is more complete and the better option, I would love to see it merged.

@Ivorforce
Copy link
Copy Markdown
Member

I completely forgot to check for existing PRs, yours is more complete and the better option, I would love to see it merged.

Feel free to add a review to #77261, this may help move it along :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow Godot to always print stderr colors

4 participants