scour-project / scour

Scour - An SVG Optimizer / Cleaner
Apache License 2.0
757 stars 61 forks source link

Move over to argparse #278

Open IceflowRE opened 3 years ago

IceflowRE commented 3 years ago

Currently optparse is used and deprecated and stopped developing since 2011. Also the options should be moved to a dict, it is a hassle to work with optparse.Values in third-party software.

It was already a bit discussed in #112 .

Ede123 commented 3 years ago

Indeed, this has been a "low priority" improvement for the last five years, see https://github.com/scour-project/scour/pull/44. ;-)

PRs welcome.

For now you can make use of sanitizeOptions (which was introduced in the linked PR) which lets you make use of "random" objects (so you don't absolutely need to handle optparse.Values).