From 71f96b3c833a2e8bc1109ac25d43d3f2c8af9931 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 2 Jul 2024 19:08:52 +0530 Subject: [PATCH] Package the standalone NERD font --- kitty_tests/check_build.py | 4 +++- setup.py | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/kitty_tests/check_build.py b/kitty_tests/check_build.py index 025b35656..086175558 100644 --- a/kitty_tests/check_build.py +++ b/kitty_tests/check_build.py @@ -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 diff --git a/setup.py b/setup.py index f2f6cc5de..9847a51fa 100755 --- a/setup.py +++ b/setup.py @@ -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]: