[mercury-users] mdb default settings

Ralph Becket rafe at csse.unimelb.edu.au
Fri Sep 1 12:37:19 AEST 2006

Nicholas Nethercote, Friday,  1 September 2006:
> Hi,
> Is there a way to setup default settings in mdb?  I find myself typing 
> "format_param depth 10" and "format_param size 100" a lot.  I think GDB 
> lets you use a .gdb file or somesuch.

Yes.  From the "Mercury debugger invocation" part of the User's Guide:

	When the debugger starts up, as part of its initialization it
	executes commands from the following three sources, in order:

	   1. The file named by the MERCURY_DEBUGGER_INIT environment
	   variable.  Usually, mdb sets this variable to point to a file
	   that provides documentation for all the debugger commands and
	   defines a small set of aliases. However, if
	   MERCURY_DEBUGGER_INIT is already defined when mdb is invoked,
	   it will leave its value unchanged. You can use this override
	   ability to provide alternate documentation. If the file named
	   by MERCURY_DEBUGGER_INIT cannot be read, mdb will print a
	   warning, since in that case, that usual online documentation
	   will not be available.

	   2. The file named .mdbrc in your home directory. You can put
	   your usual aliases and settings here.

	   3. The file named .mdbrc in the current working directory.
	   You can put program-specific aliases and settings here. 

I have `S' aliased to `save .mdbrc' so I can easily save my current
settings in the working directory and have them read automatically
next time I run mdb.

-- Ralph
mercury-users mailing list
Post messages to:       mercury-users at csse.unimelb.edu.au
Administrative Queries: owner-mercury-users at csse.unimelb.edu.au
Subscriptions:          mercury-users-request at csse.unimelb.edu.au

More information about the users mailing list