srwiez/svgtinyps-cli

SVG (Portable and Secure) commandline converter for BIMI compliance

v1.0.6 2023-12-02 11:07 UTC

This package is auto-updated.

Last update: 2024-04-07 17:16:58 UTC


README

GitHub release (with filter) Packagist PHP Version Packagist License (custom server) GitHub Workflow Status (with event)

CLI Tool for SVG Tiny P/S (Portable and Secure) conversion and BIMI compliance.

Read more from bimi group and the RFC

🧪 If you just want to convert your SVG in a nice UI, you can use the online version of the converter!

You can also checkout the PHP package that this project is based on.

Installation

Via Composer global install command

composer global install srwiez/svgtinyps-cli

By downloading binaries on the latest release, currently only these binaries are compiled on the CI:

  • macOS x86_64
  • linux x86_64
  • linux arm

Usage

Identify issues in an SVG file

svgtinyps issues input.svg

Convert an SVG file to SVG (P/S)

svgtinyps convert input.svg output.svg

If in the identified issues, you missing th title tag, you can set its value with the --title option

svgtinyps convert input.svg output.svg --title="My awesome company"

Testing

This project use Pest for testing.

composer test

Build from sources

This project use box, php-static-cli and php-micro. A build script has been created to build the project. (tested only on macOS x86_64)

composer build

Roadmap

Pull requests are welcome! Here are some ideas to get you started:

  • Option to set <title>
  • Use Symfony Console for better ui
  • Build binaries for Windows, Linux and MacOS
  • Publish on Homebrew
  • Automate everything with Github Actions

Credits

svgtinyps was created by Eser DENIZ.

Inspired by the official scripts of authindicators/svg-ps-converters

Thanks to gilbarbara/logos for the logos used in the tests.

License

svgtinyps PHP is licensed under the MIT License. See LICENSE for more information.