Pyscan is coded in a psuedo-procedural manner where the top level works just like any procedural program (the functions are "chained" in a way) but the internals use structs and models/classes to an extent enough to call it OOP. It's a mix of both worlds.
There's comments on almost anything comment-able and worthy. Feel free to look around.
-
parser.rs
- top level look at the parser. Check outextractor.rs
to really see the extraction and file discovery being done. -
scanner::api.rs
- how the API stuff gets done using the structOsv
, look atmod.rs
for a higher level view. -
docker.rs
- handles getting and doing stuff with Docker. [this one is buggy and might get deprecated because i dont really care about docker, just run the program inside the container or something] -
display.rs
- some functions used to print to the screen, not all though.
-
This thing will be updated every once in a while to detail how pyscan works in a much more articulate and better way, including subcommands and other arguments and quirks.
-
If you think the codebase is designed badly, I don't know, it might be. I have never made a CLI tool before so, there's that. Open an issue or make a PR and I'm more than willing to learn from you.
-
Please be descriptive and detailed in your PRs, comments and other decent things. It's very cool what the open source community has done for pyscan so far.