123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657(**************************************************************************)(* *)(* Copyright 2020 OCamlPro & Origin Labs *)(* *)(* All rights reserved. This file is distributed under the terms of the *)(* GNU Lesser General Public License version 2.1, with the special *)(* exception on linking described in the file LICENSE. *)(* *)(**************************************************************************)openEzcmd.V2openTypesopenEZCMD.TYPESletcmd_name="list"letall_kinds=["projects";"packages"]letcmd=letargs=ref[]inEZCMD.subcmd_name(fun()->letargs=match!argswith|[]|["all"]->all_kinds|args->argsinList.iter(function|"projects"->Printf.printf"Known project skeletons: %s\n%!"(String.concat" "(List.map(funs->s.skeleton_name)(Skeleton.project_skeletons())))|"packages"->Printf.printf"Known packages skeletons: %s\n%!"(String.concat" "(List.map(funs->s.skeleton_name)(Skeleton.package_skeletons())))|s->Printf.eprintf"Error: unknown kind: %S. Possible kinds: %s\n%!"s(String.concat" "all_kinds);exit2)args)~args:[[],Arg.Anons(funlist->args:=list),EZCMD.info"Use 'projects' or 'packages' to display corresponding skeletons"]~doc:"List available project or packages skeletons"~version:"0.4.0"~man:[`S"DESCRIPTION";`Blocks[`P"List available project or packages skeletons"]]