Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Module configuration for user vs. developer

by herveus (Parson)
on May 31, 2006 at 15:10 UTC ( #552823=note: print w/ replies, xml ) Need Help??


in reply to Module configuration for user vs. developer

Howdy!

Makefile.PL (or the functional equivalent if you are using Module::Build)

You can interact with the user when they do "perl Makefile.PL". For example, you could ask them which back-end to use and pass that information on somehow. Can you abstract out the choice of back-end into a simple configuration item? Alternately, you might be able to mechanically discover answers (or potential answers to confirm with the user).

Makefile.PL can do a lot of stuff when it's necessary. You just write suitable code, although the implementation details can be "interesting". I did this once a while back, so I'm fuzzy on the details, but I know that you can do it. You might also look at modules that interact with you when you run 'perl Makefile.PL' and steal ideas.

yours,
Michael


Comment on Re: Module configuration for user vs. developer
Re^2: Module configuration for user vs. developer
by bibliophile (Parson) on May 31, 2006 at 15:38 UTC
    Absolutely, the choice of back-end can become a simple config item. I'm a little (ok, more than a little) makefile-challenged, so I need to hit the books on this.

    The further bit of complication is that whichever data store is used must have a bit of pre-configuration done before the test suite can run (hmm... maybe I can set up a "test" that does this, which can run as the first test....).
    This would make the pick-one-at-make-time a good option.

    -- WARNING: You are logged into reality as root.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://552823]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (14)
As of 2014-08-28 16:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (264 votes), past polls