Image processing for command line interface.
Image processing for command line interface using Python3 and Pillow (LICENSE).
imp <command> <input-file> <optional flags>
# Example:
imp convert ~/image.png --ext ico
Valid commands | |
---|---|
trim | Remove transparent pixels in the edges of the image. |
convert | Change a file image type. |
resize | Resize a image. |
crop | Crop a part of the image. |
Valid optional flags | ||
---|---|---|
--width | -w | Width of the output image. |
--height | -h | Height of the output image. |
--top | -t | The top of a crop rect. |
--left | -l | The left of a crop rect. |
--ext | -e | The output extension (Could be: 'PNG', 'PPM', 'JPEG', 'JPG', 'GIF', 'TIFF', 'BMP', 'ICO'). |
--out | -o | The output path. |
--version | -v | Show current Imp version. |
--help | -p | Show the help. |
To build first install dependencies:
# with pipenv
pipenv install
# or with global pipy
pip install -r requirements.txt
and run PyInstaller
:
# In Windows
PyInstaller PyInstaller/imp.windows.spec
# In Linux
PyInstaller PyInstaller/imp.linux.spec
# Or generate your own spec file
PyInstaller __main__.py