rnelson0 / puppet-local_user

Puppet module. Manage local users, setting an initial password but letting the user change it as needed afterward.
4 stars 5 forks source link

Replace validate_* with defined types. #65

Closed rnelson0 closed 7 years ago

rnelson0 commented 7 years ago

@bastelfreak You've converted a great many modules from undefined to defined types. Layout is still a little hokey to me. I'd appreciate your thoughts on the change, as well as layout that isn't confusing. The Variant[Boolean,Enum[...]] in particular makes it a little difficult to read. I thought about putting the variables on the following line when the type is really long but not sure that helps, either.

bastelfreak commented 7 years ago

I always do an autoformat in vim to align the =, like here: https://github.com/voxpupuli/puppet-nginx/blob/master/manifests/resource/geo.pp

The used plugin is: https://github.com/junegunn/vim-easy-align just go to any of the params and press: gaip=

bastelfreak commented 7 years ago

Stdlib::Absolutepath requires a bump of stdlib to 4.13.1

rnelson0 commented 7 years ago

You don't find the far-right alignment to be too offputting? I was more concerned with that than getting the alignment right at first. The type for $manage_groups is impossibly long.

bastelfreak commented 7 years ago

You can put it in an own datatype, this gets it a bit shorter. We've examples about it in https://github.com/voxpupuli/puppet-tea/tree/master/types

rnelson0 commented 7 years ago

That seems like I'd be creating spooky action at a distance here. Oh well. Thanks!