MEGACOPY(1)

πŸ“¦ version 1.10.3, in ubuntu jammy

πŸ’– MEGACOPY(1) β€” the Megatools Manual, bestie edition πŸ’–

okay so. you're looking at megacopy, from the Megatools Manual (section 1, we're fancy like that). and honestly? it's giving entire-directory energy. let's get into it. πŸ¦‹


✨ NAME ✨

megacopy β€” upload/download entire directories to/from your Mega.nz account. yes. entire directories. she does not do things by halves. πŸ’…


🌸 SYNOPSIS 🌸

megacopy [-n] [--no-progress] --local <path> --remote <remotepath>
megacopy [-n] [--no-progress] --download --local <path> --remote <remotepath>

like. look at her. two modes. pick one. slay. ✨


πŸŽ€ DESCRIPTION πŸŽ€

So what she actually does is sync remote and local directories. and here's the part that matters most, no cap:

No files are ever overwritten or removed. Ever. She's a respecter of boundaries. πŸ’–

The default direction is uploading files to the cloud β€” that's just her default mood. If you wanna go the other way and download files, you have to actually say so by adding the --download option. she's not a mind reader bestie. πŸ™ˆ


πŸ’… OPTIONS πŸ’…

  • -r <remotepath>, --remote <remotepath> β€” the remote directory path. where on Mega.nz we're hanging out. 🌈
  • -l <path>, --local <path> β€” the local directory path. your own little corner of your own little machine. πŸ“
  • -d, --download β€” download files from the Mega.nz. the default is to upload, so this is you switching it up. πŸ”₯
  • -n, --dryrun β€” don't perform any actual changes, just print what would be done. queen of thinking about it first. ✨
  • --no-progress β€” disable upload progress reporting. no little bars, no little percentages. just vibes. 😌
  • --enable-previews β€” generate and upload file previews, when uploading new files. this is the default, unless you changed it in the configuration file. use this to override the option from the configuration file. πŸ‘‘
  • --disable-previews β€” don't generate and upload file previews. default is to generate previews. so this is the "actually no πŸ’€" button.
  • --disable-resume β€” don't resume downloads from partially dowloaded file. default is to resume. (yes, the original says "dowloaded". we keep it. character-for-character, bestie, those are the rules. πŸ’€)
  • -u <email>, --username <email> β€” account username (email). 🫢
  • -p <password>, --password <password> β€” account password. shhh. 🀫
  • --no-ask-password β€” never ask interactively for a password. she will simply not be asking. πŸ™…
  • --reload β€” reload filesystem cache. fresh eyes. new day. 🧚
  • --limit-speed <speed> β€” set maximum allowed upload and download speed in KiB/s. this option overrides config file settings. 0 means no limit. when using ParallelTransfers > 1, upload speed limit is applied to each transfer individually. so like, per-transfer. important!! πŸ’œ
  • --proxy <proxy> β€” use proxy server to connect to mega.nz. this option overrides config file settings. more information can be found in libcurl documentation at https://curl.haxx.se/libcurl/c/CURLOPT_PROXY.html. some acceptable values are:
    • none : Disable proxy if it was enabled in the config file.
    • socks5://localhost:9050 : Local SOCKSv5 proxy server
    • socks5h://localhost:9050 : Local SOCKSv5 proxy server with DNS handled by the proxy
  • --config <path> β€” load configuration from a file. 🌸
  • --ignore-config-file β€” disable loading .megarc. she's ignoring her own homework file. iconic. πŸ’…
  • --debug [<options>] β€” enable debugging of various aspects of the megatools operation. you may enable multiple debugging options separated by commas. (eg. --debug api,fs)
    • available options are:
      • http: Dump HTTP request/response details (can be used to debug connection/proxy issues)
      • api: Dump Mega.nz API calls
      • fs: Dump Mega.nz filesystem (may require --reload to actually print something)
      • cache: Dump cache contents
      • tman: Dump transfer manager events
  • --version β€” show version information. πŸ’–

⭐ EXAMPLES ⭐

  • Upload directory. going up! ☁️
$ megacopy --local MyBackups --remote /Root/Backups
  • Download directory. coming back down to earth. 🌍
$ megacopy --local MyBackups --remote /Root/Backups --download

🌳 REMOTE FILESYSTEM 🌳

okay this section is the lore. sit down. 🍿

The Mega.nz filesystem is represented as a tree of nodes of various types. Nodes are identified by a 8 character node handles (eg. 7Fdi3ZjC). structure of the filesystem is not encrypted.

Megatools maps node tree structure to a traditional filesystem paths (eg. /Root/SomeFile.DAT).

NOTE: By the nature of Mega.nz storage, several files in the directory can have the same name. To allow access to such files, the names of conflicting files are extended by appending dot and their node handle like this:
/Root/conflictingfile
/Root/conflictingfile.7Fdi3ZjC
/Root/conflictingfile.mEU23aSD

see? she handles the drama. ✨

You need to be aware of several special folders:

🏠 /Root

Writable directory representing the root of the filesystem.

πŸ—‘οΈ /Trash

Trash directory where Mega.nz web client moves deleted files. this directory is not used by megatools when removing files. so like, megatools doesn't touch it. noted. πŸ“

πŸ“₯ /Inbox

Not sure.

(yes. that's the whole thing. the manpage literally says "Not sure." and honestly? relatable. we're keeping it. πŸ’€)

πŸ‘₯ /Contacts

Directory containing subdirectories representing your contacts list. if you want to add contacts to the list, simply create subdirectory named after the contact you want to add. ✨

πŸ’Œ /Contacts/<email>

Directories representing individual contacts in your contacts list. these directories contain folders that others shared with you. all shared files are read-only, at the moment. so no editing other people's stuff, bestie. 🫢


πŸ”— SEE ALSO πŸ”—

megatools(7), megarc(5), megadf(1), megadl(1), megaget(1), megals(1), megamkdir(1), megaput(1), megareg(1), megarm(1), megacopy(1). the whole friend group. 🌈


πŸ‘‘ MEGATOOLS πŸ‘‘

Part of the megatools(7) suite.


πŸ’€ BUGS πŸ’€

Report bugs at https://github.com/megous/megatools or megous@megous.com. she wants to hear from you. πŸ›


πŸŽ€ AUTHOR πŸŽ€

Megatools was written by Ondrej Jirman <megous@megous.com>, 2013-2016.

Official website is http://megatools.megous.com.


okay that's the whole page bestie, go forth and copy some directories πŸ’–βœ¨

megatools 1.10.2 🌸 04/15/2020 🌸 and that's the MEGACOPY(1) footer, so you know exactly which version you just read. mwah. πŸ’…πŸ¦‹

πŸ“¦ where this page comes from