/*
** 1998-09-12 -	A simple yet very useful command; pop up the list of built-ins, and
**		let the user pick one. Then run that command!
** 1998-09-27 -	Reimplemented using the new command sequence architecture (and dialog).
**		Renamed the module too, since there is no longer any need for a RunUser
**		command.
** 1999-03-29 -	Simplified thanks to new cmdseq_dialog semantics.
*/

#include "gentoo.h"

#include "cmdseq.h"
#include "cmdseq_dialog.h"

#include "cmd_run.h"

/* ----------------------------------------------------------------------------------------- */

/* 1998-09-27 -	Pop up a dialog letting user select (or type) a command name,
**		and then run it.
*/
int cmd_run(MainInfo *min, DirPane *src, DirPane *dst, CmdArg *ca)
{
	const gchar	*cmd;

	if((cmd = csq_dialog(min, NULL)) != NULL)
		csq_execute(min, cmd);
	return 1;
}
