From 4608f3975eade7b9b516b8b6658cd08bf0b2c5cc Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Sun, 2 Feb 2025 15:31:20 -0500 Subject: bsgrep: make -r use . if no files on command line. --- bsgrep | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bsgrep') diff --git a/bsgrep b/bsgrep index ad89e29..0f33e16 100755 --- a/bsgrep +++ b/bsgrep @@ -92,6 +92,7 @@ if($self =~ /join/) { } if($opt{r}) { + @ARGV = (".") unless @ARGV; for(@ARGV) { if(-d $_) { find({ @@ -248,7 +249,8 @@ that contain matches (same as B). =item -r Recursively read all files under each directory, following symlinks -only if they're on the command line (same as B). +only if they're on the command line. If no files or directories are +given, reads the current directory. Same as B. =item -v -- cgit v1.2.3