mirror of
https://github.com/NaitLee/Cat-Printer.git
synced 2025-07-01 05:40:08 -07:00
Fix
This commit is contained in:
parent
08a67f7b5a
commit
b56c4dad1c
12
README.md
12
README.md
@ -82,6 +82,18 @@ On Arch Linux based distros you may install `bluez` first, as it may not be inst
|
||||
sudo pacman -S bluez bluez-utils
|
||||
```
|
||||
|
||||
You may or may not need to install ImageMagick and Ghostscript, depending on your distro.
|
||||
```bash
|
||||
sudo apt install imagemagick ghostscript
|
||||
```
|
||||
Or the package manager of your distro.
|
||||
|
||||
Extra configuration is required for ImageMagick to work. Because IM is made for external webserver, a strict security policy is applied. You need to add the following line to `/etc/ImageMagick-6/policy.xml` before `</policymap>`:
|
||||
```xml
|
||||
<policy domain="coder" rights="read | write" pattern="PDM" />
|
||||
```
|
||||
Because this script is only accesible by localhost, or at most your local network, this is safe.
|
||||
|
||||
*Packaging is also on the way!*
|
||||
|
||||
### MacOS
|
||||
|
@ -567,6 +567,8 @@ def fallback_program(*programs):
|
||||
return None
|
||||
|
||||
_MagickExe = fallback_program('magick', 'magick.exe', 'convert', 'convert.exe')
|
||||
if _MagickExe is None:
|
||||
error('ImageMagic not found. Please install and configure as per readme.')
|
||||
|
||||
def magick_text(stdin, image_width, font_size, font_family):
|
||||
'Pipe an io to ImageMagick for processing text to image, return output io'
|
||||
|
Loading…
x
Reference in New Issue
Block a user