Implemented /script list

This commit is contained in:
James Booth
2015-10-17 22:30:01 +01:00
parent 0769fc6b1b
commit a35cbea732
7 changed files with 53 additions and 5 deletions

View File

@@ -698,6 +698,10 @@ cmd_script(ProfWin *window, const char * const command, gchar **args)
if (!res) {
cons_show("Could not find script %s", args[1]);
}
} else if (g_strcmp0(args[0], "list") == 0) {
GSList *scripts = scripts_list();
cons_show_scripts(scripts);
g_slist_free_full(scripts, g_free);
} else {
cons_bad_cmd_usage(command);
}