Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Development Tools Console Foundations Users and Permissions Creating Users

Hadi Farhat
PLUS
Hadi Farhat
Courses Plus Student 7,102 Points

using cd to change to a new user

I tried using cd command to switch to a new user from the home directory and it worked. Is there any difference between cd and su when switching to a new user ?

1 Answer

cd will change the directory that your console is in, but will not change the actual user to my knowledge. In my console it says ted@ted-Lenovo-G770 ~ $ when I am in my home directory and ted@ted-Lenovo-G770 / $ when I am in my root. Did the ted@ part change for you or just the stuff between the beginning and the $? Also, what OS are you using?