I am working on a project for builiding a shell for a java enabled mobile phone(using J2ME).I have to demonstarte 3 commands 1) ls 2) top 3)cat .How to implement them?Plese give me some ideas.Thanking you.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Download Coreutils (it’s the package which contains all of these commands): http://ftp.gnu.org/gnu/coreutils/coreutils-8.9.tar.gz.
Rip it open, and find the source code for each one. I think the tarball is organized quite nicely.
And some implementations of the commands in other languages (I like Python, as it’s readable):
ls: http://www.pixelbeat.org/talks/python/ls.py.html.cat: http://www.unix.com/302420159-post2.html.topis complicated. Good luck implementing it!