pub struct AgentIndex { /* private fields */ }Expand description
Manages the generated Context section in a project’s agents.md file.
Implementations§
Source§impl AgentIndex
impl AgentIndex
pub fn new(root: impl Into<PathBuf>) -> Self
Sourcepub fn with_packages(self, packages: &[ContextPackage]) -> Self
pub fn with_packages(self, packages: &[ContextPackage]) -> Self
Add Cargo package descriptions to the generated context section.
pub fn context_path(&self) -> &Path
pub fn generate_context_section(&self) -> Result<String>
pub fn update_agents_md(&self, path: impl AsRef<Path>) -> Result<()>
Trait Implementations§
Source§impl Clone for AgentIndex
impl Clone for AgentIndex
Auto Trait Implementations§
impl Freeze for AgentIndex
impl RefUnwindSafe for AgentIndex
impl Send for AgentIndex
impl Sync for AgentIndex
impl Unpin for AgentIndex
impl UnsafeUnpin for AgentIndex
impl UnwindSafe for AgentIndex
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more