Re: [RFA] New substitute-path commands

Jason Molenda
2006-07-06T21:19:54Z

On Jul 5, 2006, at 2:56 PM, Joel Brobecker wrote:

> The new commands are:
>
> (gdb) substitute-path add <from> <to>
> (gdb) substitute-path remove
> (gdb) substitute-path

For what it's worth we added a similar facility to Apple gdb. Our
command isn't very fancy:

(gdb) apropos pathname-sub
set pathname-substitutions -- Set string substitutions to be used when
searching for source files
show pathname-substitutions -- Show string substitutions to be used
when searching for source files

It takes a series of directory pairs, e.g.

(gdb) set pathname-substitutions /old1 /new1 /old2 /new2

etc. It uses buildargv to parse the arguments so they can be quoted.
Making it a standard set/show command gets us MI support for free.

J