Which you can see everything pretty much ends in a comma or a ]. This extra editing before my parse is becoming tedious, can someone help me get this to work using the same junk source from above?
This is one way (amongst many). You could use the substitution operator to inject a newline character wherever you have '],'.
use strict; use warnings; while (<DATA>) { chomp; s/;/;\n/g; s/],/],\n/g; print; } __DATA__ window.Grid1 = new ComponentArt_Grid('Grid1'); Grid1.Data = [[33,'DOR00393','ActiveState ActivePerl 5.8.8 Build 819', +0,'Software','No','Yes','No','Yes','Yes','No','No','No','No','No'],[4 +93,'STP00A82','ActiveState Perl Dev DOR Modules 1.0',0,'Software','No +','Yes','No','Yes','No','No','No','No','No','No'],[34,'DOR00394','Act +iveState Perl Dev Kit 6.0 Pro Pack',0,'Software','No','No','No','Yes' +,'Yes','No','No','No','No','No'],[764,'','AD Group Request: Rev Repo +rts - Modify Access',1,'General','No','Yes','Yes','Yes','Yes','Yes',' +No','No','No','No'],[81,'STP0028A','Adesso Cyber Pad Software Suite 3 +.13',0,'Software','No','Yes','No','Yes','Yes','No','No','No','No','No +'],[371,'STP009FB','Adesso Cyberpad 3.14

In reply to Re: Basic regex to parse source code by toolic
in thread Basic regex to parse source code by Anonymous Monk

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.