summaryrefslogtreecommitdiff
path: root/rc/bin/patch/diff
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2022-05-22 17:27:31 +0000
committerOri Bernstein <ori@eigenstate.org>2022-05-22 17:27:31 +0000
commita59e61a6a4e11e0256da0d209afa38ccacd460a2 (patch)
tree549dfadf95e33c523a8d097e000e687f496e2686 /rc/bin/patch/diff
parent23f8872bc10fbe9ffd2b0067db1f91d8eaaabb40 (diff)
patch(1): remove bell labs patch scripts
bell labs is dead, and nobody is listening; 9front has our own patch submission proces.
Diffstat (limited to 'rc/bin/patch/diff')
-rwxr-xr-xrc/bin/patch/diff45
1 files changed, 0 insertions, 45 deletions
diff --git a/rc/bin/patch/diff b/rc/bin/patch/diff
deleted file mode 100755
index 944b5231b..000000000
--- a/rc/bin/patch/diff
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/bin/rc
-# patch/diff [-w] patch-name
-rfork e
-fn usage {
- echo 'usage: patch/diff [-bmnwz] patch-name' >[1=2]
- exit usage
-}
-
-dopts=(-c)
-while (! ~ $#* 0 && ~ $1 -*) {
- switch ($1) {
- case -[bmnw]
- dopts=($dopts $1)
- case -z
- dopts=()
- case *
- usage
- }
- shift
-}
-if(! ~ $#* 1)
- usage
-
-if(! test -d /n/sources/patch){
- rfork n
- 9fs sources
-}
-
-if(! test -d /n/sources/patch/$1){
- echo 'no such patch' /n/sources/patch/$1 >[1=2]
- exit nopatch
-}
-
-builtin cd /n/sources/patch/$1 || exit nopatch
-if(! patch/okay .){
- echo 'bad patch: '$status >[1=2]
- exit badpatch
-}
-
-d=/n/sources/patch/$1
-fn xxx {
- echo $1
- diff $dopts $2.orig $d/$2 | sed 's/^/ /'
-}
-cat files | sed 's/^/xxx /' | rc