Skip to content

Commit

Permalink
Remove usage of pkg_resources in docs/conf.py (psf#4251)
Browse files Browse the repository at this point in the history
  • Loading branch information
Viicos committed Feb 26, 2024
1 parent ea66d40 commit 8990023
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,9 @@

import os
import string
from importlib.metadata import version
from pathlib import Path

from pkg_resources import get_distribution

CURRENT_DIR = Path(__file__).parent


Expand All @@ -43,7 +42,7 @@ def make_pypi_svg(version: str) -> None:

# Autopopulate version
# The version, including alpha/beta/rc tags, but not commit hash and datestamps
release = get_distribution("black").version.split("+")[0]
release = version("black").split("+")[0]
# The short X.Y version.
version = release
for sp in "abcfr":
Expand Down

0 comments on commit 8990023

Please sign in to comment.