[izpack-devel] Dumb Variable Question (FILE_SEPARATOR)

Hal Vaughan hal at thresholddigital.com
Tue Jan 22 08:11:35 CET 2008


On Tuesday 22 January 2008, Dennis Reil wrote:
> I think, you'll have to use curly braces around variable names like
> ${INSTALL_PATH}${FILE_SEPARATOR}settings.cfg

Yes -- works perfectly!

One quick answer and now that whole project is done and out of the way.

Thanks!

Hal

> -----Ursprüngliche Nachricht-----
> Von: izpack-devel-bounces at lists.berlios.de
> [mailto:izpack-devel-bounces at lists.berlios.de] Im Auftrag von Hal
> Vaughan Gesendet: Dienstag, 22. Januar 2008 04:37
> An: izpack-devel at lists.berlios.de
> Betreff: [izpack-devel] Dumb Variable Question (FILE_SEPARATOR)
>
> Sorry to bother the list but I'm short on time and want to get a
> hobby project that's been on the back burner out of the way.
>
> I know I can use the variable $FILE_SEPARATOR so I get the right
> character for different platforms, but if it is followed by text,
> then it's not parsed.  Here's the path in *nix:
>
> /home/user/MyProgram/settings.cfg
>
> In Windows it would be:
>
> C:\Program Files\MyProgram\settings.cfg
>
> I can use this:
>
> $INSTALL_PATH/settings.cfg
>
> and it works on one OS, but if I try:
>
> $INSTALL_PATH$FILE_SEPARATORsettings.cfg
>
> it won't parse, just as I would not expect it to.
>
> How can I throw in the file separator character into a file like this
> without having to do different versions of the file for each OS?
>
> Thanks!
>
> Hal
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel




More information about the izpack-devel mailing list