669e7c32a2
We follow the rule of not putting generated files under version control, but that means drawing in additional build-time dependencies. We can reduce those when building from a released tarball by generating the stylesheets at dist time though, so do that. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/150>
14 lines
380 B
Python
14 lines
380 B
Python
#!/usr/bin/env python3
|
|
|
|
import os
|
|
from pathlib import PurePath
|
|
import subprocess
|
|
|
|
sourceroot = os.environ.get('MESON_SOURCE_ROOT')
|
|
distroot = os.environ.get('MESON_DIST_ROOT')
|
|
|
|
stylesheet_path = PurePath('data/gnome-classic.css')
|
|
src = PurePath(sourceroot, stylesheet_path.with_suffix('.scss'))
|
|
dst = PurePath(distroot, stylesheet_path)
|
|
subprocess.call(['sassc', '-a', src, dst])
|