Install Requirements

1. Python 3.10+

Check Your Python Version

To check if you have a high enough version of Python:

  1. Open your favorite terminal application.

  2. Try running python

  3. If it says the command was not found, try the following:

    1. python3

    2. python3.10 or later minor version numbers

At least one of them should show something like the output below:

Example Python prompt for version 3.10.12
Python 3.10.12+ (heads/3.10:f91dfdf5ff, Jul 20 2023, 21:32:15) [GCC 10.2.1 20210110] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>

If it doesn’t, the see Installing Python section below.

If it does, then:

  1. type exit()

  2. press enter

  3. skip to Your Needs

Installing Python

Windows & Mac

On these platforms, it’s best to install Python from the official download pages:

Linux

Your distro’s package manager is usually the best place to look.

Distros by Approximate Beginner Friendliness

Distro

Best Approach

Linux Mint (All flavors)

sudo apt install python3

Pop!_OS

sudo apt install python3 or via the Pop!_Shop

Fedora

See Fedora’s Python guide

Debian

sudo apt install python3

Ubuntu

sudo apt install python3

Note

Ubuntu is at the bottom its Snap format has had multiple serious issues.

These include:

  1. Shipping .deb packages which instead install Snap versions

  2. Marking scam malware as “safe”

  3. Performance issues compared to .deb

If you don’t have 3.10 or higher in your distro’s package manager, see Non-Standard Python on Linux.

2. Active Virtual Environment

Python’s virtual environments (venvs for short) protect your projects from breaking each other. On operating systems such as Linux, they also help protect your system Python version.

In most cases, you’ll want to do the following:

1. Create a Virtual Environment

If you aren’t using PyCharm or VSCode, you can create a venv from the terminal with:

python -m venv .venv

This will create a venv named .venv in the current directory. To learn more, please see Python’s Creating virtual environments.

2. Make Sure Your Venv Is Activated

The way you activate a virtual environment varies with your:

  • operating system

  • development tools

With PyCharm and other heavyweight development environments, your venv will usually be automatically activated in the terminal windows of the tool.

If you’re using lighter tools, you may need to activate the venv manually through the terminal. The table of examples below assumes you created a venv as in the last section:

  • In the root directory of your project

  • Named .venv

OS

Example Command

Windows (CMD)

.venv\bin\activate.bat

Windows (PowerShell)

PS .venv\bin\activate.bat

Mac, Linux, and BSDs

source .venv/bin/activate

To learn more, please see Python’s How venvs work.

Account-Wide Usage Via pipx

If you only need to use Fontknife as a utility instead of an imported Python module, you can use pipx. It allows running any’ python package which provides runnable named scripts across your entire user account. It works by creating package-specific virtual environments, then performing some routing work.

After installing it, you can use pipx instead of pip when following install instructions.