Re: ex.err & Geany
- Posted by ghaberek (admin) Mar 18, 2013
- 4149 views
K_D_R said...
Forked from Re: EuGeany 1.2
...snip...
So... If we had a little euphoria program, as you have described, which could be executed from Geany's builtin terminal interface upon a crash/error, it could pass the filename, error line, and error column to Geany. Indeed, multiple files could be opened if necessary, Yes?
Regards, Ken
Couldn't you just use crash_routine() for this?
include "std/error.e" include "std/text.e" function geany_crash( integer dummy ) integer fn = open( "ex.err", "r" ) if fn = -1 then return 0 end if object line = gets( fn ) if sequence( line ) then line = text:trim( line ) -- e.g. C:\path\to\file:1234 sequence command = sprintf( "geany \"%s\"", {line} ) system_exec( command ) end if close( fn ) return 0 and dummy end function crash_routine( routine_id("geany_crash") )
You could probably even wrap that in an ifdef DEBUG statement, and then add "-D DEBUG" to your run_cmd. Maybe you could even add custom "build targets" for Debug/Release.
-Greg