Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to pipe images into stdin in papirus-draw #180

Merged
merged 3 commits into from
Mar 12, 2018
Merged

Add ability to pipe images into stdin in papirus-draw #180

merged 3 commits into from
Mar 12, 2018

Conversation

schwma
Copy link
Contributor

@schwma schwma commented Mar 11, 2018

Follows Unix philosophy of using output of one program as input to another program.

Allows simple one-liners such as the following:
curl https://raw.githubusercontent.com/PiSupply/PaPiRus/master/bitmaps/papirus-logo.bmp | papirus-draw - -t resize

@tvoverbeek
Copy link
Contributor

Good idea.
We try to have the code Python 3 compatible, since Python 2 will stop to be supported in 2020.
In Python 3 there is a strict separation between strings (text) and bytestreams.
We need a bytestream here for Python 3.
Can you make the code Python 2 and Python 3 compatible?

@schwma
Copy link
Contributor Author

schwma commented Mar 11, 2018

Hi!
I made my code Python 2 and Python 3 compatible. I'm still new to Python and especially the compatibility problems between different versions, so if there is a better way to handle this, then please let me know.

@tvoverbeek
Copy link
Contributor

@schwma Thanks. Tested it with both Python 2 and 3. Works fine. Merged

@tvoverbeek tvoverbeek merged commit 5e7fd6a into PiSupply:master Mar 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants