libdsync-hasezoey

Crates.iolibdsync-hasezoey
lib.rslibdsync-hasezoey
version0.3.0+deprecated
sourcesrc
created_at2023-07-06 21:49:35.596921
updated_at2024-08-24 12:15:56.109446
descriptionGenerate rust structs & query functions from diesel schema files.
homepage
repositoryhttps://github.com/hasezoey/dsync
max_upload_size
id910285
size73,813
hasezoey (hasezoey)

documentation

README

libdsync-hasezoey

This is a fork of Wulf's dsync with some Pull Requests merged, see Difference with original

For a binary, use dsync-hasezoey crates.io or dsync-hasezoey github

Usage:

use std::{collections::HashMap, path::PathBuf};
use dsync_hasezoey::{GenerationConfig, TableOptions};

pub fn main() {
    let dir = env!("CARGO_MANIFEST_DIR");

    dsync_hasezoey::generate_files(
        PathBuf::from_iter([dir, "src/schema.rs"]), 
        PathBuf::from_iter([dir, "src/models"]), 
        GenerationConfig { /* ... your generation options ... */ }
    );
}

docs.rs Documentation

Commit count: 135

cargo fmt