|
ScriptDocs
How shell scripts are documented
Back to the MainPage... Note: This content is also mirrored at: https://github.com/spicyjack/public/blob/master/notes/script_docs.md Shell Script DocumentationLACK shell scripts with functions should be documented. The documentation serves to help explain how to use the shell functions in other scripts. Documentation Codes
Example usage: ## FUNC: some_shell_function ## ARG: Whatever this argument does in the function ## ARG: Whatever this other argument does in the function ## ENV: VAR1 was set in the environment for this function ## ENV: VAR2 was also set ## SETS: SET1, the name of an environment variable that is set ## SETS: SET2, the name of another environment variable set ## RET: '0' is returned if the function call was successful ## ERR: '2' is returned if a set of conditions are met ## ERR: '3' is returned if a different set of conditions are met ## DESC: This is a line of text describing this function
|