pyspj.entry.cli¶
cli¶
-
pyspj.entry.cli.
cli
(*args: Any, **kwargs: Any) → Any¶ Command line entry of pyspj CLI.
- Parameters
input_content – Input content, should be a string or
None
.output_content – Output content, should be a string or
None
.input_file – Input filename, should be a string or
None
.output_file – Output filename, should be a string or
None
.value – Additional arguments, like
KEY=VALUE
.result_type – Result type, should be a string.
spj – Special judge string.
pretty – Enable pretty print or not, default is on.
pyspj_entry¶
-
pyspj.entry.cli.
pyspj_entry
(name: str, spj, result_type: str = 'free', version: Optional[str] = None, author: Optional[str] = None, email: Optional[str] = None)[source]¶ Create your pyspj CLI entry.
- Parameters
name – Name of the special judge.
spj – Special judge function or string.
result_type – Type of result, default is
FREE
.version – Version information, default is
None
.author – Author of this special judge, default is
None
.email – Author email of this special judge, default is
None
.
- Returns
A click function, can be used directly to create a CLI program.