GNU bug report logs - #27763
egrep.sh: grep missing path

Previous Next

Package: grep;

Reported by: Santiago Ruano Rincón <santiagorr <at> riseup.net>

Date: Wed, 19 Jul 2017 07:24:02 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Santiago Ruano Rincón <santiagorr <at> riseup.net>
To: 27763 <at> debbugs.gnu.org
Cc: 863002 <at> bugs.debian.org
Subject: bug#27763: egrep.sh: grep missing path
Date: Wed, 19 Jul 2017 09:22:43 +0200
[Message part 1 (text/plain, inline)]
Control: tags -1 + patch

Hi,

As suggested by this user, it would be better if egrep/fgrep script
calls grep using its absolute path.

On Fri, 19 May 2017 22:04:44 +0100 john mullee <mullee.john <at> gmail.com> wrote:
> Package: grep
> Version: 2.20-4.1
> 
> cat /bin/egrep
>      #!/bin/sh
>      exec grep -E "$@"
> 
> should replace with
> 
>      exec /bin/grep -E "$@"
> 
> to reproduce:
> 
> root <at> debian-512mb-fra1-01:/opt/firewall# bash
> root <at> debian-512mb-fra1-01:/opt/firewall# PATH=/usr/local egrep "any" /etc/*
> bash: egrep: command not found

Please, consider the attached patch. 

Cheers,

Santiago
[0001-src-Makefile.am-egrep.sh-call-grep-using-its-absolut.patch (text/x-diff, attachment)]
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 5 years and 141 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.