mirror of
https://github.com/kellyjonbrazil/jc.git
synced 2025-06-19 00:17:51 +02:00
doc update
This commit is contained in:
@ -4,19 +4,39 @@ jc - JSON CLI output utility utils
|
|||||||
```python
|
```python
|
||||||
warning_message(message)
|
warning_message(message)
|
||||||
```
|
```
|
||||||
|
|
||||||
Prints a warning message for non-fatal issues
|
Prints a warning message for non-fatal issues
|
||||||
|
|
||||||
|
Parameters:
|
||||||
|
|
||||||
|
message (string) text of message
|
||||||
|
|
||||||
|
Returns:
|
||||||
|
|
||||||
|
no return, just prints output to STDERR
|
||||||
|
|
||||||
## error_message
|
## error_message
|
||||||
```python
|
```python
|
||||||
error_message(message)
|
error_message(message)
|
||||||
```
|
```
|
||||||
|
|
||||||
Prints an error message for fatal issues
|
Prints an error message for fatal issues
|
||||||
|
|
||||||
|
Parameters:
|
||||||
|
|
||||||
|
message (string) text of message
|
||||||
|
|
||||||
|
Returns:
|
||||||
|
|
||||||
|
no return, just prints output to STDERR
|
||||||
|
|
||||||
## compatibility
|
## compatibility
|
||||||
```python
|
```python
|
||||||
compatibility(mod_name, compatible)
|
compatibility(mod_name, compatible)
|
||||||
```
|
```
|
||||||
Checks for the parser's compatibility with the running OS platform.
|
Checks for the parser's compatibility with the running OS platform.
|
||||||
|
|
||||||
Arguments:
|
Parameters:
|
||||||
|
|
||||||
mod_name (string) __name__ of the calling module
|
mod_name (string) __name__ of the calling module
|
||||||
|
|
||||||
|
26
jc/utils.py
26
jc/utils.py
@ -4,7 +4,17 @@ import sys
|
|||||||
|
|
||||||
|
|
||||||
def warning_message(message):
|
def warning_message(message):
|
||||||
"""Prints a warning message for non-fatal issues"""
|
"""
|
||||||
|
Prints a warning message for non-fatal issues
|
||||||
|
|
||||||
|
Parameters:
|
||||||
|
|
||||||
|
message (string) text of message
|
||||||
|
|
||||||
|
Returns:
|
||||||
|
|
||||||
|
no return, just prints output to STDERR
|
||||||
|
"""
|
||||||
|
|
||||||
error_string = f'''
|
error_string = f'''
|
||||||
jc: Warning - {message}
|
jc: Warning - {message}
|
||||||
@ -13,7 +23,17 @@ def warning_message(message):
|
|||||||
|
|
||||||
|
|
||||||
def error_message(message):
|
def error_message(message):
|
||||||
"""Prints an error message for fatal issues"""
|
"""
|
||||||
|
Prints an error message for fatal issues
|
||||||
|
|
||||||
|
Parameters:
|
||||||
|
|
||||||
|
message (string) text of message
|
||||||
|
|
||||||
|
Returns:
|
||||||
|
|
||||||
|
no return, just prints output to STDERR
|
||||||
|
"""
|
||||||
|
|
||||||
error_string = f'''
|
error_string = f'''
|
||||||
jc: Error - {message}
|
jc: Error - {message}
|
||||||
@ -24,7 +44,7 @@ def error_message(message):
|
|||||||
def compatibility(mod_name, compatible):
|
def compatibility(mod_name, compatible):
|
||||||
"""Checks for the parser's compatibility with the running OS platform.
|
"""Checks for the parser's compatibility with the running OS platform.
|
||||||
|
|
||||||
Arguments:
|
Parameters:
|
||||||
|
|
||||||
mod_name (string) __name__ of the calling module
|
mod_name (string) __name__ of the calling module
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user