Michael Schuster
|
Re: how to implement command "cd"
|
Michael Schuster
03/08/2019 1:05 AM
post119569
|
Re: how to implement command "cd"
... or a builtin of whatever tool you're building. look up 'chdir'.
On Fri, 2019-03-08 at 06:59 +0100, Michael Schuster wrote:
'cd' is a shell builtin.
think about it: "cd" changes the shell's current (working) directory. Since every process has its own current directory,
it'd be useless if it were a seperate binary, as it would only change its own directory, not that of the calling shell.
HTH
On Fri, 2019-03-08 at 00:56 -0500, mike scott wrote:
Hi QNX,
qnx sdp 6.6,
BSP_ti-am335x-beaglebone_br-660_be-660_SVN797070_JBN574.zip
beaglebone black Rev. C
QT 5.3.1
I implemented a QT program similar to https://evileg.com/en/post/261/
input filesystem command such as "ls", which will list the files under current directory. and "pwd" will show the
current directory path.
However, I am not able to change directory with command "cd".
"ls" / "pwd" and lots of other commands are available @ /opt/qnx660/target/qnx6/armle-v7/bin, however there is no "cd".
Please advise, thanks in advance.
Mike
_______________________________________________
OSTech
http://community.qnx.com/sf/go/post119567
To cancel your subscription to this discussion, please e-mail ostech-core_os-unsubscribe@community.qnx.com<mailto:ostech
-core_os-unsubscribe@community.qnx.com>
|
|
|
mike scott(deleted)
|
Re: how to implement command "cd"
|
mike scott(deleted)
03/08/2019 1:07 AM
post119570
|
Re: how to implement command "cd"
Hi Michael Schuster,
Thank you for the quick reply.
Then is there anyway I can bring the shell environment into this QT program, in which then I am able to use "cd" to
change directories?
Please advise, thanks in advance
Mike
|
|
|