A GDScript beautifier for Godot Engine
This addon is compatible with Godot 4.
GDBeautifier performs several cleaning tasks.
- Removes spaces and tabs in empty lines
- Removes spaces at the end of lines
- Removes empty lines at the end of a script
- Adds spaces around operators
- Adds a space after commas and colons
- Adds 2 empty lines before any function
The addon ignores anything inside strings and comments.
Add the addons folder to your project, and enable it in the plugins panel of the project settings.
The beautifier panel is in the top left dock. It appears when the script editor is visible and a script is selected.
Select the desired options and click on beautify. The current script will be beautified.
You can also activate it with the shortcut Ctrl+Alt+B
.
You can undo if you change your mind.