Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things

Re: RegExp: pos management in global substitution

by Perlbotics (Chancellor)
on Sep 03, 2011 at 11:52 UTC ( #923982=note: print w/replies, xml ) Need Help??

in reply to RegExp: pos management in global substitution

I would use two regexp: first to check if line starts with {name_a and a second to remove all unwanted param_* entries:

m/wanted name_a-line/  and  s/unwanted parameters//g;

Replies are listed 'Best First'.
Re^2: RegExp: pos management in global substitution
by OlegG (Monk) on Sep 03, 2011 at 17:48 UTC
    I know. This is a purely scientific interest to do it with s/// only.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://923982]
[choroba]: Good morning! I'll be mostly absent today, a day off at work, children have concerts and other activities...
[Corion]: Hi choroba! Yay, day off sounds great! I hope the performances of the kids go well!

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (7)
As of 2017-12-12 08:49 GMT
Find Nodes?
    Voting Booth?
    What programming language do you hate the most?

    Results (327 votes). Check out past polls.