puppet-lint icon indicating copy to clipboard operation
puppet-lint copied to clipboard

Feature request - align class parameters

Open michalmiddleton opened this issue 8 years ago • 6 comments

I'd love if linter aligned parameters/variables in class definitions the way it aligns arrows. Example:

class mycompany::myprofiles::myclass (
    $var1 = 'default',
    $varother2   = hiera('mycompany::myprofiles::myclass::myvar2'),
    $var3     = 'something else',
) {
...
}

should be aligned as:

class mycompany::myprofiles::myclass (
    $var1         = 'default',
    $varother2    = hiera('mycompany::myprofiles::myclass::myvar2'),
    $var3         = 'something else',
) {
...
}

michalmiddleton avatar Feb 03 '17 21:02 michalmiddleton

https://github.com/puppetlabs/puppet-docs/pull/723

binford2k avatar Feb 23 '17 22:02 binford2k

Any update on this?

JacobHenner avatar Apr 02 '18 03:04 JacobHenner

I'd like this also +1

davehewy avatar Jun 13 '18 10:06 davehewy

+1

dekonnection avatar Jul 03 '19 10:07 dekonnection

Just bumped into this. I would love it for consistency with the alignment behaviour with Hash rockets.

sp-ricard-valverde avatar Sep 30 '21 14:09 sp-ricard-valverde

I think anhpt379/puppet-lint-class_alignment-check implements this.

thde avatar Jul 25 '24 09:07 thde