gitdb-database
Version:
A production-ready CLI tool for managing a NoSQL database using GitHub repositories as storage
22 lines • 615 B
TypeScript
export type ShardConfig = {
[collection: string]: {
repo: string;
branch?: string;
};
};
/**
* Load sharding configuration from .gitdb/shards.json
*/
export declare function loadShardsConfig(path: string): ShardConfig;
/**
* Save sharding configuration to .gitdb/shards.json
*/
export declare function saveShardsConfig(config: ShardConfig, path: string): void;
/**
* Resolve the repo/branch for a given collection
*/
export declare function resolveShard(collection: string, config: ShardConfig): {
repo: string;
branch?: string;
} | null;
//# sourceMappingURL=sharding.d.ts.map