Use Dialog to connect to and edit wireless/wired access points, rather than trying to mess with the command line of nmcli or have a window manager up to use nm-connection-editor or nm-applet.
Check the wiki for information on installation, use, and future potential.