I was given a project that seems to require Perl I could use a sample just to extract a list of names associated with a group or repo and print them.
1) Assigned a task to extract data fron a text file. 2) Output file needs to be very specific, and created monthly 3) tried doing in korn shell too complex 4) Figured Perl my best option, but don't know Perl 5) Got the Modern Perl in PDF format 6) Installed Strawberry Perl Output format is simple ??, but extracting the data and printing it I haven't a clue where to start. ( I am not trying to get someone to write this for me, just a simple extract and print example and point me in the right direction ) Desired output: [code] UserName~RepoName/PATH~GroupName~Access (Note: _admn is a special case and repeated in every Repo so its output would look like UserName~~GroupName~Read Write Access Access need to be spelled out r = Read only, rw = Read Write) [/code] Example Input File: [code] #[groups] svnAdmins_admn = johnl1, bill4, saras2 auditors_cgrp = dave101 other_cgrp = gullapp, pughj, frayerm1, naidue, ramseym4, kochw, leej95, joness22, davidsm9 build_cgrp = mohameh, johnsod5 foospecial_cgrp = browng3, mintzh, scottj11, svnbeta barspecial_cgrp = lambt4, cheny1, locklie, nicholk9 repo1_devs = ritched2, appalas, bohnerc, davidss1, goulett2, kriegn, kumara19, kumarr19 repo1_owners = nadign, pengh1, poojary, predovc, settyp, shirwan repo1_readers = mandeh1, dinwidg, pals, rajendk1, pantk repo2_devs = yonuta1, cmbuild, carmacs, greeng1, rickg repo2_owners = sundarb1, dhayagp, thoomuv repo2_readers = buschm2, todorob, shukkun, enjetyv1 #[Repo access rules] [repo1:/] @repo1_devs = r @repo1_owners = rw @repo1_readers = r @svnAdmins_admn = rw @auditors_cgrp = r @other_cgrp = r @build_cgrp = r @foospecial_cgrp = r [repo1:/branches] @repo1_devs = rw @foospecial_cgrp = rw [repo1:/tags] @foospecial_cgrp = rw [repo1:/trunk] @repo1_devs = rw [repo1:/trunk/project1] @repo1_devs = rw @other_cgrp = rw [repo1:/trunk/project2] @foospecial_cgrp = rw @repo1_devs = rw [repo1:/trunk/project3] @repo1_devs = rw @build_cgrp = rw [repo2:/] @repo1_devs = r @repo1_owners = rw @repo1_readers = r @svnAdmins_admn = rw @auditors_cgrp = r @foospecial_cgrp = r [repo2:/branches] @repo1_devs = rw [repo2:/tags] @foospecial_cgrp = rw [repo2:/trunk] @repo1_devs = rw [repo2:/trunk/project1] @repo2_devs = rw @other_cgrp = rw [repo2:/trunk/project2/foo] @repo1_devs = rw @foospecial_cgrp = rw @barspecial_cgrp = r [repo2:/trunk/project3/foo/bar] @repo1_devs = rw @build_cgrp = rw @barspecial_cgrp = rw [/code] phil -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/