In the spirit of #1111254: Document the Hostmaster API, I'd love to see some more documentation of hooks in Provision.
Now, Drush hooks are pretty interesting (http://drush.ws/docs/drush.api.php), with built-in pre-, post-, -validate and -rollback hooks. So, I'm not really sure whether these need to be documented any further...
Since these never seem to be passed with parameters, I guess they depend on contexts (eek!). So, this then brings us to the infamous d() function. Despite the reassurances ("The d accessor is not to be feared!" ref.: http://community.aegirproject.org/node/322), I'm still pretty diffident to jump into this particular deep end.
Comment | File | Size | Author |
---|---|---|---|
#1 | provision-1205956-1-Document_the_provision_API.patch | 4.03 KB | helmo |
Comments
Comment #1
helmo CreditAttribution: helmo commentedThere is provision.api.php in the code.
Today was not the first time that I found myself wondering what the best function name was for a provision hook I need.
After digging around I therefore added a bunch of comment lines like "Implementation of drush_hook_COMMAND_validate()."
Hope it helps, it should not be difficult to do this for more functions.
Comment #2
helmo CreditAttribution: helmo commentedSetting the status appropriately.
Still applies to 6.x-1.x, 6.x-2.x and 7.x-2.x
Comment #3
Anonymous (not verified) CreditAttribution: Anonymous commentedHappy with this for now, it makes sense to confirm to how drush documents its own hooks. Thanks!