修正bug
parent
e3c7f529b3
commit
a264e86c71
3
find.sh
3
find.sh
|
|
@ -1,10 +1,9 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
results=$(find . -name '*_1.txt')
|
results=$(find . -name '*_1.*')
|
||||||
for result in $results;do
|
for result in $results;do
|
||||||
originFile=$(echo $result | sed 's/\(.*\)_1\(\..*\)/\1\2/g')
|
originFile=$(echo $result | sed 's/\(.*\)_1\(\..*\)/\1\2/g')
|
||||||
if [ -f $originFile ];then
|
if [ -f $originFile ];then
|
||||||
echo "$originFile exist!"
|
|
||||||
same=$(diff $result $originFile)
|
same=$(diff $result $originFile)
|
||||||
if [ ! -n "$same" ];then
|
if [ ! -n "$same" ];then
|
||||||
echo "file $result same with $originFile"
|
echo "file $result same with $originFile"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue