Setup Codeformatter for Sublime Text 3 - Allman bracket style

1k Views Asked by At

I have installed Codeformatter for Sublime Text 3, because I want the Allman style for curly brackets when I hit tab. However, I cannot seem to figure out how to "activate" this feature, so it auto formats with the allman style (mainly in PHP). Any help is appreciated!

1

There are 1 best solutions below

2
On

Let's hope I get this right. I'm assuming you're using sublimetext-codeformatter. In the language specific options for PHP, add AllmanStyleBraces to the passes array:

"codeformatter_php_options":
{
    "syntaxes": "php",
    "passes": ["AllmanStyleBraces"]
}

Checkout the WIKI for an example options list, and this page for a list of PHP Transformations.