This commit is contained in:
parent
aa2ff7b2f0
commit
2f3113f55d
11742 changed files with 1223940 additions and 0 deletions
20
unikernel/duniverse/dune_/bin/exit_code.ml
Normal file
20
unikernel/duniverse/dune_/bin/exit_code.ml
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
type t =
|
||||
| Success
|
||||
| Error
|
||||
| Signal
|
||||
|
||||
let all = [ Success; Error; Signal ]
|
||||
|
||||
let code = function
|
||||
| Success -> 0
|
||||
| Error -> 1
|
||||
| Signal -> 130
|
||||
;;
|
||||
|
||||
let doc = function
|
||||
| Success -> "on success."
|
||||
| Error -> "if an error happened."
|
||||
| Signal -> "if it was interrupted by a signal."
|
||||
;;
|
||||
|
||||
let info e = Cmdliner.Cmd.Exit.info (code e) ~doc:(doc e)
|
||||
Loading…
Add table
Add a link
Reference in a new issue