Skip to main content

systemprompt_sync/export/
mod.rs

1//! Disk serialisation helpers used by the various `*_to_disk` operations.
2//! Each submodule emits the YAML config + Markdown body layout expected by
3//! the matching `*Local Sync`.
4//!
5//! Copyright (c) systemprompt.io — Business Source License 1.1.
6//! See <https://systemprompt.io> for licensing details.
7
8mod content;
9
10pub use content::{export_content_to_file, generate_content_markdown};
11
12pub fn escape_yaml(s: &str) -> String {
13    s.replace('\\', "\\\\")
14        .replace('"', "\\\"")
15        .replace('\n', "\\n")
16}