The reason I opened #23 was to try to fix the issue that the read_file() function crashes into an infinite loop when trying to read an empty (or only containing white space) file.
Steps to reproduce:
Empty the generated README.md
Run ansible-gendoc again.
Expected behavior:
Ignore the file and continue.
Possible fix:
I'm not sure where it crashes exactly. Maybe in function read_file you could check if there is data left after removing the white spaces before returning.
The reason I opened #23 was to try to fix the issue that the read_file() function crashes into an infinite loop when trying to read an empty (or only containing white space) file.
Steps to reproduce:
Expected behavior:
Possible fix: I'm not sure where it crashes exactly. Maybe in function
read_file
you could check if there is data left after removing the white spaces before returning.