I have this shell emulator:
How do I make it so that you can use the cd function to change the directory? Right now it doesn't work.Code:#include <iostream> #include <string> #include <windows.h> using namespace std; int main() { char path[500]; GetCurrentDirectory(500,path); std::string command; start: cout << path << ">"; getline( cin, command ); system(command.c_str()); goto start; }