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

to reuse or to write my own ?

by tinman (Curate)
on Mar 18, 2001 at 02:27 UTC ( [id://65209]=perlquestion: print w/replies, xml ) Need Help??

tinman has asked for the wisdom of the Perl Monks concerning the following question:

Hi fellow Monks, My question is not anything to do with Perl syntax, but rather on style...

In the course of my work, I've discovered a lot of new and cool uses for Perl. Its pretty fair to say its saved me a lot of grunt work.. some of the uses that I've had for Perl include
checking an Oracle database for schema changes, and mailing these schema changes to myself (a hacked up Oracle change manager)
A squid log file interface
lotsa mail interfaces, to check/send mail out etc?

Now, through no choice of my own, my primary work OS is Windows, and I don't have access to Visual C++ (required for XS modules from CPAN).. so, where the ActivePerl repository doesn't have it, I end up writing my own stuff..

Should I share the stuff I do with others, even when there is a module already, or should I not "taint" the official module out there... I'd love to share my work, not only to help someone else out, but also because I think I can learn a lot about Perl that way...

What do you think ? and how should I go about using my code to serve someone else? any ideas ?

point to note is that a lot of the module code out there seems to intimidate me ;o) my stuff gets the job done, but I don't really know how clever it is... or isn't..

Replies are listed 'Best First'.
Re: to reuse or to write my own ?
by lhoward (Vicar) on Mar 18, 2001 at 02:55 UTC
    My vote is for share. I think there's always room for "pure perl" modules to sit aside their xs cousins. There are bound to be lots of people in a similar situation to you. I can think of 2 examples right now that are in CPAN: If you do publish to CPAN, I think you should probably notify the author of the original module (just so he doesn't stubmle into yours and become surprised) and name your module similarly, but distinctively diffrent from its xs cousin (I think the _PP standard used by the 2 modules I refrenced above is good).
Re: to reuse or to write my own ?
by arhuman (Vicar) on Mar 18, 2001 at 02:55 UTC
    Try if possible to reuse existing modules, enhancing them is ok too.
    (Laziness ?)

    If you modify/enhance an existing module submit the patches to the author.
    (hubris ?)

    If you write a new module, (impatience ?) submit it to peer review polish it and then make it publicly available...

    This way you'll get benefit of others experience, enhance things, avoid unnecessery 'pollution' of the modules list and get feedback about your code.

    "Trying to be a SMART lamer" (thanx to Merlyn ;-)
Re: to reuse or to write my own ?
by BrotherAde (Pilgrim) on Mar 18, 2001 at 06:03 UTC
Re: to reuse or to write my own ?
by repson (Chaplain) on Mar 18, 2001 at 06:12 UTC
    >> Visual C++ (required for XS modules from CPAN)

    I thought I'd just point out the existence of cygwin, a vastly (IMHO) superior command line and perl enviroment for windows including software such as gcc, bash, make, vim and perl. These make it easy to build most modules with the standard cpan shell interface. I have had some trouble with some modules (Win98), but the majority works fine.

Re: to reuse or to write my own ?
by BrotherAde (Pilgrim) on Mar 18, 2001 at 17:09 UTC
    Addition to both posts above: Whichever version of make (nmake, dmake or cygwin's "make") you use, do not forget to tell perl which one you're using.

    This is done in config.pm, the relevant line being

    make='nmake' #or dmake, or make...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://65209]
Approved by root
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2024-03-29 08:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found