Revision 10724,
303 bytes
checked in by ghudson, 27 years ago
(diff) |
This commit was generated by cvs2svn to compensate for changes in r10723,
which included commits to RCS files with non-trunk default branches.
|
Line | |
---|
1 | : mv-if-diff file1 file2 |
---|
2 | : move file1 to file2 if file1 and file2 are different. |
---|
3 | |
---|
4 | if test $# -lt 2 ; then |
---|
5 | echo "usage: $0 file1 file2" |
---|
6 | echo "move file1 to file2 if file1 and file2 are different." |
---|
7 | exit 1 |
---|
8 | fi |
---|
9 | if cmp $1 $2 >/dev/null 2>&1; then |
---|
10 | echo "File $2 not changed." |
---|
11 | rm -f tmp |
---|
12 | else |
---|
13 | mv $1 $2 |
---|
14 | fi |
---|
Note: See
TracBrowser
for help on using the repository browser.