#!/usr/bin/env nu # domains/librosys/commands.nu — CLI dispatch for KnowledgeBase/ContentProject projects. def main [cmd?: string, ...rest: string] { let domain_root = (^ore project root librosys | str trim) match ($cmd | default "") { "content-types" => { let schemas_dir = ([$domain_root, "reflection", "schemas"] | path join) if ($schemas_dir | path exists) { ls $"($schemas_dir)/*.ncl" | get name | each { |f| $f | path basename | str replace ".ncl" "" } | print } else { print " (no reflection/schemas/ in librosys)" } }, "index" => { print " (librosys RAG index status — not yet implemented)" }, "chapters" => { print " (librosys chapter map — not yet implemented)" }, _ => { print " librosys: content-types | index | chapters" }, } }