cli: split 'general' into 'nmcli switch' and 'nmcli general' commands

They basically contain operations previously available via 'nmcli nm'.
'nmcli nm' is still kept for backward compatibility.

Usage:
nmcli switch  [all|networking|wifi|wwan|wimax [on/off]]
nmcli general [status|permissions]

Examples:
nmcli switch all         - show all switches
nmcli switch wifi off    - switch Wi-Fi off

nmcli g s    - show NM status
nmcli g p    - show NM permissions
This commit is contained in:
Jiří Klimeš
2012-12-10 19:11:04 +01:00
committed by Dan Williams
parent 7a8d654691
commit 2bafd7a707
3 changed files with 330 additions and 61 deletions

View File

@@ -14,7 +14,7 @@
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*
* (C) Copyright 2010 Red Hat, Inc.
* (C) Copyright 2010 - 2012 Red Hat, Inc.
*/
#ifndef NMC_NETWORK_MANAGER_H
@@ -22,6 +22,10 @@
#include "nmcli.h"
NMCResultCode do_general (NmCli *nmc, int argc, char **argv);
NMCResultCode do_switch (NmCli *nmc, int argc, char **argv);
/* Backward compatibility only */
NMCResultCode do_network_manager (NmCli *nmc, int argc, char **argv);
#endif /* NMC_NETWORK_MANAGER_H */