forked from pool/patch
20 lines
305 B
Plaintext
20 lines
305 B
Plaintext
$ mkdir d
|
|
$ cd d
|
|
|
|
$ mkdir sub
|
|
$ echo 1 > f
|
|
$ echo 2 > f.new
|
|
$ diff -Nu f f.new > f.diff
|
|
$ mv f.new f
|
|
$ echo 3 > f.new
|
|
$ diff -Nu f f.new >> f.diff
|
|
$ rm f.new
|
|
$ echo 1 > f
|
|
$ chmod a=r f
|
|
$ strace -o ../log patch -p0 --backup < f.diff
|
|
> patching file f
|
|
> patching file f
|
|
|
|
$ cd ..
|
|
$ rm -rf d
|