From 3f0331a307f448a416727837a64416c274d6f917 Mon Sep 17 00:00:00 2001 From: "Azalea (on HyDEV-Daisy)" Date: Sun, 10 Apr 2022 04:38:20 -0400 Subject: [PATCH] [+] Get ascii lines --- hyfetch/neofetch_util.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/hyfetch/neofetch_util.py b/hyfetch/neofetch_util.py index 6977c588..cb99be63 100644 --- a/hyfetch/neofetch_util.py +++ b/hyfetch/neofetch_util.py @@ -11,3 +11,13 @@ def get_command_path() -> str: :return: Command path """ return pkg_resources.resource_filename(__name__, 'scripts/neofetch_mod.sh') + + +def get_distro_ascii_lines() -> int: + """ + Get how many lines are in the distro ascii + + :return: Number of lines + """ + out = check_output([get_command_path(), "print_ascii"]) + return len(out.decode().strip().split('\n'))