Conversation
There was a problem hiding this comment.
For the above code, I wanted to dynamically construct the arguments type, nfs_version, and nfs_udp so I could not have to copy the other parameters. Sadly, my Ruby skills are nonexistent, and I'm coding on an airplane without Internet access for Ruby documentation. In Python, I'd do something like this:
params = {type: 'nfs'}
if vm_sync == "nfs4":
params['nfs_version'] = 4
params['nfs_udp'] = False
function(some_stuff, **params)
If you can tell me how to do that I'll change it.
|
Great patch @rbarlow ... I'm tempted to merge this as is, but I'll shoot out a few questions first...
a) Here in your branch at the puppet sync location https://github.com/rbarlow/oh-my-vagrant/blob/nfs4/vagrant/Vagrantfile#L1392 b) In the atomic sync location too: https://github.com/rbarlow/oh-my-vagrant/blob/nfs4/vagrant/Vagrantfile#L986 Lastly, I don't know off hand the answer to your ruby question, but it's a good one, and doing so might make the code more elegant for the two other sync areas... In reading this I did notice that I've used "sync" in at least two places that are in the main loop and should really be "vm_sync" -- so those are bugs :) Cheers, |
|
@rbarlow Hey awesome patch writer. OMV would love your contribution, got a fresh version for us? Thanks! |
No description provided.