[Geany-Users] Geany cannot jump to the line with error

andrej.meszaros at agromel.sk andrej.meszaros at xxxxx
Thu Nov 8 14:01:38 UTC 2018


After research on internet and regex ... a found a solution.

Add this regex in build settings : (.+) \([^\d]*(\d+)[^\d]*\)

This works, when I click on error line, the line is showed in editor.

Andrej





On 2018-11-08 10:52, andrej.meszaros at agromel.sk wrote:
> I make some tests.
> 
> Make C project. Make errors in it. Compile, Get errors. Click, and it 
> works.
> 
> The error line uses this format :
> <file name> ":" <line number with error> ":"
> This format can recognize the Geany.
> 
> The error line from GCBasic compiler is a little bit different.
> <file name> "(" <line number with error> ")"
> This is not recognized correctly.
> 
> So I need to change the regex.
> 
> Where can I find regex and how to change to get the correct format ?
> 
> Can somebody help ?
> 
> Regards
> 
> Andrej
> 
> 
> On 2018-11-08 01:30, Lex Trotman wrote:
>> On Thu, 8 Nov 2018 at 09:27, Colomban Wendling
>> <lists.ban at herbesfolles.org> wrote:
>>> 
>>> Le 07/11/2018 à 11:41, Lex Trotman a écrit :
>>> > […]
>>> > It would appear that the location of the file as the build system
>>> > thinks it is doesn't agree with where the editor thinks it is,
>>> > otherwise it would just jump to the line in the already open buffer.
>>> 
>>> Isn't the problem simply that the format of the error message doesn't
>>> match the default error_regex? see
>>> https://www.geany.org/manual/#build-settings-section
>> 
>> Well, the images in the OP shows that the error message is recognised
>> as an error (its red and clickable), and its trying to find the right
>> filename, just its looking for it in the wrong place.  So presumably
>> the weird fallback parsing for basic in
>> msgwindow.c:parse_compiler_error_line()  is working after the regex
>> fails.
>> 
>> Cheers
>> Lex
>> 
>>> 
>>> Regards,
>>> Colomban
>>> _______________________________________________
>>> Users mailing list
>>> Users at lists.geany.org
>>> https://lists.geany.org/cgi-bin/mailman/listinfo/users
>> _______________________________________________
>> Users mailing list
>> Users at lists.geany.org
>> https://lists.geany.org/cgi-bin/mailman/listinfo/users
> _______________________________________________
> Users mailing list
> Users at lists.geany.org
> https://lists.geany.org/cgi-bin/mailman/listinfo/users






More information about the Users mailing list