Linux - EnterpriseThis forum is for all items relating to using Linux in the Enterprise.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
If functions are set in the environment, you should see them using the set command, as suggested by catkin above. In alternative you can try
Code:
type DEV12
If you don't see any relevant output, maybe the code you're looking for hasn't been defined as an environment shell function (please notice that functions must be exported using
Code:
export -f function_name
in order to be available to the users' environment). Which system and shell is this, anyway
AIX 6.1 and ksh.
Code:
$ type DEV12
DEV12 is a function.
$
And see this error please:
Code:
$ export -f home
ksh: export: 0403-010 A specified flag is not valid for this command.
$
Quote:
If functions are set in the environment, you should see them using the set command, as suggested by catkin above.
I do see them but no source code. Here is what I see:
I am running the /bin/bash shell so maybe you are not seeing the declare feature due to not being in this shell. I'm guessing, but maybe if you try to switch to the bash shell you can do what you are trying with the "declare -f home" command. Just a thought.
I am running the /bin/bash shell so maybe you are not seeing the declare feature due to not being in this shell. I'm guessing, but maybe if you try to switch to the bash shell you can do what you are trying with the "declare -f home" command. Just a thought.
Michael Cunningham
Thanks Michael but I am unable to change the shell. I get this:
Code:
$ cat /etc/shells
/bin/csh
/bin/ksh
/bin/psh
/bin/tsh
/bin/bsh
/usr/bin/csh
/usr/bin/ksh
/usr/bin/psh
/usr/bin/tsh
/usr/bin/bsh
$ . /bin/bsh
ksh: 0403-057 Syntax error: `;' is not expected.
$ . /usr/bin/bsh
ksh: 0403-057 Syntax error: `;' is not expected.
$ bash
ksh: bash: not found.
$
Besides, I don't need to know the type of DEV12 but its source code.
$ cat /etc/shells
/bin/csh
/bin/ksh
/bin/psh
/bin/tsh
/bin/bsh
/usr/bin/csh
/usr/bin/ksh
/usr/bin/psh
/usr/bin/tsh
/usr/bin/bsh
$ . /bin/bsh
ksh: 0403-057 Syntax error: `;' is not expected.
$ . /usr/bin/bsh
ksh: 0403-057 Syntax error: `;' is not expected.
$ bash
ksh: bash: not found.
$
NB: Although it really looks like bash isn’t there: there is the command chsh to change your own login shell and on the AIX system I have access to it lists more than in /etc/shells.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.