Re: Find the path of a shell command [POSTPONED]

2022-10-16 Thread Peter J. Holzer
On 2022-10-16 17:21:03 +0100, Barry wrote: > > On 16 Oct 2022, at 04:53, Dan Stromberg wrote: > > > > On Wed, Oct 12, 2022 at 9:57 PM Cameron Simpson wrote: > > > >>> On 13Oct2022 03:25, Paulo da Silva > >>> wrote: > >>> There is another problem involved. The script, works fine except when >

Re: Find the path of a shell command [POSTPONED]

2022-10-16 Thread Barry
> On 16 Oct 2022, at 04:53, Dan Stromberg wrote: > > On Wed, Oct 12, 2022 at 9:57 PM Cameron Simpson wrote: > >>> On 13Oct2022 03:25, Paulo da Silva >>> wrote: >>> There is another problem involved. The script, works fine except when >>> launched by cron! Why? >> >> Record the script

Re: Find the path of a shell command [POSTPONED]

2022-10-15 Thread Dan Stromberg
On Wed, Oct 12, 2022 at 9:57 PM Cameron Simpson wrote: > On 13Oct2022 03:25, Paulo da Silva > wrote: > >There is another problem involved. The script, works fine except when > >launched by cron! Why? > > Record the script output: > > # record all output > exec >/tmp/script.$$.out 2>&1

Re: Find the path of a shell command [POSTPONED]

2022-10-12 Thread Cameron Simpson
On 13Oct2022 03:25, Paulo da Silva wrote: There is another problem involved. The script, works fine except when launched by cron! Why? Record the script output: # record all output exec >/tmp/script.$$.out 2>&1 # dump the envionment env | sort # turn on execution tracing

Re: Find the path of a shell command [POSTPONED]

2022-10-12 Thread Paulo da Silva
Às 05:00 de 12/10/22, Paulo da Silva escreveu: Hi! The simple question: How do I find the full path of a shell command (linux), i.e. how do I obtain the corresponding of, for example, "type rm" in command line? The reason: I have python program that launches a detached rm. It works pretty