1#!/bin/sh - 2# 3# Copyright (c) 1991, 1993 4# The Regents of the University of California. All rights reserved. 5# 6# %sccs.include.proprietary.sh% 7# 8# @(#)diff3.sh 8.1 (Berkeley) 06/06/93 9# 10 11e= 12case $1 in 13-*) 14 e=$1 15 shift;; 16esac 17if test $# = 3 -a -f $1 -a -f $2 -a -f $3 18then 19 : 20else 21 echo usage: diff3 file1 file2 file3 1>&2 22 exit 23fi 24trap "rm -f /tmp/d3[ab]$$" 0 1 2 13 15 25diff $1 $3 >/tmp/d3a$$ 26diff $2 $3 >/tmp/d3b$$ 27/usr/libexec/diff3 $e /tmp/d3[ab]$$ $1 $2 $3 28