# HG changeset patch # User Chayoung You # Date 1552288280 25200 # Node ID 157853e84d2772b027d15f78735a2e3fb64b4112 # Parent ac9adbec887bc949b505101f09d7a90a5c04f285 Fix listing files with spaces for cscope diff -r ac9adbec887b -r 157853e84d27 plat/unix/update_scopedb.sh --- a/plat/unix/update_scopedb.sh Wed Dec 19 20:49:22 2018 +0900 +++ b/plat/unix/update_scopedb.sh Mon Mar 11 00:11:20 2019 -0700 @@ -74,15 +74,19 @@ if [ -n "${FILE_LIST_CMD}" ]; then if [ "${PROJECT_ROOT}" = "." ]; then - eval "$FILE_LIST_CMD" > "${DB_FILE}.files" + eval "$FILE_LIST_CMD" | while read -r l; do + echo "\"${l}\"" + done > "${DB_FILE}.files" else # If using a tags cache directory, use absolute paths eval "$FILE_LIST_CMD" | while read -r l; do - echo "${PROJECT_ROOT%/}/${l}" + echo "\"${PROJECT_ROOT%/}/${l}\"" done > "${DB_FILE}.files" fi else - find . -type f ! -name ${DB_FILE} > "${DB_FILE}.files" + find . -type f ! -name ${DB_FILE} | while read -r l; do + echo "\"${l}\"" + done > "${DB_FILE}.files" fi CSCOPE_ARGS="${CSCOPE_ARGS} -i ${DB_FILE}.files"