Merge remote-tracking branch 'origin/release'

This commit is contained in:
Overhang.IO 2025-04-16 14:37:53 +00:00
commit e8c9d5ac61
3 changed files with 12 additions and 5 deletions

View File

@ -3,11 +3,6 @@ variables:
TUTOR_PYPI_PACKAGE: tutor-deck
GITHUB_REPO: overhangio/tutor-deck
build-css:
script:
- make scss
stage: build
include:
- project: "community/tutor-ci"
file: "plugin-gitlab-ci.yml"

View File

@ -1,12 +1,20 @@
# https://hatch.pypa.io/latest/how-to/config/dynamic-metadata/
import os
import subprocess
import typing as t
from hatchling.builders.hooks.plugin.interface import BuildHookInterface
from hatchling.metadata.plugin.interface import MetadataHookInterface
HERE = os.path.dirname(__file__)
class CustomBuildHook(BuildHookInterface):
def initialize(self, version, build_data):
# This runs before the build starts
subprocess.check_call(["make", "scss"])
class MetaDataHook(MetadataHookInterface):
def update(self, metadata: dict[str, t.Any]) -> None:
about = load_about()

View File

@ -69,5 +69,9 @@ strict-naming = false
include = [ "/tutordeck", ".hatch_build.py"]
exclude = ["tests*"]
[tool.hatch.build.targets.sdist.hooks.custom]
# Build static assets prior to running sdist
path = ".hatch_build.py"
[tool.hatch.build.targets.wheel]
packages = ["tutordeck"]