Add command line switches to pause and resume syncing.
Please add to Onedrive command line switches to pause and resume syncing.
Some programs create, delete or rename many files at the same time. When Onedrive jumps in to do an update in the middle of this process, It either hangs up or creates duplicate files. At present, the only way for developers to avoid these problems is to use the API function suspendthread. It works but it is not a good solution. If you would add command line switches /pause and /resume it would be much better.
Sean Kelly commented
I require this as need to stop remote studios updating when they are live on air ...
Jonathan Blaine commented
I frequently encounter issues when using PowerShell to interact with Excel - usually when taking a template, saving under a different name, then modifying the sheet. If I pause or shutdown the OneDrive client, I don't have these issues. I'm using onedrive.exe /shutdown and that seems to work - although recently (with the update to allow on-demand files) I've been getting messages that "Excel is trying to recover..." I don't experience these issues when I manually pause and resume, which would be preferable regardless. Note that I have both personal and OneDrive for Business instances running (not groove.exe), so a command line switch to pause or resume should (ideally) also allow specifying which instance should be paused/resumed.
that is required for my scenario because of onedrive running inside of an encrypted volume. If pause syncing in not possible, I have to completely restart the onedrive every time the location goes offline.