From d2fe3c35801eebf8e65dd402169e19261af951f1 Mon Sep 17 00:00:00 2001 From: Alex Karle Date: Mon, 19 Sep 2022 13:00:45 -0400 Subject: [PATCH] bin: Add no9 function to strip plan9 from PATH This is helpful when I'm trying to get a command to share with coworkers (i.e. using system sed(1)). --- bin/no9 | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 bin/no9 diff --git a/bin/no9 b/bin/no9 new file mode 100755 index 0000000..b6e175d --- /dev/null +++ b/bin/no9 @@ -0,0 +1,10 @@ +#!/bin/sh +# no9 -- opposite of 9 (strip plan9 tools from path) +# +# helpful to spawn a shell with system tools for sharing with others +# +# % no9 bash -l +# $ which rc # empty +PATH=$(echo $PATH | sed -e "s@$PLAN9/bin@@g" -e 's/::/:/' -e 's/:$//') +export PATH +exec "$@" -- libgit2 1.1.1