Package the standalone NERD font

This commit is contained in:
Kovid Goyal
2024-07-02 19:08:52 +05:30
parent 15af20fa31
commit 71f96b3c83
2 changed files with 4 additions and 1 deletions

View File

@@ -54,11 +54,13 @@ class TestBuild(BaseTest):
self.assertGreater(len(names), 8)
def test_filesystem_locations(self) -> None:
from kitty.constants import local_docs, logo_png_file, shell_integration_dir, terminfo_dir
from kitty.constants import fonts_dir, local_docs, logo_png_file, shell_integration_dir, terminfo_dir
zsh = os.path.join(shell_integration_dir, 'zsh')
self.assertTrue(os.path.isdir(terminfo_dir), f'Terminfo dir: {terminfo_dir}')
self.assertTrue(os.path.exists(logo_png_file), f'Logo file: {logo_png_file}')
self.assertTrue(os.path.exists(zsh), f'Shell integration: {zsh}')
nsfm = os.path.join(fonts_dir, 'SymbolsNerdFontMono-Regular.ttf')
self.assertTrue(os.path.exists(nsfm), f'Logo file: {nsfm}')
def is_executable(x):
mode = os.stat(x).st_mode

View File

@@ -1742,6 +1742,7 @@ def package(args: Options, bundle_type: str, do_build_all: bool = True) -> None:
shutil.copy2('logo/beam-cursor.png', os.path.join(libdir, 'logo'))
shutil.copy2('logo/beam-cursor@2x.png', os.path.join(libdir, 'logo'))
shutil.copytree('shell-integration', os.path.join(libdir, 'shell-integration'), dirs_exist_ok=True)
shutil.copytree('fonts', os.path.join(libdir, 'fonts'), dirs_exist_ok=True)
allowed_extensions = frozenset('py glsl so'.split())
def src_ignore(parent: str, entries: Iterable[str]) -> List[str]: