Download mega.nz files from command line

Solution 1:

Megatools allow you to copy individual files as well as entire directory trees to and from the cloud. You can also perform streaming downloads for example to preview videos and audio files, without needing to download the entire file first. Megatools are robust and optimized for fast operation - as fast as Mega servers allow. This is quite fast. Memory requirements and CPU utilization are kept at minimum.

Megatools is provided in Ubuntu by the universe repository. You can install megatools in all currently supported versions of Ubuntu with the following command:

sudo apt install megatools