Am working through the appendix for Learn Python The Hard Way to familiarise myself with bash. However, in exercise 55.9.1 it shows us the pushd and popd commands t move around. When it says to type this:
cd temp
$ mkdir i/like/icecream
I do the exact the same thing in my terminal (Mac OSx) and get the following:
mkdir: i/like: no such file or directory.
i’m not sure what I"m doing wrong and it’d be great if someone could tell me. I’m going to move on from that exercise but I imagine it’s pretty important.
ok nevermind it was because i wasn’t putting the -p in between mkdir and i/like/icecream. i can’t see where that is specifically mentioned in the chapter beforehand, though.
Yes, you need the “-p” on macOS.
This screenshot is from the pdf version of the book. The pdf version is missing the “-p”.
The html version is correct. It has the “-p”.
I encountered this issue myself when working through the command line appendix. As quoted above, the -p modifier for the mkdir command is missing from the .pdf at the beginning of exercise 55.9.1 (line 2). Just wanted to make sure this is the case. I understand the importance of typing in the commands exactly as we see them for beginners and this one had me confused for a while before I just decided to google the issue and found others having the same problem. Thanks for such a great approach to learning this stuff. I’m very much enjoying it.
I’m fairly certain I’m looking at the right page. I quoted it above. Other people have this problem in the forum, I just don’t think anybody followed up with a reply to you that it was a possible misprint. Take a look…a screenshot of the currently downloadable .pdf is viewable above this post.
Oh weird, yeah the -p is missing on the linux instructions but I fixed that ages ago in the Python 3 book. What book are you using again? When did you get it?