datalad_next.utils.rmtree
- datalad_next.utils.rmtree(path: str | Path, chmod_files: bool | Literal['auto'] = 'auto', children_only: bool = False, *args: Any, **kwargs: Any) None [source]
To remove git-annex .git it is needed to make all files and directories writable again first
- Parameters:
path (Path or str) -- Path to remove
chmod_files (string or bool, optional) -- Whether to make files writable also before removal. Usually it is just a matter of directories to have write permissions. If 'auto' it would chmod files on windows by default
children_only (bool, optional) -- If set, all files and subdirectories would be removed while the path itself (must be a directory) would be preserved
*args
**kwargs -- Passed into shutil.rmtree call