Changeset 66 in code for trunk/cli/authors.ml
- Timestamp:
- Aug 21, 2024, 1:37:05 AM (8 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/cli/authors.ml
r65 r66 7 7 Person.Set.iter (fun x -> print_endline (Person.to_string x)) s 8 8 9 open Ocmd 10 let term = 11 let recurse = Arg.(value & flag & info ["R"] 12 ~doc:"include texts in subdirectories too") in 13 let topics = Arg.(value & opt (some string) None & info ["topics"] 14 ~docv:"TOPICS" ~doc:"display authors who have written on topics") in 15 Term.(const authors $ recurse $ topics), 16 Term.info "authors" ~doc:"list authors" 17 ~man:[ `S "DESCRIPTION"; `P "List author names" ] 9 open Cmdliner 10 let recurse = Arg.(value & flag & info ["R"] ~doc: "Include texts in subdirectories too") 11 let topics = Arg.(value & opt (some string) None & info ["topics"] ~docv:"topics" ~doc: "Display authors who have written on topics") 12 13 let authors_t = Term.(const authors $ recurse $ topics) 14 15 let cmd = 16 let doc = "List authors" in 17 let man = [ 18 `S Manpage.s_description; 19 `P "List author names" ] 20 in 21 let info = Cmd.info "authors" ~version:"%%VERSION%%" ~doc ~man in 22 Cmd.v info authors_t
Note:
See TracChangeset
for help on using the changeset viewer.