Initial commit

This commit is contained in:
2024-08-27 20:33:44 +02:00
commit 1f1832267d
14794 changed files with 1599592 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
from typing import ClassVar, List
from .base import OptimizerBase
__all__ = ["Jpegoptim"]
class Jpegoptim(OptimizerBase):
"""https://github.com/tjko/jpegoptim"""
library_name: ClassVar[str] = "jpegoptim"
image_format: ClassVar[str] = "jpeg"
@classmethod
def get_command_arguments(cls, file_path: str) -> List[str]:
return [
"--strip-all", # strip out all text information like comments and EXIF data
"--max=85", # set maximum quality
"--all-progressive", # make the resulting image progressive
file_path,
]