Skip to content

puppet-lint-strict_indent-check --fix makes it worse instead of better #33

@shibumi

Description

@shibumi

Hi,

We have the following code:

  file { ['/opt/foo/var',
          '/opt/foo/log',
          '/opt/foo/bar']:
    ensure => directory,
    owner  => 'root',
    group  => 'root',
    mode   => '0755',
  }

The formatter makes out of this perfectly fine code something like this:

  file { ['/opt/dbe/dirtdb',
      '/opt/dbe/log',
    '/opt/dbe/sox']:
      ensure => directory,
      owner  => 'root',
      group  => 'root',
      mode   => '0755',
  }

This is not the only occurence. Looks like the formatter is formatting code incorrectly in several other places as well.
For example in one occurence it made out of a file:

class bar::foo {
...
exec { 'foobarbazinga':
    command => '/usr/sbin/command',
    unless  => '/usr/sbin/command2',
  }
}

Something like this:

class bar::foo {
...
exec { 'foobarbazinga':
    command => '/usr/sbin/command',
    unless  => '/usr/sbin/command2',
} }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions