Build an eDoc Reader for Your iPod, Part 3
Subject:   You may want to add quotes to that shell script...
Date:   2005-01-07 22:42:38
From:   philippec
Great article! But in, you may want to add quotes to these lines:


export CLASSPATH="$CLASSPATH:$here/../Resources/log4j-1.2.8.jar"
export CLASSPATH="$CLASSPATH:$here/../Resources/PDFBox-0.6.7a.jar"

exec "$here/$cmd"

I named my program "Pod Reader", but any non-standard character in your path will cause it to fail.

Full Threads Oldest First

Showing messages 1 through 1 of 1.

  • Matthew Russell photo You may want to add quotes to that shell script...
    2005-01-08 00:41:16  Matthew Russell | O'Reilly AuthorO'Reilly Blogger [View]

    That is an excellent point. It definitely is a good habit to use those double quotes (something I'm guilty of not always doing), and this is an excellent example of why that's so.

    I have a habit of not using spaces or nonstandard characters in paths or filenames, so I didn't use the double quotes. As you pointed out, however, that can possibly lead to portability or maintenance problems.