|
Open a member from the iProjects using the "Text Editor", in find
capture whatever you want and replace with whatever you want BUT put \R
for each new line replaced / added.
Example:
Before:
001000000000 // MOD# PCR# PGMR DATE DESCRIPTION
Find / Replace:
(00100)(0)(000000 // MOD# PCR# PGMR DATE DESCRIPTION)
$1$2$3\R$19$3\R
After:
001000000000 // MOD# PCR# PGMR DATE DESCRIPTION
001009000000 // MOD# PCR# PGMR DATE DESCRIPTION
Thanks, Matt
-----Original Message-----
From: wdsci-l-bounces@xxxxxxxxxxxx [mailto:wdsci-l-bounces@xxxxxxxxxxxx]
On Behalf Of Vern Hamberg
Sent: Wednesday, March 14, 2012 1:43 PM
To: Rational Developer for IBM i / Websphere Development Studio Client
forSystem i& iSeries
Subject: Re: [WDSCI-L] Compare showing sequence number differences -
offtopic
Nice, Paul - I'm glad to be corrected - maybe it's always been there,
but the help was not helpful, as I recall.
I realized I should've explained the backslash quoting the TextPad uses
- next time, eh?
I'll definitely take a look again - and I hope there's a special code
for newline and all that.
Thanks
Vern
On 3/14/2012 8:47 AM, Paul Bailey wrote:
The \1 capturing group replacement stumped me at first, until Irealised it was $1 not \1 for the first replacement, $2 for the second,
etc. I'm not sure when this appeared, I can't see it documented
anywhere, and I can't remember where I saw it first, but it works.
Google says it has been mentioned before on WDSCI-L back in 2006:
http://archive.midrange.com/wdsci-l/200605/msg00295.html
Some flavours of regular expression differ in minor ways, I guess. TheRDP help pages take you to the java.util.regex.Pattern javadoc for
regular expression help, but the capturing group replacement values
aren't right, so maybe there are other minor differences. (Such as the
inability to use \n as a replacement value.) I wonder if these are bugs
or misleading/erroneous documentation.
[mailto:wdsci-l-bounces@xxxxxxxxxxxx] On Behalf Of Vern Hamberg
-Paul.
-----Original Message-----
From: wdsci-l-bounces@xxxxxxxxxxxx
Sent: 14 March 2012 12:43for System i& iSeries
To: Rational Developer for IBM i / Websphere Development Studio Client
Subject: Re: [WDSCI-L] Compare showing sequence number differencesavailable in replacement strings - that's the main thing - searching is
Hi Paul
I've found that things like \1 for preserving found text are not
pretty good, replacing is lacking.
Now maybe there's more in 8.03 - I've not explored that - have theyimproved the support?
I'm in the LPEX editor - it seems that maybe the Eclipse editor isbetter, but I've never used that for RPG or CL source.
I'll reply privately on the RTC stuff, at least for now. No biggie.statement requires you to move source outside of RDP? I can't work out
Vern
On 3/14/2012 7:20 AM, Paul Bailey wrote:
The regex features in RDP are reasonably good. What kind of regex
inserting newlines, but everything else seems to work as you'd expect.
your recent posts. I'd be very interested to hear about your experiencesIncidentally, you mentioned moving to Rational Team Concert in one of
with installing and using RTC with RDP (and iProjects) as we are also
considering it but the move to iProjects is putting me off researching
too much further. Do you have a blog or something to write that kind of
report up on?
Client
-Paul
-----Original Message-----
From: wdsci-l-bounces@xxxxxxxxxxxx
[mailto:wdsci-l-bounces@xxxxxxxxxxxx] On Behalf Of Vern Hamberg
Sent: 14 March 2012 11:42
To: Rational Developer for IBM i / Websphere Development Studio
side-by-side compare in Textpad, but it does show diffs. I'm sure thingsfor System i& iSeries
Subject: Re: [WDSCI-L] Compare showing sequence number differences
:-) I hear you - the eclipse compare is very nice for regular text
files, although I still use TextPad for that - I have not seen a
like Notepad II or whatever the name are similar.
what was described here - source dates are involved. This uses theTrouble with comparing source -without SourceLanding's tool - is just
Eclipse compare, I believe.
just went looking, because I thought it was there. I think it's like theNow there is another compare tool - it is under the Edit menu - I
old CODE compare tool - it might be the LPEX editor tool - the one that
the setting to ignore sequence numbers might relate to.
name, so far as I can see - I had to go to the Edit menu - there may beThe latter tool is not accessible from a right-click on the member
a shortcut, I don't know after a quick look-see.
pink (red)and yellow highlighting.But take a look at this one - it shows the changes intermingled in
there, then use the really powerful regex functionality there, then copyBTW, I use Textpad for Search/Replace - I copy a block of source
the block back in to the LPEX editor.
HTH
Vern
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.