Lift the given inputs into a canonical node, mapping a lift failure (unknown directive, missing `id`, malformed `:::ref`, …) to a clean argument error so the CLI reports it gracefully instead of surfacing an internal error.
(inputs: &LiftInputs)
| 86 | /// directive, missing `id`, malformed `:::ref`, …) to a clean argument error so |
| 87 | /// the CLI reports it gracefully instead of surfacing an internal error. |
| 88 | pub fn lift(inputs: &LiftInputs) -> BridgeResult<CanonicalNode> { |
| 89 | lift_intent(&inputs.frontmatter, &inputs.body).map_err(|e| RepositoryError::InvalidOperation { |
| 90 | message: format!("could not lift intent: {e}"), |
| 91 | }) |
| 92 | } |
| 93 | |
| 94 | /// Sanitize an intent id/key for use as a directory name in the sidecar/vault |
| 95 | /// path. Keeps ASCII alphanumerics, `-` and `_`; everything else becomes `_`. |
no test coverage detected