Arduino Yún list wifi in sketch

I know you can connect to wifi on a Yún using Luci or the web control panel. However, I was wondering if there is a way to list and connect to wifi from inside a sketch. There must be a command you could run (using Process) to do this?

http://forum.arduino.cc/index.php?topic=216850.msg1586874#msg1586874