#check #split #merge #fs

filego

A file splitting & merging solution

13 unstable releases (4 breaking)

Uses new Rust 2024

0.5.4 May 28, 2025
0.5.3 Mar 12, 2025
0.5.2 Feb 24, 2025
0.4.1 Dec 16, 2024
0.2.2 Jun 22, 2024

#131 in Multimedia

Download history

902 downloads per month

MIT license

52KB
1K SLoC

FileGo

A file splitting & merging solution.

Quick Start

Split file from a path to a directory with Split struct.

use std::path::PathBuf;

use filego::split::{Split, SplitResult};

let result: SplitResult = Split::new()
    .in_file(PathBuf::from("path").join("to").join("file"))
    .out_dir(PathBuf::from("path").join("to").join("dir"))
    .run()
    .unwrap();

Async version also available with the async-std/async_std and tokio features:

// This is a `async-std` example

use async_std::path::PathBuf;

use filego::split::{
    Split,
    SplitResult,
    async_std::SplitAsyncExt as _,
};

let result: SplitResult = Split::new()
    .in_file(PathBuf::from("path").join("to").join("file"))
    .out_dir(PathBuf::from("path").join("to").join("dir"))
    .run_async()
    .await
    .unwrap();
// This is a `tokio` example

use std::path::PathBuf;

use filego::split::{
    Split,
    SplitResult,
    tokio::SplitAsyncExt as _,
};

let result: SplitResult = Split::new()
    .in_file(PathBuf::from("path").join("to").join("file"))
    .out_dir(PathBuf::from("path").join("to").join("dir"))
    .run_async()
    .await
    .unwrap();

License

This project is licensed under the terms of the MIT license.

Dependencies

~0–5MB
~113K SLoC