remove r/o file attribute
Posted 29 April 2005 - 09:58
Problem: The filesystem i take them from is read only. But after installation they have to be writeable.
Ok, i may loop through all files and call SetFileInfo (...) after installation (in OnMoved).
But is there a better solution to this ?
Posted 29 April 2005 - 14:37
Edited by Taco Bell, 29 April 2005 - 15:03.
Posted 03 May 2005 - 23:19
Posted 20 May 2005 - 20:40
attrib -R C:\foldername\*.* /s
to remove the read-only attribute from all files in C:\foldername and its subfolders. Or, depending on how you do your builds you could issue the command on the files before you build.
Posted 01 June 2005 - 20:31
The batch file also allowd me to seperate files into File Groups that were important for the installation, not the folder srtucture needed in development. For instance, all the *.exe, *.dll, and *.bpl files are in one folder in StarTeam. The batch file allows me to seperate them into three file groups.
This method allows me to control and organize the files in such a way that I do not need to add special code in the install script to slow up or goof up the install process.
Posted 02 June 2005 - 08:24
| nReturn = FindAllFiles( TARGETDIR, "*.*", szResult, RESET );|
while( nReturn = 0 )
GetFileInfo( szResult, FILE_ATTRIBUTE, nvResult, svResult );
if( nvResult & FILE_ATTR_READONLY ) then
SetFileInfo( szResult, FILE_ATTRIBUTE, FILE_ATTR_NORMAL, "" );
nReturn = FindAllFiles( TARGETDIR, "*.*", szResult, CONTINUE );