Command line usage

I am currently running macOS 10.12 and I was trying to find how to use Duplicati in the terminal command line interface. I still haven’t found it yet.

I have found the following file that hints about command line usage:
/Applications/Duplicati.app/Contents/MacOS/duplicati-cli

I tried running this using: bash /Applications/Duplicati.app/Contents/MacOS/duplicati-cli.

I then received the following output:

Invalid type Microsoft.WindowsAzure.Storage.Blob.BlobEncryptionPolicy for instance field Microsoft.WindowsAzure.Storage.Blob.BlobRequestOptions:<EncryptionPolicy>k__BackingField
Invalid type Microsoft.WindowsAzure.Storage.Queue.QueueEncryptionPolicy for instance field Microsoft.WindowsAzure.Storage.Queue.QueueRequestOptions:<EncryptionPolicy>k__BackingField
Invalid type Microsoft.WindowsAzure.Storage.Table.TableEncryptionPolicy for instance field Microsoft.WindowsAzure.Storage.Table.TableRequestOptions:<EncryptionPolicy>k__BackingField

See duplicati.commandline.exe help <topic> for more information.
  General: example, changelog
  Commands: backup, find, restore, delete, compact, test, compare, purge
  Reparing: repair, affected, list-broken-files, purge-broken-files
  Debugging: debug, logging, create-report, test-filters, system-info, send-mail
  Targets: aftp, amzcd, azure, b2, box, cloudfiles, dropbox, ftp, file, googledrive, gcs, hubic, jottacloud, mega, onedrive, openstack, s3, ssh, od4b, mssp, tahoe, webdav
  Modules: aes, gpg, zip, 7z, console-password-input, mssql-options, hyperv-options, http-options, sendhttp, sendmail, runscript, sendxmpp, check-mono-ssl
  Formats: date, time, size, encryption, compression
  Advanced: mail, advanced, returncodes, filter, <option>

http://www.duplicati.com/              Version:  - 2.0.2.1_beta_2017-08-01



That output suggests running duplicati.commandline.exe help <topic> but I am not running a Windows machine.

Even running bash /Applications/Duplicati.app/Contents/MacOS/duplicati-cli help gives the same message.

It did work, however, when I used bash /Applications/Duplicati.app/Contents/MacOS/duplicati-cli help example.

I currently have Duplicati normally running and backing up stuff, but I would like to use a command to be able to see the progress log through the terminal interface.

I also think it would be helpful to include the command line usage on GitHub. What do you think?

That part is a packaging error.

Yes, duplicati-cli is a wrapper for running mono Duplicati.CommandLine.exe, but it is perhaps a bit confusing.

Yes, but that is not how the commandline interface works. There is another discussion on that here:

We could do that. It would be easier to search but at the cost of potentially being out-of-sync with the version you have installed.

How do you propose including command line usage options? Do you think that it would be better if there is a page on the Duplicati wiki with all of the options and usage? (I like the Duplicati wiki idea.)

My idea was that after a new build, we basically run:

echo "This is the commandline arguments supported in version x.y.z: " > commandline.md
echo "```" >> commandline.md
Duplicati.CommandLine.exe help all >> commandline.md
echo "```" >> commandline.md

That would make a Markdown document with the commandline data, and we can then simply store that is a wiki page.

1 Like

Should this already work in the current builds? I get a “Topic not found: all” after executing this command.

I remembered wrong, I was thinking of help advanced, but I just tried it, and it only outputs the options, not the other help topics.

Is it perhaps worth having a how-to topic about the command line that includes the output of help advanced for the most recent beta and canary versions?

I know it’s not complete, but it’s a searchable start…

Will this include usage examples and explanations?

It could, though I’m thinking just the contents of command-line help. Basically something searchable and for those that aren’t command-line savvy.

I’ll try to add examples when I next get to a device with Duplicati on it.

Okay. Thanks. I was initially thinking about creating a wiki page but that can get easily outdated.

1 Like