liboxen 0.46.8

Oxen is a fast, unstructured data version control, to help version large machine learning datasets written in Rust.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use crate::model::CommitEntry;
use serde::{Deserialize, Serialize};
use utoipa::ToSchema;

#[derive(Deserialize, Serialize, Debug, Clone, ToSchema)]
pub struct RemoteEntry {
    pub filename: String,
    pub hash: String,
}

impl RemoteEntry {
    pub fn from_commit_entry(entry: &CommitEntry) -> RemoteEntry {
        RemoteEntry {
            filename: String::from(entry.path.to_str().unwrap()),
            hash: entry.hash.to_owned(),
        }
    }
}