[fpc-devel]Linux troubles
    Yet Another Geek 
    yetanothergeek at yahoo.com
       
    Thu Aug 22 09:06:47 CEST 2002
    
    
  
> for i in [A-Z]*; do mv $i `echo $i | tr A-Z a-z`;
done
Careful -  
 if you already have files named
 "IMPORTANT.FILE" and "important.file" 
 then the existing "important.file"
 will get clobbered!
(You may want to use the -i option to mv)
Or you can do it recursively:
#!/bin/bash
for OLD in `find -type f -name '*[A-Z]*'`
do 
  DIR=`dirname $OLD`
  NEW=`basename $OLD | tr A-Z a-z`
  echo $OLD $DIR/$NEW # <- Just testing
# uncomment for the real thing:
# mv -i $OLD $DIR/$NEW
done
... will rename all files in all directories 
under the current directory - BE CAREFUL!!!
I really don't think you need to rename all
your files, however, you just need to make 
sure the case matches exactly in all your
search path, etc.
Another option:
The include directive can also contain an 
absolute or relative path to the file, 
for example:
{$INCLUDE /home/baikov/projects/INCLUDE/defs.inc}
... or whatever the correct path would be.
This is certainly not an elegant or portable solution,
but it might help to find the problem.
__________________________________________________
Do You Yahoo!?
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com
    
    
More information about the fpc-devel
mailing list