Last active
March 20, 2022 07:45
-
-
Save jeangjenq/eef5838949774d1b9fb53a181410c62a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from subprocess import call | |
#gather a list of files/directories/subdirectories | |
list = [] | |
for root, directories, filenames in os.environ['OneDrive']: | |
for directory in directories: | |
list.append(os.path.join(root, directory)) | |
for filename in filenames: | |
list.append(os.path.join(root, filename)) | |
#run 'fsutil reparsepoint delete #filename' for every thing in the list | |
for file in list: | |
call(["fsutil", "reparsepoint", "delete", file]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment