aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/set-eol-style.sh
blob: 281769ef2fa75e90a8f90c6d71d0a71798dcacce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

set_eol_style()
{
    IFS=$'\n'
    for file in `find . -iname \*\.$1`; do
        eolstyle=`svn propget svn:eol-style $file`
        if [ -z "${eolstyle}" -o "${eolstyle}" != "native" ]; then
            svn propset svn:eol-style native $file
        fi
    done
}

EXTENSIONS="cs ini example txt sql xml"

for ext in ${EXTENSIONS}; do
    set_eol_style $ext
done