mirror of
https://github.com/ryanoasis/nerd-fonts.git
synced 2025-01-31 12:27:22 +02:00
font-patcher: Correct python module missing message
[why] When the fontforge python bindings are not installed we fail while importing psMat. The message suggests that fontforge itself is not installed - which is not the real reason. One can use the libfontforfge with the python-fontforge without having the GUI program fontforge. Furthermore we link to outdated installation instructions. [how] We already check and report correctly what needs to be done with the fontforge module import. As both modules are often in the same package we should probably report the same message. That message holds correct hints for Debian/Ubuntu. It does not have a link to fontforge, though. [note] Also update Debian package name. Fixes: #725 Reported-by: Aniket Teredesai <a@aniketteredesai.com> Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
This commit is contained in:
parent
6564e71fce
commit
ac60053b3a
@ -14,10 +14,6 @@ projectNameAbbreviation = "NF"
|
||||
projectNameSingular = projectName[:-1]
|
||||
|
||||
import sys
|
||||
try:
|
||||
import psMat
|
||||
except ImportError:
|
||||
sys.exit(projectName + ": FontForge module is probably not installed. [See: http://designwithfontforge.com/en-US/Installing_Fontforge.html]")
|
||||
import re
|
||||
import os
|
||||
import argparse
|
||||
@ -30,12 +26,13 @@ try:
|
||||
except ImportError:
|
||||
sys.exit(projectName + ": configparser module is probably not installed. Try `pip install configparser` or equivalent")
|
||||
try:
|
||||
import psMat
|
||||
import fontforge
|
||||
except ImportError:
|
||||
sys.exit(
|
||||
projectName + (
|
||||
": FontForge module could not be loaded. Try installing fontforge python bindings "
|
||||
"[e.g. on Linux Debian or Ubuntu: `sudo apt install fontforge python-fontforge`]"
|
||||
"[e.g. on Linux Debian or Ubuntu: `sudo apt install fontforge python3-fontforge`]"
|
||||
)
|
||||
)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user