diff --git a/strip_solutions.py b/strip_solutions.py index 4e1c57f5..6751c6e0 100644 --- a/strip_solutions.py +++ b/strip_solutions.py @@ -4,6 +4,8 @@ import os from shutil import copytree, ignore_patterns +KERNELNAME = "DMSC-School" + BASE_CELL = { "cell_type": "code", "execution_count": None, @@ -56,6 +58,10 @@ def clean(filepath, destination, add_mpl_widget_cell=False): out.append(cell) obj["cells"] = out + # Update kernelspec name + obj["metadata"]["kernelspec"]["display_name"] = KERNELNAME + obj["metadata"]["kernelspec"]["name"] = KERNELNAME + outfile = os.path.join(destination, filepath) with open(outfile, "w", encoding="utf-8") as f: json.dump(obj, f, indent=1) @@ -89,6 +95,8 @@ def clean(filepath, destination, add_mpl_widget_cell=False): ".python-version", "requirements.in", "typos.toml", + "pixi.toml", + "pixi.lock", ), dirs_exist_ok=True, )