Puppet Homebrew Package Provider
Enough raving about homebrew now. I'm currently exploring Puppet , it has builtin support for macports (or as it calls it darwinports) but not for my new love. I guess it was the perfect excuse to write my own provider.
On the puppet wiki I found a document describing in generic terms what you need to do to write a custom provider. It's probably me, but I didn't get it when I read. Therefore I dug into the code of other providers. I found the gem provider most useful, but that's probably because I'm familiar with the gem command and output to see how it works.
It will only work in new versions of puppet as it uses the new directory structure lib/puppet instead of lib/plugins. There was one gotcha for me. I assumed that I needed to put my provider, well in the directory modulename/puppet/provider/ . It turns out that you need to put it in a subdirectory of the type your are implementing the provider for : module/puppet/provider/package in my case.
Code is up on github : https://github.com/jedi4ever/puppet-homebrew .
I hope one day, this provider gets into the main puppet provider list :)
References:
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)





Comments
Kyane Ben replied on Thu, 2012/03/15 - 12:33pm
chip, this implied voiding your console's warranty and not to mention the steep
prices at which mod chips were traded.