write_eval_dir

Function write_eval_dir 

Source
pub fn write_eval_dir(
    dir: &Path,
    lesson: &Lesson,
    suite: &EvalSuite,
    lesson_id: &str,
    lesson_path: &Path,
) -> Result<(), GenError>
Expand description

Write the generated eval dir into dir/.smevals/, where dir is the course root.

The thin effectful shell (§2.4): it resolves the course’s location, computes the script-path prefix that reaches the repo’s scripts/smevals/ from the generated configs/, delegates the pure generation, and writes each file (creating directories as needed). The pure generate_eval_dir never touches the filesystem; this function never emits bytes. lesson_path is threaded into every task’s lesson: key (the file the runner grades); the CLI canonicalizes it to absolute before calling, since a relative value would break blendtutor eval for a runner whose CWD is the eval dir.