mirror of
https://github.com/ossrs/srs.git
synced 2025-02-13 11:51:57 +00:00
Script: Remove unused git2unix.sh
This commit is contained in:
parent
b302d766e1
commit
a5727c373a
1 changed files with 0 additions and 26 deletions
|
@ -1,26 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
cat <<END >>/dev/null
|
|
||||||
touch git2unix &&
|
|
||||||
echo "bash `pwd`/git2unix.sh" >git2unix &&
|
|
||||||
chmod +x git2unix &&
|
|
||||||
sudo rm -f /bin/git2unix &&
|
|
||||||
sudo mv git2unix /bin/git2unix
|
|
||||||
END
|
|
||||||
|
|
||||||
dos2unix -V>/dev/null 2>&1
|
|
||||||
ret=$?; if [[ 0 -ne $ret ]]; then
|
|
||||||
echo "dos2unix not found."
|
|
||||||
echo " sudo yum install -y dos2unix"
|
|
||||||
exit $ret
|
|
||||||
fi
|
|
||||||
|
|
||||||
files=`git status|egrep "(modified|new file)"|awk -F ':' '{print $2}'|awk '{print $1}'|egrep "(.hpp$|.cpp$|.cc$|.h$|.c$|.txt$|.sh|.conf$)"`;
|
|
||||||
for file in $files; do
|
|
||||||
dos2unix $file;
|
|
||||||
echo $file|grep ".sh$" >/dev/null 2>&1; EOF_SH=$?
|
|
||||||
if [[ $EOF_SH -ne 0 && -f $file ]]; then
|
|
||||||
echo "chmod -x $file"
|
|
||||||
chmod -x $file;
|
|
||||||
fi
|
|
||||||
done
|
|
Loading…
Reference in a new issue