From 9823ba0e991abcfb17bb9c1dcfe094fdac16f487 Mon Sep 17 00:00:00 2001 From: ATATC Date: Fri, 10 May 2024 10:17:30 -0400 Subject: [PATCH 1/2] Bug fixed: replicant interpreter cannot find site-packages. (#146) --- scripts/python-install.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/python-install.sh b/scripts/python-install.sh index 4bc588fe..c58d245c 100644 --- a/scripts/python-install.sh +++ b/scripts/python-install.sh @@ -29,5 +29,6 @@ execute_root "apt" "install" "-y" "python3.12-tk" echo "Creating Virtual Environment..." execute_root "python3.12" "-m" "venv" "/usr/local/leads/venv" echo "Creating Soft Links..." -execute_root "ln" "/usr/local/leads/venv/bin/python" "/bin/python-leads" -execute_root "ln" "/usr/local/leads/venv/bin/pip" "/bin/pip-leads" \ No newline at end of file +echo "#!/bin/sh" > "/bin/python-leads" +echo '/usr/local/leads/venv/bin/python "$@"' >> "/bin/python-leads" +execute_root "ln" "-s" "/usr/local/leads/venv/bin/pip" "/bin/pip-leads" \ No newline at end of file From 8ce9068950a2f292032ed8cc3f9c54164acc91a1 Mon Sep 17 00:00:00 2001 From: ATATC Date: Fri, 10 May 2024 10:18:25 -0400 Subject: [PATCH 2/2] Added a shortcut for the main entry. --- scripts/setup.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/setup.sh b/scripts/setup.sh index 89f552b5..0c1885ff 100644 --- a/scripts/setup.sh +++ b/scripts/setup.sh @@ -26,4 +26,8 @@ echo "Cleaning up..." execute_root "rm" "python-install.sh" echo "Installing dependencies..." execute "pip-leads" "install" "Pillow" "PySDL2" "customtkinter" "gpiozero" "lgpio" "pynmea2" "pynput" "pysdl2-dll" "pyserial" "leads" -execute "python-leads" "-m" "leads_vec" "info" \ No newline at end of file +echo "Creating Shortcut..." +echo "#!/bin/sh" > "/bin/leads_vec" +echo 'python-leads -m leads_vec "$@"' >> "/bin/leads_vec" +echo "Verifying..." +execute "leads_vec" "info" \ No newline at end of file