Issue #6978 has been updated by Daniel Pittman.

An example, from current code, of how this might theoretically be used:

    # option "--ca-location LOCATION" do
    #   type [:whatever, :location, :symbols]
    #   hook :before do |value|
    #     Puppet::SSL::Host.ca_location = value
    #   end
    # end

----------------------------------------
Feature #6978: string and action options should have hooks for various 
actions...
https://projects.puppetlabs.com/issues/6978

Author: Daniel Pittman
Status: Unreviewed
Priority: Normal
Assignee: Daniel Pittman
Category: strings
Target version: 2.6.8
Affected Puppet version: development
Keywords: 
Branch: 


We need to do a few regular things when it comes to arguments:

 * custom coercion of the arguments
 * invoke some code before an action is invoked, if this option is set
 * invoke some code after an action is invoked, if this option is set
 * invoke some code around an action being invoked, if this option is set

Ideally this should all be expressed directly in the option code, rather than 
having to hand-write it each time.  This should reduce some of the repetition 
in common uses of string-wide options, at least.


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to