rsync just deleted half of my files
I had Delete option checked in User settings and empty Remote so I can set it up per Workspace. I run Rsync on unconfigured workspace (empty Remote) and got this command running:
> rsync -rlptzv --progress --delete --exclude=.git --exclude=.vscode --exclude=target /Users/xxx/Documents/myproject/ /
Guess what happened... luckily Mac has Time Machine...
Can you make sure Rsync does not run when Remote is empty and perhaps double check it is not running against /, please.
It should thow an error about remote not being set. Can you post you settings. Thanks.
Can we get a bump on this issue, its pretty critical. I just destroyed my laptop thanks to this bug.
Settings were something like:
"sync-rsync.sites": [
{
"remotePath": ""
}
],
"sync-rsync.delete": true,
"sync-rsync.onSave": true
OS: Ubuntu 21.04 vscode: 1.62 (ish)
https://github.com/thisboyiscrazy/vscode-rsync/blob/90ae7c488fa2a478cc385a5619fe4eba847dbbe7/src/Config.ts#L126
Is the culprit. Since "" does not equal null, you're defaulting to /. :cry: