grep results not jumping back

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Kevin
Posts: 28
Joined: Tue Apr 01, 2003 7:55 pm

grep results not jumping back

Post by Kevin »

I have set up grep to find all locations of a selected word like this:

[x] use POSIX regex syntax
[x] Capture Output

regex to match output

Code: Select all

^\([[:digit:]]+\):
File is blank, Line is 1, Column is blank

These settings will capture what I am grepping for in a Command Results window without any problem. When I double click on a results line, it doesn't jump to the line in my source file.

What am I forgetting to do?
User avatar
MudGuard
Posts: 1295
Joined: Sun Mar 02, 2003 10:15 pm
Location: Munich, Germany
Contact:

Post by MudGuard »

what does the output of your grep look like exactly?

According to your regex, it should be
(123): whatever
Kevin
Posts: 28
Joined: Tue Apr 01, 2003 7:55 pm

Post by Kevin »

I changed the regex to match to:

Code: Select all

^[0-9]+:
And now my output looks like:

Code: Select all

2:whatever
6:whatever
10:whatever
14:whatever
It will jump back only to the first line of the source, not to the double clicked line. :?:
User avatar
MudGuard
Posts: 1295
Joined: Sun Mar 02, 2003 10:15 pm
Location: Munich, Germany
Contact:

Post by MudGuard »

^([0-9]+):
with 1 for line should do the trick (though I am not sure because the file name is missing, but try it ...
Kevin
Posts: 28
Joined: Tue Apr 01, 2003 7:55 pm

Post by Kevin »

Thanks Mud. Works great now.
Post Reply