Page 1 of 1

Running a command [solved]

Posted: Mon Jun 18, 2018 2:46 pm
by Convert
Hi there,

A question about running a command (or program; an executable in any case).

Is it possible to execute a command which resides in the current Working Directory?
The Working Directory is not part of the PATH environment variable.
When trying to do so, I get a message 'command not found'.

a Convert

Re: Running a command

Posted: Mon Jun 18, 2018 2:48 pm
by jbudd
./command
/fullpathname/command
export PATH=$PATH:. ; command

Re: Running a command

Posted: Mon Jun 18, 2018 3:00 pm
by DougieLawson
Use the "dot slash commandname" feature of the shell.
./commandname

Re: Running a command

Posted: Mon Jun 18, 2018 6:34 pm
by Convert
Thanks (again) guys! This works indeed.

a Convert