MCPcopy Create free account
hub / github.com/BYVoid/OpenCC / _write_resource_zip

Function _write_resource_zip

python/tests/test_cli.py:46–51  ·  view source on GitHub ↗
(path: pathlib.Path)

Source from the content-addressed store, hash-verified

44
45
46def _write_resource_zip(path: pathlib.Path) -> None:
47 with zipfile.ZipFile(path, 'w', compression=zipfile.ZIP_STORED) as archive:
48 archive.writestr('s2twp.json', _TEXT_ZIP_CONFIG)
49 archive.writestr('STPhrases.txt', "打印机\t印表機\n")
50 archive.writestr('STCharacters.txt', "鼠\t鼠\n标\t標\n")
51 archive.writestr('TWPhrases.txt', "鼠標\t滑鼠\n")
52
53
54def _write_custom_config(config_path: pathlib.Path, dict_path: pathlib.Path) -> None:

Callers 2

Calls

no outgoing calls

Tested by

no test coverage detected