I bumped into this page: https://www.lede-project.org/docs/guide-quick-start/flashwithssh
And here is my attempt to explain how it works. Please verify, correct and add it to the wiki once it is good enough.
I now used the link to the LEDE snapshot, so once the first LEDE release is a fact then the link should probably point to that.
LEDE commandline firmware upgrade.
in this example i will use the GL.inet AR150 and do the firmware upgrade over SSH.
First i downloaded the firmware image.
In my case it sits in https://downloads.lede-project.org/snapshots/targets/ar71xx/generic/
And the file I need for the AR150 is named: lede-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin
You can use SSH, Putty, Minicom, HOTSSH, Cutecom, Screen or andy other means to get commandline acces to your device over SSH, or serial connection.
First of all connect to the device accordingly to the tool mentioned above. It would be cool to have a seperate manual for all the options. But for now I assume that you have at least one way to connect.
I also assume that the device is connected to the internet via WAN to be able to download the firmware directly from the website.
Once connected and having the command prompt on your terminal-screen you can upload the file to the /tmp folder on the AR150
cd /tmp wget http://downloads.lede-project.org/snapshots/targets/ar71xx/generic/lede-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin
once the file is has been downloaded you can flash the it to the ROM with the sysupgrade command as follows
sysupgrade -n -v lede-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin
The firmware will now be flashed to the device. Once the flashing completed the device will reboot.
And at this point you can reach the device at IP 192.168.1.1 Unless otherwise configured..
And you should be able to reach it with SSH:
Or via USB/serial by for instance using screen:
sudo screen /dev/ttyUSB3 115200
Keep in mind that this last one was done on a GNU/Linux machine, in my case on USB3 and a baudrate of 115200.
That should be it!
When you have the firmware file on your laptop you can also upload the file manually by commandline with the put command
put /Downloads/path_to_your_file/lede-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin /tmp/lede-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin
Once uploaded you can do the sysupgrade command as stated above. This option you may need when you are not having a working internet connection or have other reasons not to be connected to the net when doing this.