Bertalan Fodor writes:

> in cygwin environment the home directory is often
> /cygdrive/c/Documents and Settings/myname.
> This causes a problem in updmap, because $cnfFile is not written
> always as $cnfFile. Maybe $shortCnfFile also.
> In listmaps() and listavailablemaps() it is not written like that.

How's this patch?

Jan.

--- texk/tetex/ChangeLog.orig   2005-03-10 15:03:01 +0100
+++ texk/tetex/ChangeLog        2005-03-10 15:02:49 +0100
@@ -1,3 +1,7 @@
+2005-03-10  Jan Nieuwenhuizen  <[EMAIL PROTECTED]>
+
+       * updmap: Bugfix: quote $cnfFile and $cnfFileShort.
+
 Sat Dec 18 14:19:43 CET 1999 te
        * added manpages for epstopdf and dvi2fax (contributed by "James
        R. Van Zandt" <[EMAIL PROTECTED]>)
--- texk/tetex/updmap.orig      2005-03-10 14:58:50 +0100
+++ texk/tetex/updmap   2005-03-10 15:00:58 +0100
@@ -860,7 +860,7 @@
 setupCfgFile()
 {
   case "$cnfFile" in
-    "") cnfFile=`locateWeb2c $cnfFileShort`
+    "") cnfFile=`locateWeb2c "$cnfFileShort"`
         case "$cnfFile" in
           "") abort "config file $cnfFileShort not found"
         esac;;
@@ -1002,7 +1002,7 @@
 ###############################################################################
 listMaps()
 {
-  egrep '^(#! *)?(Mixed)?Map' $cnfFile
+  egrep '^(#! *)?(Mixed)?Map' "$cnfFile"
 }
 
 ###############################################################################
@@ -1017,7 +1017,7 @@
   OLDIFS=$IFS
   IFS='
 '
-  for line in `egrep '^(#! *)?(Mixed)?Map' $cnfFile`; do
+  for line in `egrep '^(#! *)?(Mixed)?Map' "$cnfFile"`; do
     m=`echo "$line" | sed '[EMAIL PROTECTED]   ]*$@@; [EMAIL PROTECTED]        
]@@'`
     kpsewhich --format=map "$m" >/dev/null && echo "$line"
   done
@@ -1312,7 +1312,7 @@
 
   if test -n "$cfgmaint"; then
     if test -z "$cfgparam"; then
-      co=`$TEXMFMAIN/texconfig/tcfmgr --tmp $tmpdir --cmd co --file 
$cnfFileShort`
+      co=`$TEXMFMAIN/texconfig/tcfmgr --tmp $tmpdir --cmd co --file 
"$cnfFileShort"`
       test $? = 0 || cleanup
       set x $co; shift
       id=$1; cnfFile=$3; orig=$4
@@ -1324,7 +1324,7 @@
 
     case "$cmd" in
       edit)
-        ${VISUAL-${EDITOR-vi}} $cnfFile;;
+        ${VISUAL-${EDITOR-vi}} "$cnfFile";;
       setoption)
         setOption "$setoptionOpt" "$setoptionVal";;
       enable)

-- 
Jan Nieuwenhuizen <[EMAIL PROTECTED]> | GNU LilyPond - The music typesetter
http://www.xs4all.nl/~jantien       | http://www.lilypond.org

Reply via email to