r/PowerShell • u/rexm3 • Jan 12 '26
Script Sharing PowerShell un-sync script
I'm looking for a customizable script to stop OneDrive from syncing specific SharePoint sites/libraries. Then after the sync has completely stopped, removing the local files remaining of that specific site. Does anybody have a script for this already or any tips on this?
I would like the option to hard code the specific libraries to un-sync as I might need to execute it using RMM software.
8
Upvotes
View all comments
Show parent comment
1
u/rexm3 Jan 12 '26
disabling the sync using Reg might work, i'll try something with that. Though i'm affraid this will keep the files in sync limbo, making it impossible to remove. but i'll try