File: diffcp

package info (click to toggle)
vrweb 1.5-5.1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 15,124 kB
  • ctags: 27,485
  • sloc: cpp: 134,333; ansic: 95,670; sh: 1,072; asm: 712; makefile: 610; pascal: 536; perl: 347; csh: 26
file content (19 lines) | stat: -rwxr-xr-x 250 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# diffcp by Till Vollmer this is used by WAVEMASTER
# V1.0
# 
#!/bin/sh
cd .. 
if [ ! -f $1 ]
then 
co $1
fi 
if [ -f $2 ] &&  diff $1 $2 > /dev/null 2>&1
then
echo "Files $1 and $2 do not differ"
else
echo "Copying $1 to $2"
rm -rf $2
cp $1 $2
fi