rewriting++

100 different scripts sounds like a nightmare (especially if you didn't write them), but I suspect that you're likely to find a lot of overlap between various scripts.

Here's a possible sequence of events for the least painless port:

  1. As Beatnik suggests, you want to try to understand what the scripts are doing first
  2. Now try to understand what the tools the scripts need to accomplish their respective tasks are
  3. Now try to highlight areas for re-use -- e.g. database access wrappers for DBI, printing feedback to the user (either HTML, text, or graphical)
  4. These reusable elements are likely to be good candidates for either modules or objects, depending on what they do
    • Remember that objects are normally wrappers to data,
    • while modules are ways of reusing useful functions
    • This is very loose, but what I'm getting at is that in a scripting-oriented language, not everything has to be, nor should be, an object
  5. Comment, comment, comment -- how many times have you come back to your own code only to say: "What the hell was I trying to do here?"

HTH


In reply to Re: Re: How to modify existing code by jreades
in thread How to modify existing code by artist

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.