Closed ShalokShalom closed 1 year ago
Yeah, fair enough. This was developed mostly for use with https://github.com/adafruit/Raspberry-Pi-Installer-Scripts to assist in conversion to Python scripts. However, there are definitely some useful things in this library for other uses.
Wonderful. I would mostly like to understand, how to simply launch a command, and how to get stderr and stdout back 😃
The best example script is probably https://github.com/adafruit/Raspberry-Pi-Installer-Scripts/blob/main/adafruit-pitft.py. The main function for running commands is:
run_command(self, cmd, suppress_message=False, return_output=False)
Stderr and stdout are combined in the function (though they call different functions to write the message back to the console). All output is returned if return_output
is True
and it is not printed to the console if suppress_message
is True
.
Do we want to include this in the readthedocs?
Eventually. I think the code just needs to have someone (probably me) go through it and have docstrings added for the public functions or at least the more commonly used ones.
Well, that would be more API documentation. I mean docs who can be read by the average Joe. Something you would include in a Readme. Something like a quick start. 👍🏻
Hi there :)
First - the API documentation is well hidden, and its almost impossible to find on the README. :) Second - I miss simple examples, particularly about sending shell commands and receiving their outputs.
The API documentation seems to be a bit too elaborate for me, thanks.