Эх сурвалжийг харах

actually cd to directory given

Former-commit-id: 4c7b8c80a62af330e59630b6c947eaa1649e2073
Alec Jacobson 8 жил өмнө
parent
commit
997df0c5e3

+ 3 - 2
scripts/autoexplicit.sh

@@ -3,7 +3,8 @@
 while getopts ":C:h" opt; do
   case $opt in
     C)
-      if ! cd "$OPTARG" 2>/dev/null
+      CDIR="$OPTARG"
+      if ! cd "$CDIR" 2>/dev/null
       then
         (>&2 echo "Failed to change directory to $OPTARG")
         exit 1
@@ -44,7 +45,7 @@ while read line; do
   filename=`echo "$symbol" | perl -pe "s#.*?igl::([A-z0-9_:]*).*$'$'#\1#"`
   filename=`echo "$filename" | sed -e "s/::/\//g"`
   #echo "filename = $filename"
-  cpp="$LIBIGL/include/igl/$filename.cpp"
+  cpp="./include/igl/$filename.cpp"
   # append .cpp and check that file exists
   if [ ! -e "$cpp" ]
   then