← Về thư mục
scripts/import_bioskills.py
- _git_environment · function · L29-L35 — def _git_environment() -> dict[str, str]
- _sha256 · function · L38-L43 — def _sha256(path: Path) -> str
- _checkout_commit · function · L46-L54 — def _checkout_commit(source: Path) -> str
- _validate_checkout · function · L57-L123 — def _validate_checkout(source: Path, expected_commit: str) -> None
- _selected_tree_entries · function · L126-L193 — def _selected_tree_entries(source: Path, commit: str) -> list[tuple[str, str, str]]
- _materialize_pinned_tree · function · L196-L252 — def _materialize_pinned_tree(source: Path, commit: str, destination: Path) -> None
- _frontmatter_value · function · L255-L284 — def _frontmatter_value(lines: list[str], key: str) -> str
- _without_top_level_frontmatter_fields · function · L287-L319 — def _without_top_level_frontmatter_fields( lines: list[str], fields: frozenset[str] ) -> list[str]
- _nested_metadata_scalar_lines · function · L322-L327 — def _nested_metadata_scalar_lines(key: str, value: str) -> list[str]
- _canonical_skill_name · function · L330-L334 — def _canonical_skill_name(value: str) -> str
- _compatibility_rewrites · function · L349-L364 — def _compatibility_rewrites(text: str) -> str
- _convert_document · function · L367-L406 — def _convert_document( raw: str, category: str, commit: str = UPSTREAM_COMMIT ) -> tuple[str, str]
- _skill_sources · function · L409-L425 — def _skill_sources(source: Path) -> list[Path]: #
glob("*/*/SKILL.md") is case-insensitive on macOS and case-sensitive on # Linux: a mis-cased upstream skill.md is silently imported -- and the # returned Path reports its name as SKILL.md, so it is renamed too -- on a # Mac, while the same command trips the count check on CI. Matching the name # explicitly makes the two platforms agree on what the pin contains.
- import_collection · function · L428-L478 — def import_collection( source: Path, destination: Path, *, expected_commit: str = UPSTREAM_COMMIT, expected_skills: int = EXPECTED_SKILLS, ) -> dict[str, object]
- _convert_tree · function · L481-L654 — def _convert_tree( source: Path, destination: Path, final: Path, sources: list[Path], commit: str, ) -> dict[str, object]
- verify_collection · function · L664-L720 — def verify_collection( destination: Path, *, expected_commit: str = UPSTREAM_COMMIT, expected_skills: int = EXPECTED_SKILLS, ) -> list[str]
- main · function · L723-L760 — def main() -> int