| Randal | Flawless yes |
| f00li5h | Flawless: why not stuff foo() in a module? |
| Randal | but you should really learn about modules |
| Flawless | Randal: I know Randal: It's on my todo list ;) |
| Randal | then you can do "selective import" can't do that with require |
| action | f00li5h has pattern recognition |
| f00li5h | has pattern recognition |
| Flawless | f00li5h: would it make sense to put a module in /etc/fooapp.pm ? |
| f00li5h | Flawless: no. you want to put it somewhere listed in @INC |
| Flawless | f00li5h: it just seems a small simple require'd file would make more sense? |
| Randal | they always start out simle simple |
| f00li5h | Flawless: only if you don't know modules |
| Flawless | f00li5h: I could add /etc/fooapp/ to @INC.. |
| f00li5h | Flawless: that's true |
| Randal | this gets scarier and scarier |
| Flawless | is that considered a hack? |
| f00li5h | Flawless: it's all global and /etc/ is for config files you're looking for more of a /lib |
| Randal | Flawless - in the privacy of your own cube, do what you want |
| Flawless | Randal: hehe, thanks ;) |
| Randal | but please learn how it's done properly, soon |
| Flawless | Randal: I will |
| Randal | I can recommend a good book! (or two) |
| Flawless | This is the situation: Suppose I have quite a few perl subs that perform useful actions on a firewall |
| Randal | on the top of the wall? teetering there, precariously? |
| Flawless | now, writing a config file format (even with a very neat package that reads and parses the file), would take a very long time |
| Randal | you don't have to write the config file *format* that comes along with the module. :) I recommend Config::Scoped |
| Flawless | having a file somewhere in /etc/ that would call the subs, would be much easier |
| f00li5h | Flawless: and here's one i prepared earlier |
| Randal | it allows nested definitions |
| action | Flawless looks at Scoped |
| Flawless | looks at Scoped |
| Randal | and limited Perl execution |