Having been inspired by Domm to fix one of my perltidy annoyances (it says something about the greatness of a tool that I keep using it even though there are some annoyances...).
I have these .perltidyrc settings:
--indent-columns=4 --cuddled-else --nooutdent-long-quotes --paren-tightness=2 --brace-tightness=2 --square-bracket-tightness=2
Some::Class->create(
{
foo => 3,
bar => 2,
baz => 1,
}
);
--stack-opening-tokens --stack-closing-tokens
Some::Class->create({
foo => 3,
bar => 2,
baz => 1,
});
Some::Class->create({
foo => 3,
bar => 2,
baz => 1,
});
Let me just second that.
I don't think that's configurable since it's a bit of a special case to only want to indent one of the structures.
Unfortunately Perl::Tidy doesn't seem to have any tests to speak of, so it's a bit of an effort to start hacking on it to add missing bits.