1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
use io;
use copy_files;
use get_file_paths;
/// This function copies all files and directories from the source directory to the destination directory.
///
/// # Arguments
///
/// * `src_dir` - The source directory path.
/// * `dest_dir` - The destination directory path.
/// * `include` - The optional list of files to include in the processing.
/// * `exclude` - The optional list of files to exclude from the processing.
///
/// # Examples
///
/// ```
/// use zenn2press::copy_images;
///
/// #[tokio::main]
/// async fn main() -> std::io::Result<()> {
/// let src_dir = "demo/zenn/images";
/// let dest_dir = "demo/press/docs/public/images";
/// let include = Some(vec!["sample-article-1"]);
/// let exclude = None;
///
/// copy_images(src_dir, dest_dir, include, exclude).await?;
/// Ok(())
/// }
/// ```
pub async