Skip to content

Commit

Permalink
Yaml 文件扩展名修改为 '.yaml'
Browse files Browse the repository at this point in the history
  • Loading branch information
TakWolf committed Jan 21, 2025
1 parent e4abffc commit 24109dc
Show file tree
Hide file tree
Showing 16 changed files with 8 additions and 8 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions tools/configs/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@
attachments = list[Attachment](get_args(Attachment.__value__))

mapping_file_paths = [
path_define.ark_pixel_mappings_dir.joinpath('2700-27BF Dingbats.yml'),
path_define.ark_pixel_mappings_dir.joinpath('2E80-2EFF CJK Radicals Supplement.yml'),
path_define.ark_pixel_mappings_dir.joinpath('2F00-2FDF Kangxi Radicals.yml'),
path_define.ark_pixel_mappings_dir.joinpath('2700-27BF Dingbats.yaml'),
path_define.ark_pixel_mappings_dir.joinpath('2E80-2EFF CJK Radicals Supplement.yaml'),
path_define.ark_pixel_mappings_dir.joinpath('2F00-2FDF Kangxi Radicals.yaml'),
]

license_configs = {
Expand Down
2 changes: 1 addition & 1 deletion tools/configs/dump.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
class DumpConfig:
@staticmethod
def load() -> dict[FontSize, list['DumpConfig']]:
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('dump-configs.yml').read_bytes())
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('dump-configs.yaml').read_bytes())
dump_configs = {font_size: [] for font_size in configs.font_sizes}
for name, items_data in configs_data.items():
version = json.loads(path_define.fonts_dir.joinpath(name, 'version.json').read_bytes())['version']
Expand Down
2 changes: 1 addition & 1 deletion tools/configs/fallback.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
class FallbackConfig:
@staticmethod
def load() -> dict[FontSize, list['FallbackConfig']]:
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('fallback-configs.yml').read_bytes())
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('fallback-configs.yaml').read_bytes())
fallback_configs = {font_size: [] for font_size in configs.font_sizes}
for config_data in configs_data:
font_size = config_data['font-size']
Expand Down
2 changes: 1 addition & 1 deletion tools/configs/font.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def line_height(self) -> int:
class FontConfig:
@staticmethod
def load(font_size: FontSize) -> 'FontConfig':
file_path = path_define.patch_glyphs_dir.joinpath(str(font_size), 'config.yml')
file_path = path_define.patch_glyphs_dir.joinpath(str(font_size), 'config.yaml')
config_data = yaml.safe_load(file_path.read_bytes())

layout_params = {}
Expand Down
2 changes: 1 addition & 1 deletion tools/configs/update.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def __init__(self, file_name: str | None, copy_list: list[tuple[str, str]]):
class UpdateConfig:
@staticmethod
def load() -> list['UpdateConfig']:
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('update-configs.yml').read_bytes())
configs_data = yaml.safe_load(path_define.assets_dir.joinpath('update-configs.yaml').read_bytes())
update_configs = []
for config_data in configs_data:
name = config_data['name']
Expand Down
2 changes: 1 addition & 1 deletion tools/services/update_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def setup_ark_pixel_glyphs():
if path_define.ark_pixel_mappings_dir.exists():
shutil.rmtree(path_define.ark_pixel_mappings_dir)
for font_size in [10, 12]:
shutil.copyfile(source_unzip_dir.joinpath('assets', 'glyphs', str(font_size), 'config.yml'), path_define.patch_glyphs_dir.joinpath(str(font_size), 'config.yml'))
shutil.copyfile(source_unzip_dir.joinpath('assets', 'glyphs', str(font_size), 'config.yaml'), path_define.patch_glyphs_dir.joinpath(str(font_size), 'config.yaml'))
shutil.copyfile(source_unzip_dir.joinpath('LICENSE-OFL'), font_ark_pixel_dir.joinpath('LICENSE.txt'))
source_unzip_dir.joinpath('assets', 'glyphs').rename(path_define.ark_pixel_glyphs_dir)
source_unzip_dir.joinpath('assets', 'mappings').rename(path_define.ark_pixel_mappings_dir)
Expand Down

0 comments on commit 24109dc

Please sign in to comment.