fixed scripts for dynamic path detection
This commit is contained in:
parent
f2b77f38b4
commit
3227497e45
5 changed files with 67 additions and 10 deletions
|
|
@ -118,12 +118,21 @@ done <<< "$lib_dirs"
|
|||
|
||||
# Check for environment variable dependencies
|
||||
echo -e "${BLUE}Checking for hardcoded paths...${NC}"
|
||||
hardcoded_paths=$(grep -r "g:\\repos\\stock-bot" ./libs 2>/dev/null || true)
|
||||
if [ -n "$hardcoded_paths" ]; then
|
||||
hardcoded_paths_win=$(grep -r "g:\\repos\\stock-bot" ./libs 2>/dev/null || true)
|
||||
hardcoded_paths_unix=$(grep -r "/home/.*/stock-bot" ./libs 2>/dev/null || true)
|
||||
|
||||
if [ -n "$hardcoded_paths_win" ]; then
|
||||
warnings+=("Found hardcoded Windows paths:")
|
||||
while IFS= read -r line; do
|
||||
warnings+=(" - $line")
|
||||
done <<< "$hardcoded_paths"
|
||||
done <<< "$hardcoded_paths_win"
|
||||
fi
|
||||
|
||||
if [ -n "$hardcoded_paths_unix" ]; then
|
||||
warnings+=("Found hardcoded Unix paths:")
|
||||
while IFS= read -r line; do
|
||||
warnings+=(" - $line")
|
||||
done <<< "$hardcoded_paths_unix"
|
||||
fi
|
||||
|
||||
# Summary
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue