Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • I think I must have overheard you talking about it on Perlmonks.

    My first question is: why a module? From your description in plain English, it looks like it's basically the functionality for a script. Anyway.

    Second: I don't like the name. IIS is a webserver. Naming it Win32::IIS::Server is saying roughly the same thing twice.

    I propose Win32::IIS::Setup, as it is apparently devised to set up sites on IIS. "Config" might at first sight appear to mean the same thing, but then, I'd expect it to be able to chang
    • Thanks. I'll probably go with ::Setup then. My hope is to also allow the changing of current configurations on a site or virtual site, but I'm not yet familiar enough with all possible configuration options. I'll be doing a little more research and work on it before I upload.

      Thanks!

  • I'd note that you should probably be using Perl style method naming.

    ->create_site instead of ->createSite

    I used to have a similar disease, and it wasn't until about a year after I was releasing things regularly that I ended up wishing I'd done things the Perl way in the first place :(

    So use a "Perlish" method style. Trust me, you'll regret it if you don't later.

    Oh, and I also like Win32::IIS::Setup better than ::Server as well.
    • But I'll add I disagree with "do it as a script".

      Most scripts should ideally just be a wrapper around some module that does the real work. Thing of the script as more of a console interface to some functionality.

      It should handle launching and command line params and output, but do the work in the module.

      And the module should never assume console environment,.
      • Thanks for the encouragement of going with a module rather than a script. I was tossing the idea back and forth in my head for a while. I'll definitely go with doing it as a module now.

    • Thanks. I'll make sure and go for the "Perlish" method style.

      I'll more than likely go with ::Setup now instead of ::Server. I want to allow the module to change current configurations, but I'm not familiar enough with all of the configuration options that are available. I'll do some more research on that part.

      • Check perlstyle [perl.org]. It’s not gospel, and there’s also Perl Best Practices (which you can’t read online), but it should give you a feel for what Perl code culturally looks like. You are free to deviate from that, of course, but make sure you have reason to. Also, the more visible the deviation (and method names are about as visible as you can get), the better the reason should be.

        • Thanks for the link! I convinced my department to buy a copy of PBP about a month or so ago. I haven't gotten too far in it yet, but I've been reading through it off and on. I appreciate your help!

          • Just to be sure, in case you don’t know the site I linked – perldoc.perl.org [perl.org] is an online version of the docs that come with Perl. You can read the same thing by running perldoc perlstyle on your machine. See also perldoc perltoc.

            (To be honest, though, these days I use the site much more than the local docs. Browser interfaces with real links are so much nicer, and the pervasively linked, syntax highlighted code snippets on the site are lightyears beyond perldoc on a console. Just noting that