From d41a302e443e63e296ca65c257084a3c05debe3f Mon Sep 17 00:00:00 2001 From: Azalea <22280294+hykilpikonna@users.noreply.github.com> Date: Thu, 16 May 2024 01:33:30 +0800 Subject: [PATCH] [F] Fix #286: Termux missing /usr/bin/env --- hyfetch/neofetch_util.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hyfetch/neofetch_util.py b/hyfetch/neofetch_util.py index f9f13ee1..a5d820db 100644 --- a/hyfetch/neofetch_util.py +++ b/hyfetch/neofetch_util.py @@ -245,7 +245,8 @@ def run_neofetch_cmd(args: str, pipe: bool = False) -> str | None: Run neofetch command """ if platform.system() != 'Windows': - full_cmd = ['/usr/bin/env', 'bash', get_command_path(), *shlex.split(args)] + bash = ['/usr/bin/env', 'bash'] if Path('/usr/bin/env').is_file() else [shutil.which('bash')] + full_cmd = [*bash, get_command_path(), *shlex.split(args)] else: cmd = get_command_path().replace("\\", "/").replace("C:/", "/c/")