dune/doc/jbuild

48 lines
845 B
Plaintext
Raw Normal View History

2017-02-26 19:49:54 +00:00
(* -*- tuareg -*- *)
open StdLabels
let commands =
[ "build"
; "build-package"
; "external-lib-deps"
; "install"
; "installed-libraries"
; "runtest"
; "uninstall"
]
let jbuild =
String.concat ~sep:""
({|
(jbuild_version 1)
2017-02-24 17:36:39 +00:00
2017-02-21 15:09:26 +00:00
(install
((section doc)
(files (manual.org))))
2017-02-24 17:36:39 +00:00
(rule
((targets (jbuilder.1))
(action (with-stdout-to ${@}
(run ${bin:jbuilder} --help=groff)))))
2017-02-26 19:49:54 +00:00
|} :: List.map commands ~f:(fun cmd ->
Printf.sprintf {|
(rule
((targets (jbuilder-%s.1))
(action (with-stdout-to ${@}
(run ${bin:jbuilder} %s --help=groff)))))
|} cmd cmd)
@ [ Printf.sprintf {|
2017-02-24 17:36:39 +00:00
(install
((section man)
(files (
jbuilder.1
2017-02-26 19:49:54 +00:00
%s
2017-02-24 17:36:39 +00:00
))))
2017-02-26 19:49:54 +00:00
|} (String.concat ~sep:"\n "
(List.map commands ~f:(Printf.sprintf "jbuilder-%s.1")))
])
2017-02-24 17:36:39 +00:00
2017-02-26 19:49:54 +00:00
let () =
Jbuild_plugin.V1.send jbuild