So I have a semiworking program where I read in user input using
getline(std::cin, userinput, '\n')
I then send the input to a
std::vector<std::string> subStrs
to break up the input from the user so each command element is seperate
and then push them all to a
std::vector<char*> params
so I can pass it to execvp(..)
This seems very inefficient to me but is there a better way of getting the user input into the std::vector<char*>
without all of the intermediate steps?