C
creo
Hi all!
this is a (relatively) newbie question
I am writing a shell in Python and I am facing a problem
The problem is, after taking the input from user, i have to execute the
command which is a python function
i invoke an 'ls' command like this
commands.ls()
where commands.py is a file in the same directory
what i want to do is
commands.VARIABLE()
where VARIABLE holds the name of the function which i want to execute
and depends on what the user has typed
what should i do to achieve that?
any help is appreciated
thank you
-creo
P.S. if you want me to clarify the question, please tell me so
this is a (relatively) newbie question
I am writing a shell in Python and I am facing a problem
The problem is, after taking the input from user, i have to execute the
command which is a python function
i invoke an 'ls' command like this
commands.ls()
where commands.py is a file in the same directory
what i want to do is
commands.VARIABLE()
where VARIABLE holds the name of the function which i want to execute
and depends on what the user has typed
what should i do to achieve that?
any help is appreciated
thank you
-creo
P.S. if you want me to clarify the question, please tell me so