1 use crate::fs::asyncify;
2 
3 use std::io;
4 use std::path::Path;
5 
6 /// Removes an existing, empty directory.
7 ///
8 /// This is an async version of [`std::fs::remove_dir`](std::fs::remove_dir)
remove_dir(path: impl AsRef<Path>) -> io::Result<()>9 pub async fn remove_dir(path: impl AsRef<Path>) -> io::Result<()> {
10     let path = path.as_ref().to_owned();
11     asyncify(move || std::fs::remove_dir(path)).await
12 }
13