On 08/30/2011 02:21 PM, David L. Johnson wrote:
> On 08/30/2011 02:19 PM, Richard Heck wrote:
>> On 08/29/2011 09:14 AM, Sophie Vandenbussche wrote:
>>> Hi everyone!
>>>
>>> I use LyX in a professional linux environment, in shared folders where
>>> 660 rights are automatically given to any created file. When I export
>>> a pdf file (using pdflatex), the created file has 600 permission. I
>>> made a trace of what happens during the saving, and at the end of
>>> everything it makes a chmod 600 on the file.
>>> So, does anyone know how to change that? Or deactivate it?
>>>
>> I've had a look at this, and I don't think it's a LyX-specific thing. I
>> just exported a file, and it's created with 664 permissions. And, so far
>> as I can see, LyX does not do anything to change the permissions. The
>> copying happens at the end of the Buffer::doExport routine, via the call
>> to copyFile(), which is implemented in Exporter.cpp, which calls
>> Mover::copy(), which eventually calls FileName::copyTo, which finally
>> calls QFile::copy(), the static version, to effect the copy. Nowhere
>> there do I see any attempt to change the permissions. So perhaps this is
>> something to do with your Qt installation?
>
> It might also have to do with the global setup that assigns that 660
> permission.  Remember that the export to ___ process starts with a TeX
> file in the /tmp/* directory, which might have different default
> permissions than the user space, pdflatex may preserve those permissions.
>
The copy is done from within LyX, but it may well be that QFile::copy()
attempts to preserve permissions.

Richard


Reply via email to