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 trialjohn larson
16,594 Pointsgoing through console foundations...again. Using Bash for windows. Can't seem to locate /home
smolderingflax@LAPTOP-0SBQ309H:~$ pwd
/home/smolderingflax
smolderingflax@LAPTOP-0SBQ309H:~$
pwd says I have one. But if I look through to try to find it, directories are as follows:
- c
- Users
- smolderingflax
would it be called something else? I came to this problem because I can't seem to change directories at all.
smolderingflax@LAPTOP-0SBQ309H:~$ cd documents
bash: cd: documents: No such file or directory
but I put a documents directory in the smoldering flax directory. What nuance (or glaring mistake) am I making. Thank you.
john larson
16,594 PointsJennifer, I don't see a documents directory listed when I do ls -al. I guess I'm confused about where
smolderingflax@LAPTOP-0SBQ309H:~$ pwd
/home/smolderingflax
actually is. If I use the treehouse console it works fine, but I'd rather work local to get a better understanding of how everything works and is setup
3 Answers
Jennifer Nordell
Treehouse TeacherHi there! If you're on a Windows system and you're using bash as your CLI you need to keep in mind that your directory structure will not be exactly the same as a Mac's directory structure. They use different file systems. So if you want it to look like the videos you're going to sort of have to make it look that way yourself
But this is really hard to say without seeing your entire directory/file structure. However, you are obviously missing the documents directory otherwise, it would have shown up in the ls -al
. So get to the folder where you want to be when you make the subdirectory "documents" and type this:
mkdir documents
cd documents
Let me know how it goes!
john larson
16,594 PointsThanks Jennifer, I kinda figured I would need to make the directory with commands, but I didn't remember how to do it. So I appreciate you showing me how and yes that did it.
john larson
16,594 PointsOne last thought. I'm kind of getting the impression that I don't have access to Bash files outside the Bash shell. Like I can't go into say the C drive and find some text file done through Bash, I have to actually go through bash to view/use that file. Is this a correct impression?
Jennifer Nordell
Treehouse Teacherjohn larson no that's not correct. However, for it to be associated to the correct program to view it it'll need the correct extension. Try this:
touch test_doc.txt
You should be able to go into a text editor such as Notepad or Sublime and be able to open that file (although it won't contain any text yet)
James Home
12,011 PointsNo. ~/
James Home
12,011 PointsI am on Unix but try ~/home
john larson
16,594 PointsJames, if I do /home it just says:
bash: /home: Is a directory
I would like to find where that actually is on my system. Because I can't find a directory "home". The directory before smolderingflax that I can see on my system, is users.
Jennifer Nordell
Treehouse TeacherJennifer Nordell
Treehouse TeacherWhen you are in this directory and you issue the ls -al command, do you see documents listed there? Let me know!