puppet-property_list_key
puppet-property_list_key copied to clipboard
Nested values can't be set individually
Basically, consider a value property like this:
value => {
[
{
'one_key' => 'one_value'
}
{
'two_key' => 'two_value'
}
{
'three_key' => 'three_value'
}
[
}
If you wanted to manage just ONE of those nested dictionaries, you would have to manage the ENTIRE array of dictionaries or else the provider would clobber the entire file. We need to decide whether we want to just manage individual pieces of a value (probably, yes) or THE ENTIRE VALUE (most likely no). If you managed the entire value, then, in essence, you would have a key/value for the entire file...and plists are long mmmkay.
I'm having this same problem with persistent-others or persistent-apps. Having the ability to say add a shortcut to my dock would be nice. But this means I'd need to maintain the entire key or if I use something like array-add it would just continuously add the shortcuts on each run.
As an aside - If I recall correctly, I think I remember seeing @jhaals with a solution in Boxen for setting dock items in a specific order (but, of course, I can't find it now)
I actually gave up trying to do this and started manage the whole dock plist with boxen. It would be awesome to actually do it properly
Sweet. Just one thing.
action => "add", could this be ensure => present instead? Would be nice to keep it the puppet way.
Yes, have moved this into it's own issue
Thanks @grahamgilbert - that's the thing I was thinking of!
Thanks guys… yeah actually grabbed dockutil last night. Graham is there support for the After or Before part vs the Position?
https://github.com/kcrawford/dockutil
On Apr 4, 2013, at 2:05 PM, Gary Larizza [email protected] wrote:
Thanks @grahamgilbert - that's the thing I was thinking of!
— Reply to this email directly or view it on GitHub.
Not yet, but file an issue on the repo and I'll see what I can do.
On 4 Apr 2013, at 10:57 PM, cdenneen [email protected] wrote:
Thanks guys… yeah actually grabbed dockutil last night. Graham is there support for the After or Before part vs the Position?
https://github.com/kcrawford/dockutil
On Apr 4, 2013, at 2:05 PM, Gary Larizza [email protected] wrote:
Thanks @grahamgilbert - that's the thing I was thinking of!
— Reply to this email directly or view it on GitHub.
— Reply to this email directly or view it on GitHubhttps://github.com/glarizza/puppet-property_list_key/issues/4#issuecomment-15926633 .
I'd also like to add my vote for being able to manage nested values individually.
Yeah, this is pretty important for me as well.