From de515819a871ce54ad3f31ad34b8e19fc196dbc2 Mon Sep 17 00:00:00 2001 From: Alex Karle Date: Sun, 7 Jan 2024 04:25:59 +0000 Subject: [PATCH] plan9: Add git plumbing rules and scripts --- plan9/bin/rc/Glog | 2 ++ plan9/bin/rc/gd | 2 ++ plan9/bin/rc/gds | 2 ++ plan9/lib/plumbing | 4 ++++ 4 files changed, 10 insertions(+) create mode 100755 plan9/bin/rc/Glog create mode 100755 plan9/bin/rc/gd create mode 100755 plan9/bin/rc/gds diff --git a/plan9/bin/rc/Glog b/plan9/bin/rc/Glog new file mode 100755 index 0000000..a934ab6 --- /dev/null +++ b/plan9/bin/rc/Glog @@ -0,0 +1,2 @@ +#!/bin/rc +git/log -s | plumb -i -d edit -a 'action=showdata filename=Glog' diff --git a/plan9/bin/rc/gd b/plan9/bin/rc/gd new file mode 100755 index 0000000..3bf71b8 --- /dev/null +++ b/plan9/bin/rc/gd @@ -0,0 +1,2 @@ +#!/bin/rc +git/diff diff --git a/plan9/bin/rc/gds b/plan9/bin/rc/gds new file mode 100755 index 0000000..a5ba9c8 --- /dev/null +++ b/plan9/bin/rc/gds @@ -0,0 +1,2 @@ +#!/bin/rc +git/diff -s diff --git a/plan9/lib/plumbing b/plan9/lib/plumbing index eb378fe..f782e07 100644 --- a/plan9/lib/plumbing +++ b/plan9/lib/plumbing @@ -5,3 +5,7 @@ browser = mothra include basic +# sha1's to git +type is text +data matches '[a-f0-9][a-f0-9][a-f0-9][a-f0-9][a-f0-9][a-f0-9]+' +plumb start rc -c 'cd '$wdir' && git/export '$0' >[2=1] | plumb -i -d edit -a ''action=showdata filename=/'$wdir'/'$0'''' -- libgit2 1.1.1