In bash, using echo $? to get the last command's exit status. But how to get it in newlisp?
e.g.
In bash, I get 0, it means the /user/chenshu folder exists in HDFS
Code: Select all
hdfs dfs -test -e /user/chenshu
echo $?
0
Code: Select all
> (exec "hdfs dfs -test -e /user/chenshu;echo $?")
14/10/27 09:19:33 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicab\
le
("0")
Any way to get the exist status quickly?