SWI Prolog change working directory/get current working directory?

Viewed 31105

in SWI Prolog terminal how do I view the current working directory and change the current working directory?

I found:

working_directory(CWD, CWD)

but I dont think its what I need

3 Answers

To view the current directory use : pwd.

And to change it use : working_directory(CWD,'path_or_location').

Example : working_directory(CWD,'C:/Users/Student/Destop').

Remember to change the direction of slashes in the path name.

Related