Refactoring optparse code to be more adhoc

Thanks for reviewing this PR. I believe it increases the overall readability (mimicking the `optparse-applicative` tutorial)
If you accept it, I will modify `pdbQuery` tomorrow for consistency sake