mikeizbicki / ucr-cs100

open source software construction course
Other
485 stars 407 forks source link

HW2 question #37

Closed katherinegallaher closed 10 years ago

katherinegallaher commented 10 years ago

I'm trying to make sure I understand all aspects of the assignment so I wanted to clarify some things. We are creating the ls.cpp separate from our rshell.cpp file but they will be in the same repository, right? How should we set up user input? Can we make it so when the program runs we take one ls command and then the program quits Or do we have to do something like we continuously take commands until they exit the program?

bmars003 commented 10 years ago

HW2 is in the same repository as HW1.

mikeizbicki commented 10 years ago

Your ls should behave exactly like the GNU ls command for the -a, -l, and -R commands. There is no user input from stdin.

DanTheTingler commented 10 years ago

I'm still a bit confused after reading the answers. So in our ls.cpp, if there isn't supposed to be user input, then how is the user supposed to input the flags and what not? Is the rshell.cpp supposed to call the ls.cpp everytime ls is called?

mikeizbicki commented 10 years ago

Your ls will take parameters via argv and argc. This is different than stdin.

katherinegallaher commented 10 years ago

Oh okay! That makes sense. Thanks for clarifying