diff options
author | stanley lieber <stanley.lieber@gmail.com> | 2014-04-11 13:19:18 -0400 |
---|---|---|
committer | stanley lieber <stanley.lieber@gmail.com> | 2014-04-11 13:19:18 -0400 |
commit | 4ae2015d865a481829b949a171c055c3ec22fa98 (patch) | |
tree | b1256e33503442f6127d809bba61a9c93bd66952 /rc/bin/newt | |
parent | 794197adb16da0f7644cc8b56830316682b89011 (diff) | |
download | plan9front-4ae2015d865a481829b949a171c055c3ec22fa98.tar.xz |
newt: add 'kf' command to grep $home/lib/newsgroups for group names
Diffstat (limited to 'rc/bin/newt')
-rwxr-xr-x | rc/bin/newt | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/rc/bin/newt b/rc/bin/newt index 7d6e8ab8e..af5c15b3d 100755 --- a/rc/bin/newt +++ b/rc/bin/newt @@ -75,7 +75,7 @@ fn k{ kmnt=`{echo $mnt | sed 's/\//\\\//g'} f $mnt/$* | grep -v -e '\/([0-9]+|article|body|header|post|xover)$' | - sed 's/^'$"kmnt'\// g /g' | + sed 's/^'$"kmnt'\// g /g' | sort } fn nshift{ shift; echo $* } @@ -88,6 +88,7 @@ g ... go to specified group h print message headlines help print this help message k ... list sub-groups under specified group +kf ... grep $home/lib/newsgroups for regexp l jump to last message n next p print message with minimal headers @@ -194,6 +195,9 @@ while(){ k $group case k' '* k `{nshift $cmd | sed 's/\./\//g'} + case kf' '* + grep -e `{nshift $cmd} $home/lib/newsgroups | + sed 's/^/ g /g' case l post=$posts($#posts) printp $post |