ihatemoney/hatch_build.py
Éloi Rivard 8c865b1037
chore: move from setuptools to hatch_build
packages are built with hatch instead of setuptools.
Translations catalogs are compiled at package build time, and before unit tests are
ran. Thus there is no need to keep them versioned in git anymore.
2023-12-12 13:26:36 +01:00

11 lines
297 B
Python

import sys
from hatchling.builders.hooks.plugin.interface import BuildHookInterface
class CustomBuildHook(BuildHookInterface):
def initialize(self, version, build_data):
sys.path.insert(0, "./ihatemoney")
from babel_utils import compile_catalogs
compile_catalogs()