Subversion Repositories HelenOS

Rev

Rev 3022 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3022 Rev 4055
Line -... Line 1...
-
 
1
#!/bin/bash
-
 
2
 
1
# by Alf
3
# by Alf
2
# This script solves malfunction of symlinks in cygwin
4
# This script solves malfunction of symlinks in cygwin
3
# 
5
# 
4
# Download sources from repository and than run this script to correct symlinks 
6
# Download sources from repository and than run this script to correct symlinks 
5
#   to be able compile project
7
#   to be able compile project
Line 13... Line 15...
13
fi
15
fi
14
 
16
 
15
for linkName in `find . ! -iwholename '.*svn*' ! -type d -print`; do
17
for linkName in `find . ! -iwholename '.*svn*' ! -type d -print`; do
16
  if head -n 1 $linkName | grep '^link' > /dev/null; then
18
    if head -n 1 $linkName | grep '^link' > /dev/null; then
17
     linkTarget=`head -n 1 $linkName | sed 's/^link //'`
19
        linkTarget=`head -n 1 $linkName | sed 's/^link //'`
18
     echo $linkName " -->" $linkTarget
20
        echo $linkName " -> " $linkTarget
19
     rm $linkName
21
        rm $linkName
20
     ln -s "$linkTarget" "$linkName"
22
        ln -s "$linkTarget" "$linkName"
21
   fi  
23
    fi  
22
done
24
done