Function journal_load

Source
pub fn journal_load(journals: &mut Vec<Journal>, aim_path: &Path) -> Result<()>
Expand description

Loads journal entries from a .jnl file.

This function loads journal entries from a .jnl file. If the .jnl file doesn’t exist, it will attempt to create it by scanning the corresponding .aim file.

§Arguments

  • journals - Vector to store the loaded journal entries
  • aim_path - Path to the .aim file to load the journal for

§Returns

  • Ok(()) on successful load
  • Err if the file cannot be read or parsed

§Examples

use std::path::Path;
use aimx::aim::{Journal, journal_load};

let mut journals = Vec::new();
let result = journal_load(&mut journals, Path::new("workflow.aim"));