--
We've all been waiting for the official Linux ProtonDrive sync client for too long.
I tried different existing solutions to keep folders in sync with Proton Drive on my Linux machines ( including a headless one). None of them were 100% match for me. So I wrote a command-line client on top of Proton's open-source Drive SDK.
GitHub: https://github.com/NSky/protondrive-client
What it is, and what it isn't
- Not an rclone wrapper, and not a reverse-engineered client. It doesn't re-implement Proton's API or encryption.
- It's built on Proton's own open-source Drive SDK (C#) and Proton's cryptography library. Login, keys, encryption and API calls all go through Proton's code. My part is the CLI and the sync engine on top. (Proton doesn't publish these libraries on NuGet, so I build the packages from forks of their repositories.)
- Sync follows Proton's events feed. After the first sync, it asks Drive "what changed since last time?" instead of walking your whole remote folder tree on every pass. That keeps it fast, and light on the API, even with large folders.
Features
- `login` with password, TOTP 2FA and two-password accounts; the session is saved and refreshed automatically
- `ls`, `download`, `upload` and `delete` for files and whole folders, with parallel transfers and a live per-file progress display
- `upload` never overwrites anything: it checks every name against the server first, and if anything conflicts, nothing is sent
- `delete` moves items to the Proton Drive trash by default; folders need `-r`, permanent deletion needs `--permanent`, and it asks before doing anything
- Two-way sync: `protondrive sync add ~/Proton /Backup/Laptop`, then run it once or keep it running with `--watch`
- `protondrive service enable` runs sync in the background as a systemd user service, and keeps running after you log out
- A live status line shows what it's doing during long steps (e.g. "Listing the remote folder: 48,210 items · Photos/2019")
How sync decides
It does a three-way comparison of the local folder, the remote state (kept current from the events feed) and a local SQLite record of the last agreed state, so it knows which side changed. When both sides changed a file, you get a conflict copy instead of a silent overwrite.
Output is colour-coded: real conflicts show in bold yellow as `CONFLICT …`, deletions in red, uploads in green, downloads in cyan. `--dry-run` shows the whole plan first.
Already have a copy of your files? You can point sync at a folder you filled with another tool. Files that match (by checksum, or by size and modification time when the server has no checksum) are just recorded as in sync, with nothing transferred and no conflict copies.
The first listing of a big Drive is fast too: it goes one folder level at a time and batches the requests, instead of making two round trips per folder.
Safety, because sync tools can eat data
- Deleted files go to a local trash folder or to Proton's trash, never straight to oblivion
- If your local folder suddenly looks empty (unmounted disk, wrong path), it refuses to sync
- If the cloud side suddenly looks empty, it pauses that folder and keeps your local files
- Mass local deletions (more than 10 items and over half the folder) are held back until you confirm with `--force`
- When something is held back, you're told without having to read logs: a desktop notification, a notice file in the synced folder, a message at login, and the systemd status line
Install
- Arch: `yay -S nsky-protondrive-client-bin` (AUR)
- Other distributions: self-contained tarballs for x86-64 and ARM64 on the releases page (glibc 2.34+, so Ubuntu 22.04+, Debian 12+, Fedora 35+ and so on). No .NET runtime needed; `sudo ./install.sh` puts it in /usr/local.
Caveats
- Beta. Provided as is, without warranty. Keep independent backups of anything important.
- Unofficial: built on Proton's SDK, but not affiliated with or endorsed by Proton AG.
- No CAPTCHA (human verification) support yet. If Proton asks for one at login, it won't work.
- Linux only.
It's written in C# / .NET 10, MIT licensed. Bug reports, especially about sync edge cases, are very welcome.