Skip to content

PDDL Formatter

Compare
Choose a tag to compare
@jan-dolejsi jan-dolejsi released this 25 Jan 00:00
· 178 commits to master since this release
75314e1

2.21.0

PDDL Formatter

Right-click on PDDL document and you will see two more options: Format Document and Format Selection.
It re-formats the white space to enhance readability of the domain/problem.
The formatter does not modify most of your line breaks, but modifies most of the indentation.

Even more helpful is the on-type formatter, which automatically suggests indentation when you press Enter in the document.

On-type formatter

The on-type formatter must however be first enabled using this setting:

"editor.formatOnType": true

You can selectively enable the on-type formatting just for PDDL documents:

"[pddl]": {
    "editor.formatOnType": true
}

The above configuration can be now easily inserted from the PDDL: Overview Page.

The Document and Document Selection formatter (along with the separately enabled on-type formatter) can be disabled (in case of clash with another extension) using the pddl.formatter setting.

This was one of the oldest standing feature request is now addressed.
This work was started by our intern more than 2 years ago, but I only had time to finish it now - thanks to C-19 isolation.