aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/app_queue.c31
-rw-r--r--apps/app_voicemail.c8
-rw-r--r--channels/chan_agent.c8
-rw-r--r--channels/chan_features.c11
-rw-r--r--channels/chan_iax2.c82
-rw-r--r--channels/chan_local.c11
-rw-r--r--channels/chan_mgcp.c53
-rw-r--r--channels/chan_sip.c145
-rw-r--r--channels/chan_skinny.c45
-rw-r--r--main/asterisk.c28
-rw-r--r--main/channel.c8
-rw-r--r--main/cli.c177
-rw-r--r--main/config.c4
-rw-r--r--main/file.c4
-rw-r--r--main/frame.c10
-rw-r--r--main/http.c11
-rw-r--r--main/image.c4
-rw-r--r--main/logger.c11
-rw-r--r--main/manager.c16
-rw-r--r--main/pbx.c22
-rw-r--r--res/res_agi.c6
-rw-r--r--res/res_crypto.c4
-rw-r--r--res/res_features.c2
-rw-r--r--res/res_indications.c4
-rw-r--r--res/res_musiconhold.c4
-rw-r--r--res/res_odbc.c11
26 files changed, 220 insertions, 500 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c
index 380036181..b2ea75d3d 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -3866,12 +3866,12 @@ static int reload_queues(void)
return 1;
}
-static int __queues_show(struct mansession *s, int manager, int fd, int argc, char **argv, int queue_show)
+static int __queues_show(struct mansession *s, int manager, int fd, int argc, char **argv)
{
struct call_queue *q;
struct queue_ent *qe;
struct member *mem;
- int pos;
+ int pos, queue_show;
time_t now;
char max_buf[80];
char *max;
@@ -3880,7 +3880,11 @@ static int __queues_show(struct mansession *s, int manager, int fd, int argc, ch
char *term = manager ? "\r\n" : "\n";
time(&now);
- if ((!queue_show && argc != 2) || (queue_show && argc != 3))
+ if (argc == 2)
+ queue_show = 0;
+ else if (argc == 3)
+ queue_show = 1;
+ else
return RESULT_SHOWUSAGE;
/* We only want to load realtime queues when a specific queue is asked for. */
@@ -3994,14 +3998,9 @@ static int __queues_show(struct mansession *s, int manager, int fd, int argc, ch
return RESULT_SUCCESS;
}
-static int queue_list(int fd, int argc, char **argv)
-{
- return __queues_show(NULL, 0, fd, argc, argv, 0);
-}
-
static int queue_show(int fd, int argc, char **argv)
{
- return __queues_show(NULL, 0, fd, argc, argv, 1);
+ return __queues_show(NULL, 0, fd, argc, argv);
}
static char *complete_queue(const char *line, const char *word, int pos, int state)
@@ -4028,9 +4027,9 @@ static char *complete_queue(const char *line, const char *word, int pos, int sta
*/
static int manager_queues_show( struct mansession *s, struct message *m )
{
- char *a[] = { "queue", "list" };
+ char *a[] = { "queue", "show" };
- __queues_show(s, 1, -1, 2, a, 0);
+ __queues_show(s, 1, -1, 2, a);
astman_append(s, "\r\n\r\n"); /* Properly terminate Manager output */
return RESULT_SUCCESS;
@@ -4381,10 +4380,6 @@ static char *complete_queue_remove_member(const char *line, const char *word, in
return NULL;
}
-static char queue_list_usage[] =
-"Usage: queue list\n"
-" Provides summary information on call queues.\n";
-
static char queue_show_usage[] =
"Usage: queue show\n"
" Provides summary information on a specified queue.\n";
@@ -4397,7 +4392,7 @@ static char qrm_cmd_usage[] =
static struct ast_cli_entry cli_show_queues_deprecated = {
{ "show", "queues", NULL },
- queue_list, NULL,
+ queue_show, NULL,
NULL, NULL };
static struct ast_cli_entry cli_show_queue_deprecated = {
@@ -4416,10 +4411,6 @@ static struct ast_cli_entry cli_remove_queue_member_deprecated = {
NULL, complete_queue_remove_member };
static struct ast_cli_entry cli_queue[] = {
- { { "queue", "list", NULL },
- queue_list, "Show status of queues",
- queue_list_usage, NULL, &cli_show_queues_deprecated },
-
{ { "queue", "show", NULL },
queue_show, "Show status of a specified queue",
queue_show_usage, complete_queue, &cli_show_queue_deprecated },
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index ef85586d0..56c17e8a7 100644
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -6645,11 +6645,11 @@ static int vmauthenticate(struct ast_channel *chan, void *data)
}
static char voicemail_show_users_help[] =
-"Usage: voicemail list users [for <context>]\n"
+"Usage: voicemail show users [for <context>]\n"
" Lists all mailboxes currently set up\n";
static char voicemail_show_zones_help[] =
-"Usage: voicemail list zones\n"
+"Usage: voicemail show zones\n"
" Lists zone message formats\n";
static int handle_voicemail_show_users(int fd, int argc, char *argv[])
@@ -6766,11 +6766,11 @@ static struct ast_cli_entry cli_show_voicemail_zones_deprecated = {
NULL, NULL };
static struct ast_cli_entry cli_voicemail[] = {
- { { "voicemail", "list", "users", NULL },
+ { { "voicemail", "show", "users", NULL },
handle_voicemail_show_users, "List defined voicemail boxes",
voicemail_show_users_help, complete_voicemail_show_users, &cli_show_voicemail_users_deprecated },
- { { "voicemail", "list", "zones", NULL },
+ { { "voicemail", "show", "zones", NULL },
handle_voicemail_show_zones, "List zone message formats",
voicemail_show_zones_help, NULL, &cli_show_voicemail_zones_deprecated },
};
diff --git a/channels/chan_agent.c b/channels/chan_agent.c
index 92027fb5e..23ef874f1 100644
--- a/channels/chan_agent.c
+++ b/channels/chan_agent.c
@@ -1721,11 +1721,11 @@ static int agents_show_online(int fd, int argc, char **argv)
static char show_agents_usage[] =
-"Usage: agent list\n"
+"Usage: agent show\n"
" Provides summary information on agents.\n";
static char show_agents_online_usage[] =
-"Usage: agent list online\n"
+"Usage: agent show online\n"
" Provides a list of all online agents.\n";
static char agent_logoff_usage[] =
@@ -1744,11 +1744,11 @@ static struct ast_cli_entry cli_show_agents_online_deprecated = {
NULL, NULL };
static struct ast_cli_entry cli_agents[] = {
- { { "agent", "list", NULL },
+ { { "agent", "show", NULL },
agents_show, "Show status of agents",
show_agents_usage, NULL, &cli_show_agents_deprecated },
- { { "agent", "list", "online" },
+ { { "agent", "show", "online" },
agents_show_online, "Show all online agents",
show_agents_online_usage, NULL, &cli_show_agents_online_deprecated },
diff --git a/channels/chan_features.c b/channels/chan_features.c
index 0f239ce4b..4e3d8ec31 100644
--- a/channels/chan_features.c
+++ b/channels/chan_features.c
@@ -530,18 +530,13 @@ static int features_show(int fd, int argc, char **argv)
}
static char show_features_usage[] =
-"Usage: feature list channels\n"
+"Usage: feature show channels\n"
" Provides summary information on feature channels.\n";
-static struct ast_cli_entry cli_features_show_channels_deprecated = {
- { "feature", "show", "channels", NULL },
- features_show, NULL,
- NULL };
-
static struct ast_cli_entry cli_features[] = {
- { { "feature", "list", "channels", NULL },
+ { { "feature", "show", "channels", NULL },
features_show, "List status of feature channels",
- show_features_usage, NULL, &cli_features_show_channels_deprecated },
+ show_features_usage },
};
static int load_module(void)
diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c
index 642dd6d61..5bb88d9b2 100644
--- a/channels/chan_iax2.c
+++ b/channels/chan_iax2.c
@@ -4424,55 +4424,27 @@ static int iax2_do_jb_debug(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int iax2_no_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 3)
- return RESULT_SHOWUSAGE;
- iaxdebug = 0;
- ast_cli(fd, "IAX2 Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int iax2_no_debug(int fd, int argc, char *argv[])
{
- if (argc != 2)
+ if (argc != 3)
return RESULT_SHOWUSAGE;
iaxdebug = 0;
ast_cli(fd, "IAX2 Debugging Disabled\n");
return RESULT_SUCCESS;
}
-static int iax2_no_trunk_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 4)
- return RESULT_SHOWUSAGE;
- iaxtrunkdebug = 0;
- ast_cli(fd, "IAX2 Trunk Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int iax2_no_trunk_debug(int fd, int argc, char *argv[])
{
- if (argc != 3)
+ if (argc != 4)
return RESULT_SHOWUSAGE;
iaxtrunkdebug = 0;
ast_cli(fd, "IAX2 Trunk Debugging Disabled\n");
return RESULT_SUCCESS;
}
-static int iax2_no_jb_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 4)
- return RESULT_SHOWUSAGE;
- jb_setoutput(jb_error_output, jb_warning_output, NULL);
- jb_debug_output("\n");
- ast_cli(fd, "IAX2 Jitterbuffer Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int iax2_no_jb_debug(int fd, int argc, char *argv[])
{
- if (argc != 3)
+ if (argc != 4)
return RESULT_SHOWUSAGE;
jb_setoutput(jb_error_output, jb_warning_output, NULL);
jb_debug_output("\n");
@@ -9637,11 +9609,11 @@ static struct ast_switch iax2_switch =
};
static char show_stats_usage[] =
-"Usage: iax2 list stats\n"
+"Usage: iax2 show stats\n"
" Display statistics on IAX channel driver.\n";
static char show_cache_usage[] =
-"Usage: iax2 list cache\n"
+"Usage: iax2 show cache\n"
" Display currently cached IAX Dialplan results.\n";
static char show_peer_usage[] =
@@ -9664,34 +9636,34 @@ static char show_prov_usage[] =
" fields will be provisioned as empty fields.\n";
static char show_users_usage[] =
-"Usage: iax2 list users [like <pattern>]\n"
+"Usage: iax2 show users [like <pattern>]\n"
" Lists all known IAX2 users.\n"
" Optional regular expression pattern is used to filter the user list.\n";
static char show_channels_usage[] =
-"Usage: iax2 list channels\n"
+"Usage: iax2 show channels\n"
" Lists all currently active IAX channels.\n";
static char show_netstats_usage[] =
-"Usage: iax2 list netstats\n"
+"Usage: iax2 show netstats\n"
" Lists network status for all currently active IAX channels.\n";
static char show_threads_usage[] =
-"Usage: iax2 list threads\n"
+"Usage: iax2 show threads\n"
" Lists status of IAX helper threads\n";
static char show_peers_usage[] =
-"Usage: iax2 list peers [registered] [like <pattern>]\n"
+"Usage: iax2 show peers [registered] [like <pattern>]\n"
" Lists all known IAX2 peers.\n"
" Optional 'registered' argument lists only peers with known addresses.\n"
" Optional regular expression pattern is used to filter the peer list.\n";
static char show_firmware_usage[] =
-"Usage: iax2 list firmware\n"
+"Usage: iax2 show firmware\n"
" Lists all known IAX firmware images.\n";
static char show_reg_usage[] =
-"Usage: iax2 list registry\n"
+"Usage: iax2 show registry\n"
" Lists all registration requests and status.\n";
static char debug_usage[] =
@@ -9748,17 +9720,17 @@ static struct ast_cli_entry cli_iax2_jb_debug_deprecated = {
static struct ast_cli_entry cli_iax2_no_debug_deprecated = {
{ "iax2", "no", "debug", NULL },
- iax2_no_debug_deprecated, NULL,
+ iax2_no_debug, NULL,
NULL };
static struct ast_cli_entry cli_iax2_no_trunk_debug_deprecated = {
{ "iax2", "no", "trunk", "debug", NULL },
- iax2_no_trunk_debug_deprecated, NULL,
+ iax2_no_trunk_debug, NULL,
NULL };
static struct ast_cli_entry cli_iax2_no_jb_debug_deprecated = {
{ "iax2", "no", "jb", "debug", NULL },
- iax2_no_jb_debug_deprecated, NULL,
+ iax2_no_jb_debug, NULL,
NULL };
static struct ast_cli_entry cli_iax2_show_cache_deprecated = {
@@ -9806,39 +9778,39 @@ static struct ast_cli_entry cli_iax2_show_registry_deprecated = {
show_reg_usage };
static struct ast_cli_entry cli_iax2[] = {
- { { "iax2", "list", "cache", NULL },
+ { { "iax2", "show", "cache", NULL },
iax2_show_cache, "Display IAX cached dialplan",
show_cache_usage, NULL, &cli_iax2_show_cache_deprecated },
- { { "iax2", "list", "channels", NULL },
+ { { "iax2", "show", "channels", NULL },
iax2_show_channels, "List active IAX channels",
show_channels_usage, NULL, &cli_iax2_show_channels_deprecated },
- { { "iax2", "list", "firmware", NULL },
+ { { "iax2", "show", "firmware", NULL },
iax2_show_firmware, "List available IAX firmwares",
show_firmware_usage, NULL, &cli_iax2_show_firmware_deprecated },
- { { "iax2", "list", "netstats", NULL },
+ { { "iax2", "show", "netstats", NULL },
iax2_show_netstats, "List active IAX channel netstats",
show_netstats_usage, NULL, &cli_iax2_show_netstats_deprecated },
- { { "iax2", "list", "peers", NULL },
+ { { "iax2", "show", "peers", NULL },
iax2_show_peers, "List defined IAX peers",
show_peers_usage, NULL, &cli_iax2_show_peers_deprecated },
- { { "iax2", "list", "registry", NULL },
+ { { "iax2", "show", "registry", NULL },
iax2_show_registry, "Display IAX registration status",
show_reg_usage, NULL, &cli_iax2_show_registry_deprecated },
- { { "iax2", "list", "stats", NULL },
+ { { "iax2", "show", "stats", NULL },
iax2_show_stats, "Display IAX statistics",
show_stats_usage, NULL, &cli_iax2_show_stats_deprecated },
- { { "iax2", "list", "threads", NULL },
+ { { "iax2", "show", "threads", NULL },
iax2_show_threads, "Display IAX helper thread info",
show_threads_usage, NULL, &cli_iax2_show_threads_deprecated },
- { { "iax2", "list", "users", NULL },
+ { { "iax2", "show", "users", NULL },
iax2_show_users, "List defined IAX users",
show_users_usage, NULL, &cli_iax2_show_users_deprecated },
@@ -9866,15 +9838,15 @@ static struct ast_cli_entry cli_iax2[] = {
iax2_do_jb_debug, "Enable IAX jitterbuffer debugging",
debug_jb_usage, NULL, &cli_iax2_jb_debug_deprecated },
- { { "iax2", "nodebug", NULL },
+ { { "iax2", "debug", "off", NULL },
iax2_no_debug, "Disable IAX debugging",
no_debug_usage, NULL, &cli_iax2_no_debug_deprecated },
- { { "iax2", "nodebug", "trunk", NULL },
+ { { "iax2", "debug", "trunk", "off", NULL },
iax2_no_trunk_debug, "Disable IAX trunk debugging",
no_debug_trunk_usage, NULL, &cli_iax2_no_trunk_debug_deprecated },
- { { "iax2", "nodebug", "jb", NULL },
+ { { "iax2", "debug", "jb", "off", NULL },
iax2_no_jb_debug, "Disable IAX jitterbuffer debugging",
no_debug_jb_usage, NULL, &cli_iax2_no_jb_debug_deprecated },
diff --git a/channels/chan_local.c b/channels/chan_local.c
index 9896f0f1d..863820586 100644
--- a/channels/chan_local.c
+++ b/channels/chan_local.c
@@ -626,18 +626,13 @@ static int locals_show(int fd, int argc, char **argv)
}
static char show_locals_usage[] =
-"Usage: local list channels\n"
+"Usage: local show channels\n"
" Provides summary information on active local proxy channels.\n";
-static struct ast_cli_entry cli_local_show_channels_deprecated = {
- { "local", "show", "channels", NULL },
- locals_show, NULL,
- NULL };
-
static struct ast_cli_entry cli_local[] = {
- { { "local", "list", "channels", NULL },
+ { { "local", "show", "channels", NULL },
locals_show, "List status of local channels",
- show_locals_usage, NULL, &cli_local_show_channels_deprecated },
+ show_locals_usage },
};
/*! \brief Load module into PBX, register channel */
diff --git a/channels/chan_mgcp.c b/channels/chan_mgcp.c
index 778fd4ca7..9c7c26e13 100644
--- a/channels/chan_mgcp.c
+++ b/channels/chan_mgcp.c
@@ -1040,11 +1040,11 @@ static int mgcp_show_endpoints(int fd, int argc, char *argv[])
}
static char show_endpoints_usage[] =
-"Usage: mgcp endpoint list\n"
+"Usage: mgcp show endpoints\n"
" Lists all endpoints known to the MGCP (Media Gateway Control Protocol) subsystem.\n";
static char audit_endpoint_usage[] =
-"Usage: mgcp endpoint audit <endpointid>\n"
+"Usage: mgcp audit endpoint <endpointid>\n"
" Lists the capabilities of an endpoint in the MGCP (Media Gateway Control Protocol) subsystem.\n"
" mgcp debug MUST be on to see the results of this command.\n";
@@ -1053,12 +1053,13 @@ static char debug_usage[] =
" Enables dumping of MGCP packets for debugging purposes\n";
static char no_debug_usage[] =
-"Usage: mgcp nodebug\n"
+"Usage: mgcp debug off\n"
" Disables dumping of MGCP packets for debugging purposes\n";
static char mgcp_reload_usage[] =
"Usage: mgcp reload\n"
-" Reloads MGCP configuration from mgcp.conf\n";
+" Reloads MGCP configuration from mgcp.conf\n"
+" Deprecated: please use 'reload chan_mgcp.so' instead.\n";
static int mgcp_audit_endpoint(int fd, int argc, char *argv[])
{
@@ -1122,55 +1123,31 @@ static int mgcp_do_debug(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int mgcp_no_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 3)
- return RESULT_SHOWUSAGE;
- mgcpdebug = 0;
- ast_cli(fd, "MGCP Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int mgcp_no_debug(int fd, int argc, char *argv[])
{
- if (argc != 2)
+ if (argc != 3)
return RESULT_SHOWUSAGE;
mgcpdebug = 0;
ast_cli(fd, "MGCP Debugging Disabled\n");
return RESULT_SUCCESS;
}
-static struct ast_cli_entry cli_mgcp_no_debug_deprecated = {
- { "mgcp", "no", "debug", NULL },
- mgcp_no_debug_deprecated, NULL,
- NULL };
-
-static struct ast_cli_entry cli_mgcp_audit_endpoint_deprecated = {
- { "mgcp", "audit", "endpoint", NULL },
- mgcp_audit_endpoint, NULL,
- NULL };
-
-static struct ast_cli_entry cli_mgcp_show_endpoints_deprecated = {
- { "mgcp", "show", "endpoints", NULL },
- mgcp_show_endpoints, NULL,
- NULL };
-
static struct ast_cli_entry cli_mgcp[] = {
- { { "mgcp", "endpoint", "audit", NULL },
+ { { "mgcp", "audit", "endpoint", NULL },
mgcp_audit_endpoint, "Audit specified MGCP endpoint",
- audit_endpoint_usage, NULL, &cli_mgcp_audit_endpoint_deprecated },
+ audit_endpoint_usage },
- { { "mgcp", "endpoint", "list", NULL },
+ { { "mgcp", "show", "endpoints", NULL },
mgcp_show_endpoints, "List defined MGCP endpoints",
- show_endpoints_usage, NULL, &cli_mgcp_show_endpoints_deprecated },
+ show_endpoints_usage },
{ { "mgcp", "debug", NULL },
mgcp_do_debug, "Enable MGCP debugging",
debug_usage },
- { { "mgcp", "nodebug", NULL },
+ { { "mgcp", "debug", "off", NULL },
mgcp_no_debug, "Disable MGCP debugging",
- no_debug_usage, NULL, &cli_mgcp_no_debug_deprecated },
+ no_debug_usage },
{ { "mgcp", "reload", NULL },
mgcp_reload, "Reload MGCP configuration",
@@ -4305,6 +4282,12 @@ static int mgcp_do_reload(void)
static int mgcp_reload(int fd, int argc, char *argv[])
{
+ static int deprecated = 0;
+ if (!deprecated && argc > 0) {
+ ast_log(LOG_WARNING, "'mgcp reload' is deprecated. Please use 'reload chan_mgcp.so' instead.\n");
+ deprecated = 1;
+ }
+
ast_mutex_lock(&mgcp_reload_lock);
if (mgcp_reloading) {
ast_verbose("Previous mgcp reload not yet done\n");
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 99f9e87aa..3477d9d96 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -10757,18 +10757,9 @@ static int sip_notify(int fd, int argc, char *argv[])
}
/*! \brief Disable SIP Debugging in CLI */
-static int sip_no_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 3)
- return RESULT_SHOWUSAGE;
- ast_clear_flag(&global_flags[1], SIP_PAGE2_DEBUG_CONSOLE);
- ast_cli(fd, "SIP Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int sip_no_debug(int fd, int argc, char *argv[])
{
- if (argc != 2)
+ if (argc != 3)
return RESULT_SHOWUSAGE;
ast_clear_flag(&global_flags[1], SIP_PAGE2_DEBUG_CONSOLE);
ast_cli(fd, "SIP Debugging Disabled\n");
@@ -10787,19 +10778,9 @@ static int sip_do_history(int fd, int argc, char *argv[])
}
/*! \brief Disable SIP History logging (CLI) */
-static int sip_no_history_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 3) {
- return RESULT_SHOWUSAGE;
- }
- recordhistory = FALSE;
- ast_cli(fd, "SIP History Recording Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int sip_no_history(int fd, int argc, char *argv[])
{
- if (argc != 2) {
+ if (argc != 3) {
return RESULT_SHOWUSAGE;
}
recordhistory = FALSE;
@@ -10995,7 +10976,7 @@ static int build_reply_digest(struct sip_pvt *p, int method, char* digest, int d
}
static char show_domains_usage[] =
-"Usage: sip list domains\n"
+"Usage: sip show domains\n"
" Lists all configured SIP local domains.\n"
" Asterisk only responds to SIP messages to local domains.\n";
@@ -11005,7 +10986,7 @@ static char notify_usage[] =
" Message types are defined in sip_notify.conf\n";
static char show_users_usage[] =
-"Usage: sip list users [like <pattern>]\n"
+"Usage: sip show users [like <pattern>]\n"
" Lists all known SIP users.\n"
" Optional regular expression pattern is used to filter the user list.\n";
@@ -11015,12 +10996,12 @@ static char show_user_usage[] =
" Option \"load\" forces lookup of peer in realtime storage.\n";
static char show_inuse_usage[] =
-"Usage: sip list inuse [all]\n"
+"Usage: sip show inuse [all]\n"
" List all SIP users and peers usage counters and limits.\n"
" Add option \"all\" to show all devices, not only those with a limit.\n";
static char show_channels_usage[] =
-"Usage: sip list channels\n"
+"Usage: sip show channels\n"
" Lists all currently active SIP channels.\n";
static char show_channel_usage[] =
@@ -11032,7 +11013,7 @@ static char show_history_usage[] =
" Provides detailed dialog history on a given SIP channel.\n";
static char show_peers_usage[] =
-"Usage: sip list peers [like <pattern>]\n"
+"Usage: sip show peers [like <pattern>]\n"
" Lists all known SIP peers.\n"
" Optional regular expression pattern is used to filter the peer list.\n";
@@ -11047,7 +11028,7 @@ static char prune_realtime_usage[] =
" Optional regular expression pattern is used to filter the objects.\n";
static char show_reg_usage[] =
-"Usage: sip list registry\n"
+"Usage: sip show registry\n"
" Lists all registration requests and status.\n";
static char debug_usage[] =
@@ -11060,11 +11041,11 @@ static char debug_usage[] =
" Require peer to be registered.\n";
static char no_debug_usage[] =
-"Usage: sip nodebug\n"
+"Usage: sip debug off\n"
" Disables dumping of SIP packets for debugging purposes\n";
static char no_history_usage[] =
-"Usage: sip nohistory\n"
+"Usage: sip history off\n"
" Disables recording of SIP dialog history for debugging purposes\n";
static char history_usage[] =
@@ -11074,18 +11055,19 @@ static char history_usage[] =
static char sip_reload_usage[] =
"Usage: sip reload\n"
-" Reloads SIP configuration from sip.conf\n";
+" Reloads SIP configuration from sip.conf\n"
+" Deprecated: please use 'reload chan_sip.so'\n";
static char show_subscriptions_usage[] =
-"Usage: sip list subscriptions\n"
+"Usage: sip show subscriptions\n"
" Lists active SIP subscriptions for extension states\n";
static char show_objects_usage[] =
-"Usage: sip list objects\n"
+"Usage: sip show objects\n"
" Lists status of known SIP objects\n";
static char show_settings_usage[] =
-"Usage: sip list settings\n"
+"Usage: sip show settings\n"
" Provides detailed list of the configuration of the SIP channel.\n";
/*! \brief Read SIP header (dialplan function) */
@@ -16799,6 +16781,11 @@ static int sip_do_reload(enum channelreloadreason reason)
/*! \brief Force reload of module from cli */
static int sip_reload(int fd, int argc, char *argv[])
{
+ static int deprecated = 0;
+ if (!deprecated && argc > 0) {
+ ast_log(LOG_WARNING, "\"sip reload\" is deprecated. Please use 'reload chan_sip.so' instead.\n");
+ deprecated = 1;
+ }
ast_mutex_lock(&sip_reload_lock);
if (sip_reloading)
@@ -16822,92 +16809,42 @@ static int reload(void)
return sip_reload(0, 0, NULL);
}
-static struct ast_cli_entry cli_sip_no_history_deprecated = {
- { "sip", "no", "history", NULL },
- sip_no_history_deprecated, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_no_debug_deprecated = {
- { "sip", "no", "debug", NULL },
- sip_no_debug_deprecated, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_objects_deprecated = {
- { "sip", "show", "objects", NULL },
- sip_show_objects, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_users_deprecated = {
- { "sip", "show", "users", NULL },
- sip_show_users, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_subscriptions_deprecated = {
- { "sip", "show", "subscriptions", NULL },
- sip_show_subscriptions, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_channels_deprecated = {
- { "sip", "show", "channels", NULL },
- sip_show_channels, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_domains_deprecated = {
- { "sip", "show", "domains", NULL },
- sip_show_domains, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_peers_deprecated = {
- { "sip", "show", "peers", NULL },
- sip_show_peers, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_inuse_deprecated = {
- { "sip", "show", "inuse", NULL },
- sip_show_inuse, NULL,
- NULL };
-
-static struct ast_cli_entry cli_sip_show_registry_deprecated = {
- { "sip", "show", "registry", NULL },
- sip_show_registry, NULL,
- NULL };
-
static struct ast_cli_entry cli_sip[] = {
- { { "sip", "list", "channels", NULL },
+ { { "sip", "show", "channels", NULL },
sip_show_channels, "List active SIP channels",
- show_channels_usage, NULL, &cli_sip_show_channels_deprecated },
+ show_channels_usage },
- { { "sip", "list", "domains", NULL },
+ { { "sip", "show", "domains", NULL },
sip_show_domains, "List our local SIP domains.",
- show_domains_usage, NULL, &cli_sip_show_domains_deprecated },
+ show_domains_usage },
- { { "sip", "list", "inuse", NULL },
+ { { "sip", "show", "inuse", NULL },
sip_show_inuse, "List all inuse/limits",
- show_inuse_usage, NULL, &cli_sip_show_inuse_deprecated },
+ show_inuse_usage },
- { { "sip", "list", "objects", NULL },
+ { { "sip", "show", "objects", NULL },
sip_show_objects, "List all SIP object allocations",
- show_objects_usage, NULL, &cli_sip_show_objects_deprecated },
+ show_objects_usage },
- { { "sip", "list", "peers", NULL },
+ { { "sip", "show", "peers", NULL },
sip_show_peers, "List defined SIP peers",
- show_peers_usage, NULL, &cli_sip_show_peers_deprecated },
+ show_peers_usage },
- { { "sip", "list", "registry", NULL },
+ { { "sip", "show", "registry", NULL },
sip_show_registry, "List SIP registration status",
- show_reg_usage, NULL, &cli_sip_show_registry_deprecated },
+ show_reg_usage },
{ { "sip", "show", "settings", NULL },
sip_show_settings, "Show SIP global settings",
- show_settings_usage, NULL, NULL},
+ show_settings_usage },
- { { "sip", "list", "subscriptions", NULL },
+ { { "sip", "show", "subscriptions", NULL },
sip_show_subscriptions, "List active SIP subscriptions",
- show_subscriptions_usage, NULL, &cli_sip_show_subscriptions_deprecated },
+ show_subscriptions_usage },
- { { "sip", "list", "users", NULL },
+ { { "sip", "show", "users", NULL },
sip_show_users, "List defined SIP users",
- show_users_usage, NULL, &cli_sip_show_users_deprecated },
+ show_users_usage },
{ { "sip", "notify", NULL },
sip_notify, "Send a notify packet to a SIP peer",
@@ -16953,17 +16890,17 @@ static struct ast_cli_entry cli_sip[] = {
sip_do_debug, "Enable SIP debugging on Peername",
debug_usage, complete_sip_debug_peer },
- { { "sip", "nodebug", NULL },
+ { { "sip", "debug", "off", NULL },
sip_no_debug, "Disable SIP debugging",
- no_debug_usage, NULL, &cli_sip_no_debug_deprecated },
+ no_debug_usage },
{ { "sip", "history", NULL },
sip_do_history, "Enable SIP history",
history_usage },
- { { "sip", "nohistory", NULL },
+ { { "sip", "history", "off", NULL },
sip_no_history, "Disable SIP history",
- no_history_usage, NULL, &cli_sip_no_history_deprecated },
+ no_history_usage },
{ { "sip", "reload", NULL },
sip_reload, "Reload SIP configuration",
diff --git a/channels/chan_skinny.c b/channels/chan_skinny.c
index ae32ebf7b..f4890e18a 100644
--- a/channels/chan_skinny.c
+++ b/channels/chan_skinny.c
@@ -1758,19 +1758,9 @@ static int skinny_do_debug(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int skinny_no_debug_deprecated(int fd, int argc, char *argv[])
-{
- if (argc != 3) {
- return RESULT_SHOWUSAGE;
- }
- skinnydebug = 0;
- ast_cli(fd, "Skinny Debugging Disabled\n");
- return RESULT_SUCCESS;
-}
-
static int skinny_no_debug(int fd, int argc, char *argv[])
{
- if (argc != 2) {
+ if (argc != 3) {
return RESULT_SHOWUSAGE;
}
skinnydebug = 0;
@@ -1959,11 +1949,11 @@ static int skinny_show_lines(int fd, int argc, char *argv[])
}
static char show_devices_usage[] =
-"Usage: skinny list devices\n"
+"Usage: skinny show devices\n"
" Lists all devices known to the Skinny subsystem.\n";
static char show_lines_usage[] =
-"Usage: skinny list lines\n"
+"Usage: skinny show lines\n"
" Lists all lines known to the Skinny subsystem.\n";
static char debug_usage[] =
@@ -1971,44 +1961,29 @@ static char debug_usage[] =
" Enables dumping of Skinny packets for debugging purposes\n";
static char no_debug_usage[] =
-"Usage: skinny nodebug\n"
+"Usage: skinny no debug\n"
" Disables dumping of Skinny packets for debugging purposes\n";
static char reset_usage[] =
"Usage: skinny reset <DeviceId|all> [restart]\n"
" Causes a Skinny device to reset itself, optionally with a full restart\n";
-static struct ast_cli_entry cli_skinny_show_devices_deprecated = {
- { "skinny", "show", "devices", NULL },
- skinny_show_devices, NULL,
- NULL };
-
-static struct ast_cli_entry cli_skinny_show_lines_deprecated = {
- { "skinny", "show", "lines", NULL },
- skinny_show_lines, NULL,
- NULL };
-
-static struct ast_cli_entry cli_skinny_no_debug_deprecated = {
- { "skinny", "no", "debug", NULL },
- skinny_no_debug_deprecated, NULL,
- NULL };
-
static struct ast_cli_entry cli_skinny[] = {
- { { "skinny", "list", "devices", NULL },
+ { { "skinny", "show", "devices", NULL },
skinny_show_devices, "List defined Skinny devices",
- show_devices_usage, NULL, &cli_skinny_show_devices_deprecated },
+ show_devices_usage },
- { { "skinny", "list", "lines", NULL },
+ { { "skinny", "show", "lines", NULL },
skinny_show_lines, "List defined Skinny lines per device",
- show_lines_usage, NULL, &cli_skinny_show_lines_deprecated },
+ show_lines_usage },
{ { "skinny", "debug", NULL },
skinny_do_debug, "Enable Skinny debugging",
debug_usage },
- { { "skinny", "nodebug", NULL },
+ { { "skinny", "no", "debug", NULL },
skinny_no_debug, "Disable Skinny debugging",
- no_debug_usage, NULL, &cli_skinny_no_debug_deprecated },
+ no_debug_usage },
{ { "skinny", "reset", NULL },
skinny_reset_device, "Reset Skinny device(s)",
diff --git a/main/asterisk.c b/main/asterisk.c
index a59b48689..22ee7e9ab 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -139,10 +139,10 @@ int daemon(int, int); /* defined in libresolv of all places */
#define WELCOME_MESSAGE \
ast_verbose("Asterisk " ASTERISK_VERSION ", Copyright (C) 1999 - 2006 Digium, Inc. and others.\n"); \
ast_verbose("Created by Mark Spencer <markster@digium.com>\n"); \
- ast_verbose("Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for details.\n"); \
+ ast_verbose("Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core show warranty' for details.\n"); \
ast_verbose("This is free software, with components licensed under the GNU General Public\n"); \
ast_verbose("License version 2 and other licenses; you are welcome to redistribute it under\n"); \
- ast_verbose("certain conditions. Type 'show license' for details.\n"); \
+ ast_verbose("certain conditions. Type 'core show license' for details.\n"); \
ast_verbose("=========================================================================\n")
/*! \defgroup main_options Main Configuration Options
@@ -291,7 +291,7 @@ struct thread_list_t {
static AST_LIST_HEAD_STATIC(thread_list, thread_list_t);
static char show_threads_help[] =
-"Usage: show threads\n"
+"Usage: core show threads\n"
" List threads currently active in the system.\n";
void ast_register_thread(char *name)
@@ -531,7 +531,7 @@ static int handle_show_profile(int fd, int argc, char *argv[])
}
static char show_version_files_help[] =
-"Usage: file list version [like <pattern>]\n"
+"Usage: core show file version [like <pattern>]\n"
" Lists the revision numbers of the files used to build this copy of Asterisk.\n"
" Optional regular expression pattern is used to filter the file list.\n";
@@ -1359,15 +1359,15 @@ static char bang_help[] =
" Executes a given shell command\n";
static char show_warranty_help[] =
-"Usage: show warranty\n"
+"Usage: core show warranty\n"
" Shows the warranty (if any) for this copy of Asterisk.\n";
static char show_license_help[] =
-"Usage: show license\n"
+"Usage: core show license\n"
" Shows the license(s) for this copy of Asterisk.\n";
static char version_help[] =
-"Usage: show version\n"
+"Usage: core show version\n"
" Shows Asterisk version information.\n";
static int handle_version(int fd, int argc, char *argv[])
@@ -1566,15 +1566,15 @@ static struct ast_cli_entry cli_asterisk[] = {
handle_restart_when_convenient, "Restart Asterisk at empty call volume",
restart_when_convenient_help },
- { { "show", "warranty", NULL },
+ { { "core", "show", "warranty", NULL },
show_warranty, "Show the warranty (if any) for this copy of Asterisk",
show_warranty_help },
- { { "show", "license", NULL },
+ { { "core", "show", "license", NULL },
show_license, "Show the license(s) for this copy of Asterisk",
show_license_help },
- { { "show", "version", NULL },
+ { { "core", "show", "version", NULL },
handle_version, "Display version info",
version_help },
@@ -1583,19 +1583,19 @@ static struct ast_cli_entry cli_asterisk[] = {
bang_help },
#if !defined(LOW_MEMORY)
- { { "file", "list", "version", NULL },
+ { { "core", "show", "file", "version", NULL },
handle_show_version_files, "List versions of files used to build Asterisk",
show_version_files_help, complete_show_version_files, &cli_show_version_files_deprecated },
- { { "show", "threads", NULL },
+ { { "core", "show", "threads", NULL },
handle_show_threads, "Show running threads",
show_threads_help },
- { { "profile", "list", NULL },
+ { { "core", "show", "profile", NULL },
handle_show_profile, "Display profiling info",
NULL, NULL, &cli_show_profile_deprecated },
- { { "profile", "clear", NULL },
+ { { "core", "clear", "profile", NULL },
handle_show_profile, "Clear profiling info",
NULL, NULL, &cli_clear_profile_deprecated },
#endif /* ! LOW_MEMORY */
diff --git a/main/channel.c b/main/channel.c
index 4c6b630e4..992a6a539 100644
--- a/main/channel.c
+++ b/main/channel.c
@@ -289,11 +289,11 @@ static char *complete_channeltypes(const char *line, const char *word, int pos,
}
static char show_channeltypes_usage[] =
-"Usage: channeltype list\n"
+"Usage: core show channeltypes\n"
" Lists available channel types registered in your Asterisk server.\n";
static char show_channeltype_usage[] =
-"Usage: channeltype show <name>\n"
+"Usage: core show channeltype <name>\n"
" Show details about the specified channel type, <name>.\n";
static struct ast_cli_entry cli_show_channeltypes_deprecated = {
@@ -307,11 +307,11 @@ static struct ast_cli_entry cli_show_channeltype_deprecated = {
NULL, complete_channeltypes };
static struct ast_cli_entry cli_channel[] = {
- { { "channeltype", "list", NULL },
+ { { "core", "show", "channeltypes", NULL },
show_channeltypes, "List available channel types",
show_channeltypes_usage, NULL, &cli_show_channeltypes_deprecated },
- { { "channeltype", "show", NULL },
+ { { "core", "show", "channeltype", NULL },
show_channeltype, "Give more details on that channel type",
show_channeltype_usage, complete_channeltypes, &cli_show_channeltype_deprecated },
};
diff --git a/main/cli.c b/main/cli.c
index 5e2d2e180..cfd8ccce9 100644
--- a/main/cli.c
+++ b/main/cli.c
@@ -76,11 +76,11 @@ void ast_cli(int fd, char *fmt, ...)
static AST_LIST_HEAD_STATIC(helpers, ast_cli_entry);
static char load_help[] =
-"Usage: module load <module name>\n"
+"Usage: load <module name>\n"
" Loads the specified module into Asterisk.\n";
static char unload_help[] =
-"Usage: module unload [-f|-h] <module name>\n"
+"Usage: unload [-f|-h] <module name>\n"
" Unloads the specified module from Asterisk. The -f\n"
" option causes the module to be unloaded even if it is\n"
" in use (may cause a crash) and the -h module causes the\n"
@@ -94,32 +94,32 @@ static char help_help[] =
" topic, it provides a list of commands.\n";
static char chanlist_help[] =
-"Usage: channel list [concise|verbose]\n"
+"Usage: core show channels [concise|verbose]\n"
" Lists currently defined channels and some information about them. If\n"
" 'concise' is specified, the format is abridged and in a more easily\n"
" machine parsable format. If 'verbose' is specified, the output includes\n"
" more and longer fields.\n";
static char reload_help[] =
-"Usage: module reload [module ...]\n"
+"Usage: reload [module ...]\n"
" Reloads configuration files for all listed modules which support\n"
" reloading, or for all supported modules if none are listed.\n";
static char verbose_help[] =
-"Usage: core verbose <level>\n"
+"Usage: core set verbose <level>\n"
" Sets level of verbose messages to be displayed. 0 means\n"
" no messages should be displayed. Equivalent to -v[v[v...]]\n"
" on startup\n";
static char debug_help[] =
-"Usage: core debug <level> [filename]\n"
+"Usage: core set debug <level> [filename]\n"
" Sets level of core debug messages to be displayed. 0 means\n"
" no messages should be displayed. Equivalent to -d[d[d...]]\n"
" on startup. If filename is specified, debugging will be\n"
" limited to just that file.\n";
static char nodebug_help[] =
-"Usage: core nodebug\n"
+"Usage: core set no debug\n"
" Turns off core debug messages.\n";
static char logger_mute_help[] =
@@ -133,12 +133,12 @@ static char softhangup_help[] =
" the next time the driver reads or writes from the channel\n";
static char group_show_channels_help[] =
-"Usage: group list channels [pattern]\n"
+"Usage: group show channels [pattern]\n"
" Lists all currently active channels with channel group(s) specified.\n"
" Optional regular expression pattern is matched to group names for each\n"
" channel.\n";
-static int handle_load_deprecated(int fd, int argc, char *argv[])
+static int handle_load(int fd, int argc, char *argv[])
{
if (argc != 2)
return RESULT_SHOWUSAGE;
@@ -149,18 +149,7 @@ static int handle_load_deprecated(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int handle_load(int fd, int argc, char *argv[])
-{
- if (argc != 3)
- return RESULT_SHOWUSAGE;
- if (ast_load_resource(argv[2])) {
- ast_cli(fd, "Unable to load module %s\n", argv[2]);
- return RESULT_FAILURE;
- }
- return RESULT_SUCCESS;
-}
-
-static int handle_reload_deprecated(int fd, int argc, char *argv[])
+static int handle_reload(int fd, int argc, char *argv[])
{
int x;
int res;
@@ -183,29 +172,6 @@ static int handle_reload_deprecated(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int handle_reload(int fd, int argc, char *argv[])
-{
- int x;
- int res;
- if (argc < 2)
- return RESULT_SHOWUSAGE;
- if (argc > 2) {
- for (x=2;x<argc;x++) {
- res = ast_module_reload(argv[x]);
- switch(res) {
- case 0:
- ast_cli(fd, "No such module '%s'\n", argv[x]);
- break;
- case 1:
- ast_cli(fd, "Module '%s' does not support reload\n", argv[x]);
- break;
- }
- }
- } else
- ast_module_reload(NULL);
- return RESULT_SUCCESS;
-}
-
static int handle_set_verbose_deprecated(int fd, int argc, char *argv[])
{
int val = 0;
@@ -403,7 +369,7 @@ static int handle_logger_mute(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int handle_unload_deprecated(int fd, int argc, char *argv[])
+static int handle_unload(int fd, int argc, char *argv[])
{
int x;
int force=AST_FORCE_SOFT;
@@ -431,34 +397,6 @@ static int handle_unload_deprecated(int fd, int argc, char *argv[])
return RESULT_SUCCESS;
}
-static int handle_unload(int fd, int argc, char *argv[])
-{
- int x;
- int force=AST_FORCE_SOFT;
- if (argc < 3)
- return RESULT_SHOWUSAGE;
- for (x=2;x<argc;x++) {
- if (argv[x][0] == '-') {
- switch(argv[x][1]) {
- case 'f':
- force = AST_FORCE_FIRM;
- break;
- case 'h':
- force = AST_FORCE_HARD;
- break;
- default:
- return RESULT_SHOWUSAGE;
- }
- } else if (x != argc - 1)
- return RESULT_SHOWUSAGE;
- else if (ast_unload_resource(argv[x], force)) {
- ast_cli(fd, "Unable to unload resource %s\n", argv[x]);
- return RESULT_FAILURE;
- }
- }
- return RESULT_SUCCESS;
-}
-
#define MODLIST_FORMAT "%-30s %-40.40s %-10d\n"
#define MODLIST_FORMAT2 "%-30s %-40.40s %-10s\n"
@@ -476,11 +414,11 @@ static int modlist_modentry(const char *module, const char *description, int use
}
static char modlist_help[] =
-"Usage: module list [like keyword]\n"
+"Usage: core show modules [like keyword]\n"
" Shows Asterisk modules currently in use, and usage statistics.\n";
static char uptime_help[] =
-"Usage: show uptime [seconds]\n"
+"Usage: core show uptime [seconds]\n"
" Shows Asterisk uptime information.\n"
" The seconds word returns the uptime in seconds only.\n";
@@ -1018,16 +956,6 @@ static char *complete_ch_4(const char *line, const char *word, int pos, int stat
return ast_complete_channels(line, word, pos, state, 3);
}
-static char *complete_mod_2_nr(const char *line, const char *word, int pos, int state)
-{
- return ast_module_helper(line, word, pos, state, 1, 0);
-}
-
-static char *complete_mod_2(const char *line, const char *word, int pos, int state)
-{
- return ast_module_helper(line, word, pos, state, 1, 1);
-}
-
static char *complete_mod_3_nr(const char *line, const char *word, int pos, int state)
{
return ast_module_helper(line, word, pos, state, 2, 0);
@@ -1043,33 +971,12 @@ static char *complete_mod_4(const char *line, const char *word, int pos, int sta
return ast_module_helper(line, word, pos, state, 3, 0);
}
-static char *complete_fn_deprecated(const char *line, const char *word, int pos, int state)
-{
- char *c;
- char filename[256];
-
- if (pos != 1)
- return NULL;
-
- if (word[0] == '/')
- ast_copy_string(filename, word, sizeof(filename));
- else
- snprintf(filename, sizeof(filename), "%s/%s", ast_config_AST_MODULE_DIR, word);
-
- c = filename_completion_function(filename, state);
-
- if (c && word[0] != '/')
- c += (strlen(ast_config_AST_MODULE_DIR) + 1);
-
- return c ? strdup(c) : c;
-}
-
static char *complete_fn(const char *line, const char *word, int pos, int state)
{
char *c;
char filename[256];
- if (pos != 2)
+ if (pos != 1)
return NULL;
if (word[0] == '/')
@@ -1179,26 +1086,11 @@ static struct ast_cli_entry cli_debug_level_deprecated = {
handle_debuglevel_deprecated, NULL,
NULL };
-static struct ast_cli_entry cli_group_show_channels_deprecated = {
- { "group", "show", "channels", NULL },
- group_show_channels, NULL,
- NULL };
-
-static struct ast_cli_entry cli_load_deprecated = {
- { "load", NULL },
- handle_load_deprecated, NULL,
- NULL, complete_fn_deprecated };
-
static struct ast_cli_entry cli_no_debug_channel_deprecated = {
{ "no", "debug", "channel", NULL },
handle_nodebugchan_deprecated, NULL,
NULL, complete_ch_4 };
-static struct ast_cli_entry cli_reload_deprecated = {
- { "reload", NULL },
- handle_reload_deprecated, NULL,
- NULL, complete_mod_2 };
-
static struct ast_cli_entry cli_set_debug_deprecated = {
{ "set", "debug", NULL },
handle_set_debug_deprecated, NULL,
@@ -1229,43 +1121,38 @@ static struct ast_cli_entry cli_show_modules_like_deprecated = {
handle_modlist, NULL,
NULL, complete_mod_4 };
-static struct ast_cli_entry cli_unload_deprecated = {
- { "unload", NULL },
- handle_unload_deprecated, NULL,
- NULL, complete_mod_2_nr };
-
static struct ast_cli_entry cli_cli[] = {
- { { "channel", "list", NULL },
+ { { "core", "show", "channels", NULL },
handle_chanlist, "Display information on channels",
chanlist_help, complete_show_channels, &cli_show_channels_deprecated },
- { { "channel", "show", NULL },
+ { { "core", "show" "channel", NULL },
handle_showchan, "Display information on a specific channel",
showchan_help, complete_ch_3, &cli_show_channel_deprecated },
- { { "channel", "debug", NULL },
+ { { "core", "debug", "channel", NULL },
handle_debugchan, "Enable debugging on a channel",
debugchan_help, complete_ch_3, &cli_debug_channel_deprecated },
- { { "channel", "nodebug", NULL },
+ { { "core", "no", "debug", "channel", NULL },
handle_nodebugchan, "Disable debugging on a channel",
nodebugchan_help, complete_ch_3, &cli_no_debug_channel_deprecated },
- { { "core", "debug", NULL },
+ { { "core", "set", "debug", NULL },
handle_debug, "Set level of debug chattiness",
debug_help, NULL, &cli_set_debug_deprecated },
- { { "core", "nodebug", NULL },
+ { { "core", "set", "no", "debug", NULL },
handle_nodebug, "Turns off debug chattiness",
nodebug_help },
- { { "core", "verbose", NULL },
+ { { "core", "set", "verbose", NULL },
handle_verbose, "Set level of verboseness",
verbose_help, NULL, &cli_set_verbose_deprecated },
- { { "group", "list", "channels", NULL },
+ { { "group", "show", "channels", NULL },
group_show_channels, "Display active channels with group(s)",
- group_show_channels_help, NULL, &cli_group_show_channels_deprecated },
+ group_show_channels_help },
{ { "help", NULL },
handle_help, "Display help list, or specific help on a command",
@@ -1275,27 +1162,27 @@ static struct ast_cli_entry cli_cli[] = {
handle_logger_mute, "Toggle logging output to a console",
logger_mute_help },
- { { "module", "list", NULL },
+ { { "core", "show", "modules", NULL },
handle_modlist, "List modules and info",
modlist_help, NULL, &cli_show_modules_deprecated },
- { { "module", "list", "like", NULL },
+ { { "core", "show", "modules", "like", NULL },
handle_modlist, "List modules and info",
modlist_help, complete_mod_4, &cli_show_modules_like_deprecated },
- { { "module", "load", NULL },
+ { { "load", NULL },
handle_load, "Load a module by name",
- load_help, complete_fn, &cli_load_deprecated },
+ load_help, complete_fn },
- { { "module", "reload", NULL },
+ { { "reload", NULL },
handle_reload, "Reload configuration",
- reload_help, complete_mod_3, &cli_reload_deprecated },
+ reload_help, complete_mod_3 },
- { { "module", "unload", NULL },
+ { { "unload", NULL },
handle_unload, "Unload a module by name",
- unload_help, complete_mod_3_nr, &cli_unload_deprecated },
+ unload_help, complete_mod_3_nr },
- { { "show", "uptime", NULL },
+ { { "core", "show", "uptime", NULL },
handle_showuptime, "Show uptime information",
uptime_help },
diff --git a/main/config.c b/main/config.c
index fdccbd749..ccbc0c330 100644
--- a/main/config.c
+++ b/main/config.c
@@ -1388,7 +1388,7 @@ static int config_command(int fd, int argc, char **argv)
}
static char show_config_help[] =
- "Usage: core list config mappings\n"
+ "Usage: core show config mappings\n"
" Shows the filenames to config engines.\n";
static struct ast_cli_entry cli_show_config_mappings_deprecated = {
@@ -1397,7 +1397,7 @@ static struct ast_cli_entry cli_show_config_mappings_deprecated = {
NULL };
static struct ast_cli_entry cli_config[] = {
- { { "core", "list", "config", "mappings", NULL },
+ { { "core", "show", "config", "mappings", NULL },
config_command, "Display config mappings (file names to config engines)",
show_config_help, NULL, &cli_show_config_mappings_deprecated },
};
diff --git a/main/file.c b/main/file.c
index 6eba7bb53..dc664e082 100644
--- a/main/file.c
+++ b/main/file.c
@@ -1154,7 +1154,7 @@ static int show_file_formats(int fd, int argc, char *argv[])
}
char show_file_formats_usage[] =
-"Usage: core list file formats\n"
+"Usage: core show file formats\n"
" Displays currently registered file formats (if any)\n";
struct ast_cli_entry cli_show_file_formats_deprecated = {
@@ -1163,7 +1163,7 @@ struct ast_cli_entry cli_show_file_formats_deprecated = {
NULL };
struct ast_cli_entry cli_file[] = {
- { { "file", "list", "formats" },
+ { { "core", "show", "file", "formats" },
show_file_formats, "Displays file formats",
show_file_formats_usage, NULL, &cli_show_file_formats_deprecated },
};
diff --git a/main/frame.c b/main/frame.c
index 9bb40cd17..46726c1db 100644
--- a/main/frame.c
+++ b/main/frame.c
@@ -685,7 +685,7 @@ static int show_codecs(int fd, int argc, char *argv[])
}
static char frame_show_codecs_usage[] =
-"Usage: core list codecs [audio|video|image]\n"
+"Usage: core show codecs [audio|video|image]\n"
" Displays codec mapping\n";
static int show_codec_n_deprecated(int fd, int argc, char *argv[])
@@ -991,19 +991,19 @@ static struct ast_cli_entry cli_show_frame_stats = {
#endif
static struct ast_cli_entry my_clis[] = {
- { { "core", "list", "codecs", NULL },
+ { { "core", "show", "codecs", NULL },
show_codecs, "Displays a list of codecs",
frame_show_codecs_usage, NULL, &cli_show_codecs },
- { { "core", "list", "codecs", "audio", NULL },
+ { { "core", "show", "audio", "codecs", NULL },
show_codecs, "Displays a list of audio codecs",
frame_show_codecs_usage, NULL, &cli_show_audio_codecs },
- { { "core", "list", "codecs", "video", NULL },
+ { { "core", "show", "video", "codecs", NULL },
show_codecs, "Displays a list of video codecs",
frame_show_codecs_usage, NULL, &cli_show_video_codecs },
- { { "core", "list", "codecs", "image", NULL },
+ { { "core", "show", "image", "codecs", NULL },
show_codecs, "Displays a list of image codecs",
frame_show_codecs_usage, NULL, &cli_show_image_codecs },
diff --git a/main/http.c b/main/http.c
index a60a27318..b778017ec 100644
--- a/main/http.c
+++ b/main/http.c
@@ -688,18 +688,13 @@ int ast_http_reload(void)
}
static char show_http_help[] =
-"Usage: http list status\n"
+"Usage: http show status\n"
" Lists status of internal HTTP engine\n";
-static struct ast_cli_entry cli_http_show_status_deprecated = {
- { "http", "show", "status", NULL },
- handle_show_http, NULL,
- NULL };
-
static struct ast_cli_entry cli_http[] = {
- { { "http", "list", "status", NULL },
+ { { "http", "show", "status", NULL },
handle_show_http, "Display HTTP server status",
- show_http_help, NULL, &cli_http_show_status_deprecated },
+ show_http_help },
};
int ast_http_init(void)
diff --git a/main/image.c b/main/image.c
index 3d282428c..644758495 100644
--- a/main/image.c
+++ b/main/image.c
@@ -212,9 +212,9 @@ struct ast_cli_entry cli_show_image_formats_deprecated = {
NULL };
struct ast_cli_entry cli_image[] = {
- { { "file", "list", "formats", "image" },
+ { { "core", "show", "image", "formats" },
show_image_formats, "Displays image formats",
- "Usage: file list formats image\n"
+ "Usage: core show image formats\n"
" displays currently registered image formats (if any)\n", NULL, &cli_show_image_formats_deprecated },
};
diff --git a/main/logger.c b/main/logger.c
index 12c37a83b..2eaa04a8f 100644
--- a/main/logger.c
+++ b/main/logger.c
@@ -554,18 +554,13 @@ static char logger_rotate_help[] =
" Rotates and Reopens the log files.\n";
static char logger_show_channels_help[] =
-"Usage: logger list channels\n"
+"Usage: logger show channels\n"
" List configured logger channels.\n";
-static struct ast_cli_entry cli_logger_show_channels_deprecated = {
- { "logger", "show", "channels", NULL },
- handle_logger_show_channels, NULL,
- NULL };
-
static struct ast_cli_entry cli_logger[] = {
- { { "logger", "list", "channels", NULL },
+ { { "logger", "show", "channels", NULL },
handle_logger_show_channels, "List configured log channels",
- logger_show_channels_help, NULL, &cli_logger_show_channels_deprecated },
+ logger_show_channels_help },
{ { "logger", "reload", NULL },
handle_logger_reload, "Reopens the log files",
diff --git a/main/manager.c b/main/manager.c
index c57f1dd70..308da06b0 100644
--- a/main/manager.c
+++ b/main/manager.c
@@ -579,21 +579,21 @@ static char showmancmd_help[] =
" Shows the detailed description for a specific Asterisk manager interface command.\n";
static char showmancmds_help[] =
-"Usage: manager list commands\n"
+"Usage: manager show commands\n"
" Prints a listing of all the available Asterisk manager interface commands.\n";
static char showmanconn_help[] =
-"Usage: manager list connected\n"
+"Usage: manager show connected\n"
" Prints a listing of the users that are currently connected to the\n"
"Asterisk manager interface.\n";
static char showmaneventq_help[] =
-"Usage: manager list eventq\n"
+"Usage: manager show eventq\n"
" Prints a listing of all events pending in the Asterisk manger\n"
"event queue.\n";
static char showmanagers_help[] =
-"Usage: manager list users\n"
+"Usage: manager show users\n"
" Prints a listing of all managers that are currently configured on that\n"
" system.\n";
@@ -626,19 +626,19 @@ static struct ast_cli_entry cli_manager[] = {
handle_showmancmd, "Show a manager interface command",
showmancmd_help, complete_show_mancmd, &cli_show_manager_command_deprecated },
- { { "manager", "list", "commands", NULL },
+ { { "manager", "show", "commands", NULL },
handle_showmancmds, "List manager interface commands",
showmancmds_help, NULL, &cli_show_manager_commands_deprecated },
- { { "manager", "list", "connected", NULL },
+ { { "manager", "show", "connected", NULL },
handle_showmanconn, "List connected manager interface users",
showmanconn_help, NULL, &cli_show_manager_connected_deprecated },
- { { "manager", "list", "eventq", NULL },
+ { { "manager", "show", "eventq", NULL },
handle_showmaneventq, "List manager interface queued events",
showmaneventq_help, NULL, &cli_show_manager_eventq_deprecated },
- { { "manager", "list", "users", NULL },
+ { { "manager", "show", "users", NULL },
handle_showmanagers, "List configured manager users",
showmanagers_help, NULL, NULL },
diff --git a/main/pbx.c b/main/pbx.c
index 0223b9188..2acf75888 100644
--- a/main/pbx.c
+++ b/main/pbx.c
@@ -2966,25 +2966,25 @@ void ast_unregister_switch(struct ast_switch *sw)
* Help for CLI commands ...
*/
static char show_applications_help[] =
-"Usage: core list applications [{like|describing} <text>]\n"
+"Usage: core show applications [{like|describing} <text>]\n"
" List applications which are currently available.\n"
" If 'like', <text> will be a substring of the app name\n"
" If 'describing', <text> will be a substring of the description\n";
static char show_functions_help[] =
-"Usage: core list functions [like <text>]\n"
+"Usage: core show functions [like <text>]\n"
" List builtin functions, optionally only those matching a given string\n";
static char show_switches_help[] =
-"Usage: core list switches\n"
+"Usage: core show switches\n"
" List registered switches\n";
static char show_hints_help[] =
-"Usage: core list hints\n"
+"Usage: core show hints\n"
" List registered hints\n";
static char show_globals_help[] =
-"Usage: core list globals\n"
+"Usage: core show globals\n"
" List current global dialplan variables and their values\n";
static char show_application_help[] =
@@ -2996,7 +2996,7 @@ static char show_function_help[] =
" Describe a particular dialplan function.\n";
static char show_dialplan_help[] =
-"Usage: dialplan show [exten@][context]\n"
+"Usage: core show dialplan [exten@][context]\n"
" Show dialplan\n";
static char set_global_help[] =
@@ -3731,23 +3731,23 @@ static struct ast_cli_entry cli_set_global_deprecated = {
NULL };
static struct ast_cli_entry pbx_cli[] = {
- { { "core", "list", "applications", NULL },
+ { { "core", "show", "applications", NULL },
handle_show_applications, "Shows registered dialplan applications",
show_applications_help, complete_show_applications, &cli_show_applications_deprecated },
- { { "core", "list", "functions", NULL },
+ { { "core", "show", "functions", NULL },
handle_show_functions, "Shows registered dialplan functions",
show_functions_help, NULL, &cli_show_functions_deprecated },
- { { "core", "list", "switches", NULL },
+ { { "core", "show", "switches", NULL },
handle_show_switches, "Show alternative switches",
show_switches_help, NULL, &cli_show_switches_deprecated },
- { { "core", "list", "hints", NULL },
+ { { "core", "show", "hints", NULL },
handle_show_hints, "Show dialplan hints",
show_hints_help, NULL, &cli_show_hints_deprecated },
- { { "core", "list", "globals", NULL },
+ { { "core", "show", "globals", NULL },
handle_show_globals, "Show global dialplan variables",
show_globals_help, NULL, &cli_show_globals_deprecated },
diff --git a/res/res_agi.c b/res/res_agi.c
index 4d9510f84..5a9a40c17 100644
--- a/res/res_agi.c
+++ b/res/res_agi.c
@@ -95,7 +95,7 @@ static char *descrip =
"variable to \"no\" before executing the AGI application.\n"
" Using 'EAGI' provides enhanced AGI, with incoming audio available out of band\n"
"on file descriptor 3\n\n"
-" Use the CLI command 'show agi' to list available agi commands\n"
+" Use the CLI command 'agi show' to list available agi commands\n"
" This application sets the following channel variable upon completion:\n"
" AGISTATUS The status of the attempt to the run the AGI script\n"
" text string, one of SUCCESS | FAILED | HANGUP\n";
@@ -2084,7 +2084,7 @@ static int deadagi_exec(struct ast_channel *chan, void *data)
}
static char showagi_help[] =
-"Usage: agi list [topic]\n"
+"Usage: agi show [topic]\n"
" When called with a topic as an argument, displays usage\n"
" information on the given command. If called without a\n"
" topic, it provides a list of AGI commands.\n";
@@ -2118,7 +2118,7 @@ static struct ast_cli_entry cli_agi[] = {
agi_no_debug, "Disable AGI debugging",
no_debug_usage, NULL, &cli_agi_no_debug_deprecated },
- { { "agi", "list", NULL },
+ { { "agi", "show", NULL },
handle_showagi, "List AGI commands or specific help",
showagi_help, NULL, &cli_show_agi_deprecated },
diff --git a/res/res_crypto.c b/res/res_crypto.c
index 586dd77cf..eea8356af 100644
--- a/res/res_crypto.c
+++ b/res/res_crypto.c
@@ -554,7 +554,7 @@ static int init_keys(int fd, int argc, char *argv[])
}
static char show_key_usage[] =
-"Usage: keys list\n"
+"Usage: keys show\n"
" Displays information about RSA keys known by Asterisk\n";
static char init_keys_usage[] =
@@ -572,7 +572,7 @@ static struct ast_cli_entry cli_init_keys_deprecated = {
NULL };
static struct ast_cli_entry cli_crypto[] = {
- { { "keys", "list", NULL },
+ { { "keys", "show", NULL },
show_keys, "Displays RSA key information",
show_key_usage, NULL, &cli_show_keys_deprecated },
diff --git a/res/res_features.c b/res/res_features.c
index b2cca3c15..86d12cefc 100644
--- a/res/res_features.c
+++ b/res/res_features.c
@@ -1927,7 +1927,7 @@ static struct ast_cli_entry cli_show_features_deprecated = {
NULL };
static struct ast_cli_entry cli_features[] = {
- { { "feature", "list", NULL },
+ { { "feature", "show", NULL },
handle_showfeatures, "Lists configured features",
showfeatures_help, NULL, &cli_show_features_deprecated },
diff --git a/res/res_indications.c b/res/res_indications.c
index 34ddf1e31..ed8a24b33 100644
--- a/res/res_indications.c
+++ b/res/res_indications.c
@@ -64,7 +64,7 @@ static char help_remove_indication[] =
" Remove the given indication from the country.\n";
static char help_show_indications[] =
-"Usage: indication list [<country> ...]\n"
+"Usage: indication show [<country> ...]\n"
" Display either a condensed for of all country/indications, or the\n"
" indications for the specified countries.\n";
@@ -359,7 +359,7 @@ static struct ast_cli_entry cli_indications[] = {
handle_remove_indication, "Remove the given indication from the country",
help_remove_indication, NULL },
- { { "indication", "list", NULL },
+ { { "indication", "show", NULL },
handle_show_indications, "Display a list of all countries/indications",
help_show_indications, NULL, &cli_show_indications_deprecated },
};
diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c
index 6da58427f..56e8a1d28 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -1206,11 +1206,11 @@ static struct ast_cli_entry cli_moh[] = {
moh_cli, "Music On Hold",
"Music On Hold" },
- { { "moh", "list", "classes"},
+ { { "moh", "show", "classes"},
moh_classes_show, "List MOH classes",
"Lists all MOH classes", NULL, &cli_moh_classes_show_deprecated },
- { { "moh", "list", "files"},
+ { { "moh", "show", "files"},
cli_files_show, "List MOH file-based classes",
"Lists all loaded file-based MOH classes and their files", NULL, &cli_moh_files_show_deprecated },
};
diff --git a/res/res_odbc.c b/res/res_odbc.c
index 444e4f4d5..036b02151 100644
--- a/res/res_odbc.c
+++ b/res/res_odbc.c
@@ -338,19 +338,14 @@ static int odbc_show_command(int fd, int argc, char **argv)
}
static char show_usage[] =
-"Usage: odbc list [<class>]\n"
+"Usage: odbc show [<class>]\n"
" List settings of a particular ODBC class.\n"
" or, if not specified, all classes.\n";
-static struct ast_cli_entry cli_odbc_show_deprecated = {
- { "odbc", "show", NULL },
- odbc_show_command, NULL,
- NULL };
-
static struct ast_cli_entry cli_odbc[] = {
- { { "odbc", "list", NULL },
+ { { "odbc", "show", NULL },
odbc_show_command, "List ODBC DSN(s)",
- show_usage, NULL, &cli_odbc_show_deprecated },
+ show_usage },
};
static int odbc_register_class(struct odbc_class *class, int connect)