cli: rename 'iface' --> 'ifname' in all commands

This commit is contained in:
Jiří Klimeš
2013-04-18 14:54:01 +02:00
parent 5f523d8f4d
commit 3bf97fafe7
3 changed files with 68 additions and 69 deletions

View File

@@ -197,9 +197,9 @@ usage (void)
" show configured [[ id | uuid | path ] <ID>]\n\n" " show configured [[ id | uuid | path ] <ID>]\n\n"
" show active [[ id | uuid | path | apath ] <ID>]\n\n" " show active [[ id | uuid | path | apath ] <ID>]\n\n"
#if WITH_WIMAX #if WITH_WIMAX
" up [ id | uuid | path ] <ID> [iface <iface>] [ap <BSSID>] [nsp <name>] [--nowait] [--timeout <timeout>]\n\n" " up [ id | uuid | path ] <ID> [ifname <ifname>] [ap <BSSID>] [nsp <name>] [--nowait] [--timeout <timeout>]\n\n"
#else #else
" up [ id | uuid | path ] <ID> [iface <iface>] [ap <BSSID>] [--nowait] [--timeout <timeout>]\n\n" " up [ id | uuid | path ] <ID> [ifname <ifname>] [ap <BSSID>] [--nowait] [--timeout <timeout>]\n\n"
#endif #endif
" down [ id | uuid | path | apath ] <ID>\n\n" " down [ id | uuid | path | apath ] <ID>\n\n"
" delete [ id | uuid | path ] <ID>\n\n" " delete [ id | uuid | path ] <ID>\n\n"
@@ -1366,7 +1366,7 @@ do_connection_up (NmCli *nmc, int argc, char **argv)
NMConnection *connection = NULL; NMConnection *connection = NULL;
NMSettingConnection *s_con; NMSettingConnection *s_con;
const char *con_type; const char *con_type;
const char *iface = NULL; const char *ifname = NULL;
const char *ap = NULL; const char *ap = NULL;
const char *nsp = NULL; const char *nsp = NULL;
gboolean wait = TRUE; gboolean wait = TRUE;
@@ -1418,14 +1418,14 @@ do_connection_up (NmCli *nmc, int argc, char **argv)
next_arg (&argc, &argv); next_arg (&argc, &argv);
while (argc > 0) { while (argc > 0) {
if (strcmp (*argv, "iface") == 0) { if (strcmp (*argv, "ifname") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
iface = *argv; ifname = *argv;
} }
else if (strcmp (*argv, "ap") == 0) { else if (strcmp (*argv, "ap") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
@@ -1489,7 +1489,7 @@ do_connection_up (NmCli *nmc, int argc, char **argv)
|| nm_connection_is_type (connection, NM_SETTING_BRIDGE_SETTING_NAME)) || nm_connection_is_type (connection, NM_SETTING_BRIDGE_SETTING_NAME))
is_virtual = TRUE; is_virtual = TRUE;
device_found = find_device_for_connection (nmc, connection, iface, ap, nsp, &device, &spec_object, &error); device_found = find_device_for_connection (nmc, connection, ifname, ap, nsp, &device, &spec_object, &error);
/* Virtual connection may not have their interfaces created yet */ /* Virtual connection may not have their interfaces created yet */
if (!device_found && !is_virtual) { if (!device_found && !is_virtual) {
if (error) if (error)

View File

@@ -262,14 +262,14 @@ usage (void)
" COMMAND := { status | show | disconnect | wifi }\n\n" " COMMAND := { status | show | disconnect | wifi }\n\n"
#endif #endif
" status\n\n" " status\n\n"
" show [<iface>]\n\n" " show [<ifname>]\n\n"
" disconnect <iface> [--nowait] [--timeout <timeout>]\n\n" " disconnect <ifname> [--nowait] [--timeout <timeout>]\n\n"
" wifi [list [iface <iface>] [bssid <BSSID>]]\n\n" " wifi [list [ifname <ifname>] [bssid <BSSID>]]\n\n"
" wifi connect <(B)SSID> [password <password>] [wep-key-type key|phrase] [iface <iface>] [bssid <BSSID>] [name <name>]\n\n" " wifi connect <(B)SSID> [password <password>] [wep-key-type key|phrase] [ifname <ifname>] [bssid <BSSID>] [name <name>]\n\n"
" [--private] [--nowait] [--timeout <timeout>]\n\n" " [--private] [--nowait] [--timeout <timeout>]\n\n"
" wifi scan [[iface] <iface>]\n\n" " wifi scan [[ifname] <ifname>]\n\n"
#if WITH_WIMAX #if WITH_WIMAX
" wimax [list [iface <iface>] [nsp <name>]]\n\n" " wimax [list [ifname <ifname>] [nsp <name>]]\n\n"
#endif #endif
)); ));
} }
@@ -1032,11 +1032,11 @@ do_devices_show (NmCli *nmc, int argc, char **argv)
{ {
const GPtrArray *devices; const GPtrArray *devices;
NMDevice *device = NULL; NMDevice *device = NULL;
const char *iface = NULL; const char *ifname = NULL;
int i; int i;
if (argc == 1) if (argc == 1)
iface = *argv; ifname = *argv;
else if (argc > 1) { else if (argc > 1) {
g_string_printf (nmc->return_text, _("Error: invalid extra argument '%s'."), *(argv+1)); g_string_printf (nmc->return_text, _("Error: invalid extra argument '%s'."), *(argv+1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
@@ -1056,17 +1056,17 @@ do_devices_show (NmCli *nmc, int argc, char **argv)
devices = nm_client_get_devices (nmc->client); devices = nm_client_get_devices (nmc->client);
if (iface) { if (ifname) {
/* Interface specified; show details only for the device */ /* Interface specified; show details only for the device */
for (i = 0; devices && (i < devices->len); i++) { for (i = 0; devices && (i < devices->len); i++) {
NMDevice *candidate = g_ptr_array_index (devices, i); NMDevice *candidate = g_ptr_array_index (devices, i);
const char *dev_iface = nm_device_get_iface (candidate); const char *dev_iface = nm_device_get_iface (candidate);
if (!g_strcmp0 (dev_iface, iface)) if (!g_strcmp0 (dev_iface, ifname))
device = candidate; device = candidate;
} }
if (!device) { if (!device) {
g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }
@@ -1160,8 +1160,8 @@ do_device_disconnect (NmCli *nmc, int argc, char **argv)
{ {
const GPtrArray *devices; const GPtrArray *devices;
NMDevice *device = NULL; NMDevice *device = NULL;
const char *iface = NULL; const char *ifname = NULL;
char *iface_ask = NULL; char *ifname_ask = NULL;
gboolean wait = TRUE; gboolean wait = TRUE;
int i; int i;
@@ -1170,20 +1170,19 @@ do_device_disconnect (NmCli *nmc, int argc, char **argv)
if (argc == 0) { if (argc == 0) {
if (nmc->ask) { if (nmc->ask) {
iface_ask = nmc_get_user_input ("Interface: "); ifname = ifname_ask = nmc_get_user_input ("Interface: ");
iface = iface_ask;
// TODO: list available devices when just Enter is pressed ? // TODO: list available devices when just Enter is pressed ?
} }
if (!iface_ask) { if (!ifname_ask) {
g_string_printf (nmc->return_text, _("Error: No interface specified.")); g_string_printf (nmc->return_text, _("Error: No interface specified."));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
} else { } else {
iface = *argv; ifname = *argv;
} }
if (!iface) { if (!ifname) {
g_string_printf (nmc->return_text, _("Error: No interface specified.")); g_string_printf (nmc->return_text, _("Error: No interface specified."));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
@@ -1233,12 +1232,12 @@ do_device_disconnect (NmCli *nmc, int argc, char **argv)
NMDevice *candidate = g_ptr_array_index (devices, i); NMDevice *candidate = g_ptr_array_index (devices, i);
const char *dev_iface = nm_device_get_iface (candidate); const char *dev_iface = nm_device_get_iface (candidate);
if (!g_strcmp0 (dev_iface, iface)) if (!g_strcmp0 (dev_iface, ifname))
device = candidate; device = candidate;
} }
if (!device) { if (!device) {
g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }
@@ -1287,7 +1286,7 @@ do_device_wifi_list (NmCli *nmc, int argc, char **argv)
GError *error = NULL; GError *error = NULL;
NMDevice *device = NULL; NMDevice *device = NULL;
NMAccessPoint *ap = NULL; NMAccessPoint *ap = NULL;
const char *iface = NULL; const char *ifname = NULL;
const char *bssid_user = NULL; const char *bssid_user = NULL;
const GPtrArray *devices; const GPtrArray *devices;
const GPtrArray *aps; const GPtrArray *aps;
@@ -1301,13 +1300,13 @@ do_device_wifi_list (NmCli *nmc, int argc, char **argv)
guint32 escape_flag = nmc->escape_values ? NMC_PF_FLAG_ESCAPE : 0; guint32 escape_flag = nmc->escape_values ? NMC_PF_FLAG_ESCAPE : 0;
while (argc > 0) { while (argc > 0) {
if (strcmp (*argv, "iface") == 0) { if (strcmp (*argv, "ifname") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
iface = *argv; ifname = *argv;
} else if (strcmp (*argv, "bssid") == 0 || strcmp (*argv, "hwaddr") == 0) { } else if (strcmp (*argv, "bssid") == 0 || strcmp (*argv, "hwaddr") == 0) {
/* hwaddr is deprecated and will be removed later */ /* hwaddr is deprecated and will be removed later */
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
@@ -1362,20 +1361,20 @@ do_device_wifi_list (NmCli *nmc, int argc, char **argv)
nmc->print_fields.header_name = _("Wi-Fi scan list"); nmc->print_fields.header_name = _("Wi-Fi scan list");
devices = nm_client_get_devices (nmc->client); devices = nm_client_get_devices (nmc->client);
if (iface) { if (ifname) {
/* Device specified - list only APs of this interface */ /* Device specified - list only APs of this interface */
for (i = 0; devices && (i < devices->len); i++) { for (i = 0; devices && (i < devices->len); i++) {
NMDevice *candidate = g_ptr_array_index (devices, i); NMDevice *candidate = g_ptr_array_index (devices, i);
const char *dev_iface = nm_device_get_iface (candidate); const char *dev_iface = nm_device_get_iface (candidate);
if (!g_strcmp0 (dev_iface, iface)) { if (!g_strcmp0 (dev_iface, ifname)) {
device = candidate; device = candidate;
break; break;
} }
} }
if (!device) { if (!device) {
g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }
@@ -1412,7 +1411,7 @@ do_device_wifi_list (NmCli *nmc, int argc, char **argv)
show_acces_point_info (device, nmc); show_acces_point_info (device, nmc);
} }
} else { } else {
g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }
@@ -1641,7 +1640,7 @@ do_device_wifi_connect_network (NmCli *nmc, int argc, char **argv)
NMSettingWirelessSecurity *s_wsec; NMSettingWirelessSecurity *s_wsec;
AddAndActivateInfo *info; AddAndActivateInfo *info;
const char *param_user = NULL; const char *param_user = NULL;
const char *iface = NULL; const char *ifname = NULL;
const char *bssid = NULL; const char *bssid = NULL;
const char *password = NULL; const char *password = NULL;
const char *con_name = NULL; const char *con_name = NULL;
@@ -1680,13 +1679,13 @@ do_device_wifi_connect_network (NmCli *nmc, int argc, char **argv)
/* Get the rest of the parameters */ /* Get the rest of the parameters */
while (argc > 0) { while (argc > 0) {
if (strcmp (*argv, "iface") == 0) { if (strcmp (*argv, "ifname") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
iface = *argv; ifname = *argv;
} else if (strcmp (*argv, "bssid") == 0) { } else if (strcmp (*argv, "bssid") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
@@ -1786,11 +1785,11 @@ do_device_wifi_connect_network (NmCli *nmc, int argc, char **argv)
/* Find a device to activate the connection on */ /* Find a device to activate the connection on */
devices_idx = 0; devices_idx = 0;
device = find_wifi_device_by_iface (devices, iface, &devices_idx); device = find_wifi_device_by_iface (devices, ifname, &devices_idx);
if (!device) { if (!device) {
if (iface) if (ifname)
g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), ifname);
else else
g_string_printf (nmc->return_text, _("Error: No Wi-Fi device found.")); g_string_printf (nmc->return_text, _("Error: No Wi-Fi device found."));
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
@@ -1799,8 +1798,8 @@ do_device_wifi_connect_network (NmCli *nmc, int argc, char **argv)
/* Find an AP to connect to */ /* Find an AP to connect to */
ap = find_ap_on_device (device, bssid1_arr, bssid1_arr ? NULL : param_user); ap = find_ap_on_device (device, bssid1_arr, bssid1_arr ? NULL : param_user);
if (!ap && !iface) { if (!ap && !ifname) {
/* AP not found. iface was not specified, so try finding the AP on another device. */ /* AP not found. ifname was not specified, so try finding the AP on another device. */
while ((device = find_wifi_device_by_iface (devices, NULL, &devices_idx)) != NULL) { while ((device = find_wifi_device_by_iface (devices, NULL, &devices_idx)) != NULL) {
ap = find_ap_on_device (device, bssid1_arr, bssid1_arr ? NULL : param_user); ap = find_ap_on_device (device, bssid1_arr, bssid1_arr ? NULL : param_user);
if (ap) if (ap)
@@ -1926,7 +1925,7 @@ static NMCResultCode
do_device_wifi_scan (NmCli *nmc, int argc, char **argv) do_device_wifi_scan (NmCli *nmc, int argc, char **argv)
{ {
NMDevice *device; NMDevice *device;
const char *iface = NULL; const char *ifname = NULL;
const GPtrArray *devices; const GPtrArray *devices;
int devices_idx; int devices_idx;
@@ -1934,25 +1933,25 @@ do_device_wifi_scan (NmCli *nmc, int argc, char **argv)
/* Get the parameters */ /* Get the parameters */
if (argc > 0) { if (argc > 0) {
if (strcmp (*argv, "iface") == 0) { if (strcmp (*argv, "ifname") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
} }
iface = *argv; ifname = *argv;
} }
/* Find Wi-Fi device to scan on. When no iface is provided, the first Wi-Fi is used. */ /* Find Wi-Fi device to scan on. When no ifname is provided, the first Wi-Fi is used. */
nmc->get_client (nmc); nmc->get_client (nmc);
devices = nm_client_get_devices (nmc->client); devices = nm_client_get_devices (nmc->client);
devices_idx = 0; devices_idx = 0;
device = find_wifi_device_by_iface (devices, iface, &devices_idx); device = find_wifi_device_by_iface (devices, ifname, &devices_idx);
if (!device) { if (!device) {
if (iface) if (ifname)
g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' is not a Wi-Fi device."), ifname);
else else
g_string_printf (nmc->return_text, _("Error: No Wi-Fi device found.")); g_string_printf (nmc->return_text, _("Error: No Wi-Fi device found."));
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
@@ -2009,7 +2008,7 @@ do_device_wimax_list (NmCli *nmc, int argc, char **argv)
GError *error = NULL; GError *error = NULL;
NMDevice *device = NULL; NMDevice *device = NULL;
NMWimaxNsp *nsp = NULL; NMWimaxNsp *nsp = NULL;
const char *iface = NULL; const char *ifname = NULL;
const char *nsp_user = NULL; const char *nsp_user = NULL;
const GPtrArray *devices; const GPtrArray *devices;
const GPtrArray *nsps; const GPtrArray *nsps;
@@ -2022,13 +2021,13 @@ do_device_wimax_list (NmCli *nmc, int argc, char **argv)
guint32 escape_flag = nmc->escape_values ? NMC_PF_FLAG_ESCAPE : 0; guint32 escape_flag = nmc->escape_values ? NMC_PF_FLAG_ESCAPE : 0;
while (argc > 0) { while (argc > 0) {
if (strcmp (*argv, "iface") == 0) { if (strcmp (*argv, "ifname") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
nmc->return_value = NMC_RESULT_ERROR_USER_INPUT; nmc->return_value = NMC_RESULT_ERROR_USER_INPUT;
goto error; goto error;
} }
iface = *argv; ifname = *argv;
} else if (strcmp (*argv, "nsp") == 0) { } else if (strcmp (*argv, "nsp") == 0) {
if (next_arg (&argc, &argv) != 0) { if (next_arg (&argc, &argv) != 0) {
g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1)); g_string_printf (nmc->return_text, _("Error: %s argument is missing."), *(argv-1));
@@ -2081,20 +2080,20 @@ do_device_wimax_list (NmCli *nmc, int argc, char **argv)
nmc->print_fields.header_name = _("WiMAX NSP list"); nmc->print_fields.header_name = _("WiMAX NSP list");
devices = nm_client_get_devices (nmc->client); devices = nm_client_get_devices (nmc->client);
if (iface) { if (ifname) {
/* Device specified - list only NSPs of this interface */ /* Device specified - list only NSPs of this interface */
for (i = 0; devices && (i < devices->len); i++) { for (i = 0; devices && (i < devices->len); i++) {
NMDevice *candidate = g_ptr_array_index (devices, i); NMDevice *candidate = g_ptr_array_index (devices, i);
const char *dev_iface = nm_device_get_iface (candidate); const char *dev_iface = nm_device_get_iface (candidate);
if (!g_strcmp0 (dev_iface, iface)) { if (!g_strcmp0 (dev_iface, ifname)) {
device = candidate; device = candidate;
break; break;
} }
} }
if (!device) { if (!device) {
g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' not found."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }
@@ -2125,7 +2124,7 @@ do_device_wimax_list (NmCli *nmc, int argc, char **argv)
show_nsp_info (device, nmc); show_nsp_info (device, nmc);
} }
} else { } else {
g_string_printf (nmc->return_text, _("Error: Device '%s' is not a WiMAX device."), iface); g_string_printf (nmc->return_text, _("Error: Device '%s' is not a WiMAX device."), ifname);
nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; nmc->return_value = NMC_RESULT_ERROR_UNKNOWN;
goto error; goto error;
} }

View File

@@ -322,13 +322,13 @@ is 'nmcli connection show configured'.
No simple reference. No simple reference.
.fi .fi
.TP .TP
.B up [ id | uuid | path ] <ID> [iface <iface>] [ap <BSSID>] [nsp <name>] [--nowait] [--timeout <timeout>] .B up [ id | uuid | path ] <ID> [ifname <ifname>] [ap <BSSID>] [nsp <name>] [--nowait] [--timeout <timeout>]
.br .br
Activate a connection. The connection is identified by its name, UUID or D-Bus Activate a connection. The connection is identified by its name, UUID or D-Bus
path. If <ID> is ambiguous, a keyword \fIid\fP, \fIuuid\fP or \fIpath\fP can be path. If <ID> is ambiguous, a keyword \fIid\fP, \fIuuid\fP or \fIpath\fP can be
used. When requiring a particular device to activate the connection on, the used. When requiring a particular device to activate the connection on, the
\fIiface\fP option with interface name should be given. In case of a VPN \fIifname\fP option with interface name should be given. In case of a VPN
connection, the \fIiface\fP option specify the device of the base connection. connection, the \fIifname\fP option specify the device of the base connection.
The \fIap\fP option specify what particular AP should be used in case of The \fIap\fP option specify what particular AP should be used in case of
a Wi\(hyFi connection. a Wi\(hyFi connection.
.br .br
@@ -336,7 +336,7 @@ See \fBshow active\fP above for the description of the <ID>-specifying keywords.
.RS .RS
.PP .PP
Available options are: Available options are:
.IP \fIiface\fP 13 .IP \fIifname\fP 13
\(en interface that will be used for activation \(en interface that will be used for activation
.IP \fIap\fP 13 .IP \fIap\fP 13
\(en BSSID of the AP which the command should connect to (for Wi\(hyFi connections) \(en BSSID of the AP which the command should connect to (for Wi\(hyFi connections)
@@ -409,7 +409,7 @@ This is the default action if no command is specified to \fIdevice\fP object.
No simple reference. No simple reference.
.fi .fi
.TP .TP
.B show [<iface>] .B show [<ifname>]
.br .br
Show detailed information about devices. Without an argument, all devices are Show detailed information about devices. Without an argument, all devices are
examined. To get information for a specific device, the interface name has examined. To get information for a specific device, the interface name has
@@ -420,7 +420,7 @@ to be provided.
No simple reference. No simple reference.
.fi .fi
.TP .TP
.B disconnect <iface> [--nowait] [--timeout <timeout>] .B disconnect <ifname> [--nowait] [--timeout <timeout>]
.br .br
Disconnect a device and prevent the device from automatically activating further Disconnect a device and prevent the device from automatically activating further
connections without user/manual intervention. connections without user/manual intervention.
@@ -441,9 +441,9 @@ arguments: none
.fi .fi
.RE .RE
.TP .TP
.B wifi [list [iface <iface>] [bssid <BSSID>]] .B wifi [list [ifname <ifname>] [bssid <BSSID>]]
.br .br
List available Wi\(hyFi access points. The \fIiface\fP and \fIbssid\fP options List available Wi\(hyFi access points. The \fIifname\fP and \fIbssid\fP options
can be used to list APs for a particular interface or with a specific BSSID, can be used to list APs for a particular interface or with a specific BSSID,
respectively. respectively.
.br .br
@@ -452,7 +452,7 @@ respectively.
No simple reference. No simple reference.
.fi .fi
.TP .TP
.B wifi connect <(B)SSID> [password <password>] [wep\-key\-type key|phrase] [iface <iface>] [bssid <BSSID>] [name <name>] [\-\-private] [\-\-nowait] [\-\-timeout <timeout>] .B wifi connect <(B)SSID> [password <password>] [wep\-key\-type key|phrase] [ifname <ifname>] [bssid <BSSID>] [name <name>] [\-\-private] [\-\-nowait] [\-\-timeout <timeout>]
.br .br
Connect to a Wi\(hyFi network specified by SSID or BSSID. The command creates a new Connect to a Wi\(hyFi network specified by SSID or BSSID. The command creates a new
connection and then activates it on a device. This is a command\(hyline counterpart connection and then activates it on a device. This is a command\(hyline counterpart
@@ -469,7 +469,7 @@ Available options are:
\(en password for secured networks (WEP or WPA) \(en password for secured networks (WEP or WPA)
.IP \fIwep\-key\-type\fP 13 .IP \fIwep\-key\-type\fP 13
\(en type of WEP secret, either \fIkey\fP for ASCII/HEX key or \fIphrase\fP for passphrase \(en type of WEP secret, either \fIkey\fP for ASCII/HEX key or \fIphrase\fP for passphrase
.IP \fIiface\fP 13 .IP \fIifname\fP 13
\(en interface that will be used for activation \(en interface that will be used for activation
.IP \fIbssid\fP 13 .IP \fIbssid\fP 13
\(en if specified, the created connection will be restricted just for the BSSID \(en if specified, the created connection will be restricted just for the BSSID
@@ -491,16 +491,16 @@ arguments: according to arguments
.fi .fi
.RE .RE
.TP .TP
.B wifi scan [[iface] <iface>] .B wifi scan [[ifname] <ifname>]
.br .br
Request that \fINetworkManager\fP immediately scan for available access points. Request that \fINetworkManager\fP immediately scan for available access points.
NetworkManager scans Wi\(hyFi networks periodically, but in some cases it can be NetworkManager scans Wi\(hyFi networks periodically, but in some cases it can be
useful to start scanning manually (e.g. after resuming the computer). useful to start scanning manually (e.g. after resuming the computer).
This command doesn't show the APs, use 'nmcli device wifi list' for that. This command doesn't show the APs, use 'nmcli device wifi list' for that.
.TP .TP
.B wimax [list [iface <iface>] [nsp <name>]] .B wimax [list [ifname <ifname>] [nsp <name>]]
.br .br
List available WiMAX NSP. The \fIiface\fP and \fInsp\fP options List available WiMAX NSP. The \fIifname\fP and \fInsp\fP options
can be used to list networks for a particular interface or with a specific can be used to list networks for a particular interface or with a specific
NSP, respectively. NSP, respectively.
.br .br
@@ -613,7 +613,7 @@ shows all connections' names and their autoconnect settings.
.IP .IP
shows all details of the connection with "My wired connection" name. shows all details of the connection with "My wired connection" name.
.IP "\fB\f(CWnmcli \-p con up \(dq\&My wired connection\(dq\& iface eth0\fP\fP" .IP "\fB\f(CWnmcli \-p con up \(dq\&My wired connection\(dq\& ifname eth0\fP\fP"
.IP .IP
activates the connection with name "My wired connection" on interface eth0. activates the connection with name "My wired connection" on interface eth0.
The \-p option makes nmcli show progress of the activation. The \-p option makes nmcli show progress of the activation.