aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorparker <contact@pkrm.dev>2025-09-09 23:05:44 -0500
committerparker <contact@pkrm.dev>2025-09-09 23:05:44 -0500
commit13c168b19dab7bb24fdad2234c034180f135b37d (patch)
tree04c51c62110607d726be3ae0040335c78252919a
parent2c328b0622aea8506d94d0ef7ce2d6b17c764198 (diff)
update pip detection and package installation
-rwxr-xr-xlinklogger.sh11
1 files changed, 9 insertions, 2 deletions
diff --git a/linklogger.sh b/linklogger.sh
index 6065479..46401ab 100755
--- a/linklogger.sh
+++ b/linklogger.sh
@@ -27,9 +27,9 @@ function check_python_version() {
fi
}
-# Function to check that pip is installed
+# Function to check if pip is installed
function check_pip_installed() {
- if ! command -v pip &> /dev/null; then
+ if ! $PYTHON_CMD -m pip --version &> /dev/null; then
printf "${RED}Pip is not installed. Please install Pip before proceeding.${NC}\n"
exit 1
fi
@@ -52,6 +52,13 @@ if [[ "$OSTYPE" == "linux-gnu"* ]] || [[ "$OSTYPE" == "darwin"* ]]; then
check_yarn_installed
printf "${GREEN}Yarn is installed.${NC}\n"
+ # Install the API dependencies
+ if [[ "$OSTYPE" == "linux-gnu"* ]]; then
+ $PYTHON_CMD -m pip install --break-system-packages -r requirements.txt
+ else
+ $PYTHON_CMD -m pip install -r requirements.txt
+ fi
+
# Install the UI dependencies
printf "${GREEN}Installing UI dependencies...${NC}\n"
cd app || { printf "${RED}Failed to enter 'app' directory. Exiting.${NC}\n"; exit 1; }