Stuck on 5/10

$ cd drama/historial
bash: cd: drama/historial: No such file or directory
$ cd drama/historial drama/
bash: cd: drama/historial: No such file or directory
$ drama/historical
bash: drama/historical: Is a directory
$ cp drama/historical
cp: missing destination file operand after ‘drama/historical’
Try ‘cp --help’ for more information.
$ cp drama/historical drama/
cp: omitting directory ‘drama/historical’
$ cd drama/historical/drama
bash: cd: drama/historical/drama: No such file or directory
$ cd drama/historical.txt drama/
bash: cd: drama/historical.txt: No such file or directory
$
$ cd drama/historical.txt/ drama/
bash: cd: drama/historical.txt/: No such file or directory
$ cd drama/historical.txt/ drama/
bash: cd: drama/historical.txt/: No such file or directory
$ cd /drama
bash: cd: /drama: No such file or directory
$ cd drama/historical

I’ve tried whatever i though could work. But nothing seems to work. Anyone know what code to make it work? Thx

You spelt historical wrong here in your first command, doesn’t look like you retried it although I’m pretty sure it only wants you to go to drama

cd drama/

Here’s the list I think it should be:

cd drama/
ls
pwd

cp biopic/cleopatra.txt historical/

cd historical/
ls

cd …

cp biopic/ray.txt biopic/notorious.txt historical/

cd historical/

ls

2 Likes

Pay attention to those error messages! They may say a lot about what you need to change to get your desired result.

$ cd drama/historial 
bash: cd: drama/historial: No such file or directory 
$ cd drama/historial drama/ 
bash: cd: drama/historial: No such file or directory 

as @benjnev points out, spelling.


$ drama/historical 
bash: drama/historical: Is a directory 

Here you can see that you’ve found the directory, but you’re trying to execute it and that doesn’t make sense. Or at least, the way we change directory is with cd, not by executing the directory.


$ cp drama/historical 
cp: missing destination file operand after ‘drama/historical’ 
Try 'cp --help' for more information. 
$ cp drama/historical drama/ 
cp: omitting directory ‘drama/historical’ 

Using --help is a good idea, but directories need to be copied with -r (recursive)
besides, it’s already in the location that you are trying to copy it to!


$ cd drama/historical/drama 
bash: cd: drama/historical/drama: No such file or directory 
$ cd drama/historical.txt drama/ 
bash: cd: drama/historical.txt: No such file or directory 
$ 
$ cd drama/historical.txt/ drama/ 
bash: cd: drama/historical.txt/: No such file or directory 
$ cd drama/historical.txt/ drama/ 
bash: cd: drama/historical.txt/: No such file or directory 

Now you’re trying to get at a bunch of stuff that doesn’t exist. You can use ls to list what exists in a directory.


$ cd /drama 
bash: cd: /drama: No such file or directory 

Starting a path with / means that that path starts at the very top (root) of the file-system as opposed to relative to your current location.


$ cd drama/historical

Assuming that the above is a directory, then this probably made you move to that directory. No idea if that’s what you were after or if that’s what you’re intended to do, but hey, the command successfully executed.

Hello everybody My name is ABD AR-RAHMAN HAMMADEH and I’m just like you’re stuck in this vicious circle of non-evidence existed so I thought a simple alternative solution, and at the same time so that you can try to copy this code or writing it in the terminal emulator and, God willing, will work…:slight_smile:
cd .. cp biopic/cleopatra.txt historical/
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
historical -cd cleopatra.txt bash: historical: command not found ls -cd historical …cleopatra.txt
ls: cannot access historical: No such file or directory
ls: cannot access …cleopatra.txt: No such file or directory
$

3 Likes

you spelled it wrong, it more like:
$cd drama/ historical

Hey guys so just working through the command line and i keep getting stuck here at 5/10 overtime i try and move to data directory it keeps telling me it can’t be found. I’ve tried about 10 times now even started again and after i copy the two files from 4/10 i go to 5/10 and I’m doing something wrong and it won’t find drama any help would be great as its driving me insane i know it will be something small

drwxr-xr-x 4 ccuser ccuser 4096 Jul 8 2015 comedy
drwxr-xr-x 4 ccuser ccuser 4096 Jul 8 2015 drama
-rw-r–r-- 1 ccuser ccuser 0 Jul 8 2015 genres.txt
cd comedy/ ls -alt
total 20
drwxr-xr-x 5 ccuser ccuser 4096 Feb 9 19:53 …
drwxr-xr-x 4 ccuser ccuser 4096 Jul 8 2015 .
-rw-r–r-- 1 ccuser ccuser 0 Jul 8 2015 .gitignore
drwxr-xr-x 2 ccuser ccuser 4096 Jul 8 2015 satire
drwxr-xr-x 2 ccuser ccuser 4096 Jul 8 2015 slapstick
-rw-r–r-- 1 ccuser ccuser 14 Jul 8 2015 the-office.txt
cd drama/biopic/ bash: cd: drama/biopic/: No such file or directory cd …/drama/biopic/
ls -alt total 32 -rw-r--r-- 1 ccuser ccuser 1431 Feb 9 11:40 lincoln.txt drwxr-xr-x 2 ccuser ccuser 4096 Feb 9 11:40 . -rw-r--r-- 1 ccuser ccuser 1431 Feb 9 11:40 lincon.txt -rw-r--r-- 1 ccuser ccuser 13 Jul 8 2015 cleopatra.txt -rw-r--r-- 1 ccuser ccuser 1431 Jul 8 2015 frida.txt -rw-r--r-- 1 ccuser ccuser 13 Jul 8 2015 notorious.txt -rw-r--r-- 1 ccuser ccuser 7 Jul 8 2015 ray.txt drwxr-xr-x 4 ccuser ccuser 4096 Jul 8 2015 .. cp frida.txt lincoln.txt
cd ../drama/ bash: cd: ../drama/: No such file or directory cd drama/
bash: cd: drama/: No such file or directory
cd ..drama/ bash: cd: ..drama/: No such file or directory cd drama/
bash: cd: drama/: No such file or directory
$

so, i fixed my problem. it was something stupid all i was forgetting was the …/…/before the new directory that i wanted to enter into. thought i would leave this up for anyone that might be having the same problem as me

Don’t use extra spaces

1 Like

Thanks, tobuscus45. This worked for me, though I am still entirely unsure why I couldn’t get past step 3 without using your code. I was able to see the copy of cleopatra.txt I made within the historical/ directory, but CodeAcademy wouldn’t let me go on. I reported the bug, but maybe I was just missing something in my code. Thanks!

Thank you, you really helped me

Thanks it helped me too

Page 5/10: I’ve started this module the other day and I was stuck on the exact one for a bit until I realized I wasn’t in the correct directory. For future references:

Make sure you’re in the drama/ directory
cd drama
THEN do
cp biopic/cleopatra.txt historical/

and it will work.

1 Like

Hello, thank you. That was very helpful.