scribe_selection/
bundler.rs1use scribe_core::Result;
4use crate::context::CodeContext;
5use serde::{Deserialize, Serialize};
6
7#[derive(Debug, Clone, Serialize, Deserialize)]
8pub struct BundleOptions {
9 pub format: String,
10 pub include_metadata: bool,
11}
12
13impl Default for BundleOptions {
14 fn default() -> Self {
15 Self {
16 format: "json".to_string(),
17 include_metadata: true,
18 }
19 }
20}
21
22#[derive(Debug, Clone, Serialize, Deserialize)]
23pub struct CodeBundle {
24 pub content: String,
25 pub metadata: std::collections::HashMap<String, String>,
26}
27
28pub struct CodeBundler;
29
30impl CodeBundler {
31 pub fn new() -> Self {
32 Self
33 }
34
35 pub async fn bundle(
36 &self,
37 _context: &CodeContext,
38 _options: &BundleOptions
39 ) -> Result<CodeBundle> {
40 Ok(CodeBundle {
42 content: String::new(),
43 metadata: std::collections::HashMap::new(),
44 })
45 }
46}
47
48impl Default for CodeBundler {
49 fn default() -> Self {
50 Self::new()
51 }
52}