xboard-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XBoard-devel] git issues


From: Michel Van den Bergh
Subject: Re: [XBoard-devel] git issues
Date: Fri, 20 Nov 2009 17:51:17 +0100
User-agent: Thunderbird 2.0.0.23 (X11/20090817)

address@hidden wrote:
It think the last alternative would be what is customary provided the
user specific config file is in a standard location. If the user wants to
put the config file in an exotic location then it would be ok I think to
leave it up to him to ensure that this is possible.

By this you mean we should create ~/.config and ~/.config/xboard if they
are not there, to write ~/.config/xboard/xboard.conf? Perhaps using
~/.xboardrc is not such a bad idea after all...

I have a Linux question anyway: I am now at a stage where redefining the
main settings file (where the save will take place) from within another
one (rather than from the command line). This required a subtle change in
behavior, because old behavior was that an expanded path name was written
back to the settingsFileName after parsing was complete, thus overwriting
anything that had changed during parsing. I now write back the expanded
path name before parsing, but after the file has been successfully opened.

This works to redirect the save file to ./xboard.ini, but NOT to
~/xboard.ini. Apparently the ~ is not a valid OS filename, but interpreted
by the shell? I tried using the function ExpandPathName onto the settings
file name, but that does not seem so help either. It keeps complaining
that it could not write "~/xboard.ini".

How should this be handled?



Some googling reveals that this should be handled by the function
wordexp which is part of libc.

I tried it with ~/xboard.ini and it does indeed work.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]