Not sure why the instructions say cp, the command for changing directory is cd. You’re closer to it but there must be a space in-between cd and the path you’re trying to change to, cd /some/path
I’m not sure if the absolute path is accepted or not; if it fails consider using the relative path in a manner similar to the one I provided in a previous post-
now I am on step 2 where it says Using a single cp command, copy all the contents of frida.txt to lincoln.txt .
cp frida.txt
cp: missing destination file operand after ‘frida.txt’
Try ‘cp --help’ for more information.
$ cp frida.txt/lincoln.txt
cp: missing destination file operand after ‘frida.txt/lincoln.txt’
Try ‘cp --help’ for more information.
$
For step 5 this is what I have gotten and I am still stuck on this any help?
cp biopic/cleopatra.txt historical/
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
$ cp biopic/cleopatra.txt historical.txt
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
$ cp biopic/cleopatra.txt …/historical
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
$ cp biopic/cleopatra.txt historical/
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
$ cd movies/biopic
bash: cd: movies/biopic: No such file or directory
$ cd movies/
$ cd drama/
$ cd biopic/
$ cp biopic/cleopatra.txt historical/
cp: cannot stat ‘biopic/cleopatra.txt’: No such file or directory
$ cp cleopatra.txt historical/
cp: cannot create regular file ‘historical/’: Not a directory
$ cp cleopatra.txt historical.txt/
cp: cannot create regular file ‘historical.txt/’: Not a directory
$
In a single command, make a copy of cleopatra.txt to go into the historical/ directory.
Pay attention to your current position, which you can always access using the command pwd .
Use cp with the first argument being the file name, and the second argument being the destination directory’s path.
The current directory is drama/ , so the relative path to cleopatra.txt is biopic/cleopatra.txt .
historical/ is inside the current directory drama/ , so you can refer to the name directly.
I’d suggest using the get-help portion of these forums for issues with each individual instruction (assuming you cannot already find an answer in the FAQ). The Question/Answer back and forth is better in get-help rather than the FAQs.
Make sure to link the relevant lesson and give the following a read for general advice on how best to set up a question-
Hey can anyone assist me? I see a lot of people are having a problem with number 5. I’m clearly taking the wrong path but is there anyone that can help me move forward?
In a single command, make a copy of cleopatra.txt to go into the historical/ directory.
I put
cp biopic/cleopatra.txt historical/
but get an error There should be a version of cleopatra.txt inside the drama/historical/ directory! Did you use a cp command to make a copy to the right destination?
I’m currently waiting for an answer for Step 5 on this part. I’m seriously going to throw this computer outside right now. I’m doing just allright on this tutorial and i’m just stuck on this step for one hour. If someone can just tell me what to type down for this part, that would be much appreciated.
Double check the hint on this one. The previous poster appears to be in the movies directory at /home/ccuser/workspace/movies/ (the contents of ls match the movies directory in the image on the RHS). You’d want to be in the /home/ccuser/workspace/movies/drama directory, try pwd to double-check where you’re at and cd to move into it.
The cp command given in the hint uses relative paths which would only work if you were in exactly the right directory.
Firstly it’s important to know which working directory you’re in. To check this, use the pwd command to see where you are in the file structure.
Once you know where you are, navigate to the Biopic folder
Next, type this command in: cp biopic/cleopatra.txt historical - This will copy the cleopatra.txt file to the historical folder.
Once done, navigate to the historical folder from the biopic folder using this command: cd …/historical and finally check if the file was successfully copied to this folder by using the ls command
I figured out how to get past step 5 in “cp part 1.” what you have to do is type in “cd /home/ccuser/workspace/movies/drama/historical” this will put you in the historical directory. Next, you type “touch cleopatra.txt” to add cleopatra.txt to historical. You’re Welcome