itsfoss / compress-pdf

A simple tool that allows you to compress PDF files
Other
72 stars 9 forks source link

Use all python code if possible #14

Closed LyzardKing closed 4 years ago

LyzardKing commented 4 years ago

Hi! I just "merged" the shell code in python, I also added the success/failure dialogs as proper modal dialogs. If possible I'd like to add a cli option, again in python.. If this is an acceptable PR and option let me know!

Thanks for the program! I needed something like this but I never bothered to write anything with a gui.

abhishekpc commented 4 years ago

@LyzardKing Thanks for the changes. We'll run some tests on our end (to avoid surprises) and merge the PR after that.

LyzardKing commented 4 years ago

Great! I was thinking about adding automated tests (i.e. a pdf that can succeed, and one that is known to fail) on github actions/travis.. What tests are you running on your end?

abhishekpc commented 4 years ago

@LyzardKing That is already on our to-do list. For now, it is manual testing with files with spaces/quotes in name, files that are known to have bigger size when compressed etc.

Since I never coded in Python (I haven't coded anything in last few years), it will take me some time and effort to create the tests in Python. Panos is also new to Python.

If you have suggestions for the unit tests (or is it called something else), please let us know.

LyzardKing commented 4 years ago

Yes, I made a very basic pdf test.. I can open another PR (since setting up the tests made me split slightly the ui and the logic..).