Copying files and directories


show more Copying files and directories provides you with in-depth training on IT. Taught by Kevin Skoglund as part of the Unix for Mac OS X Users show less
please wait ...

Copying files and directories

Now, I would like to talk about how to copy them. Let's take a look. First of all, we'll do ls -la. Notice that I'm inside my unix_files directory now, which is inside my user root. At the end of the last movie we moved everything into this folder. So you can see I have got all of my unix_files just in this folder. Now, I'll start by doing cat new_file.txt. It's just a very simple text file. Let's copy that. We use cp to copy and we start by saying copy these source.

Our source for this is going to be file.txt. Again, we can provide a full path to that source. It doesn't have to be something that's in this current directory. It can be an absolute path or a relative path. And then the destination, the target. And again, absolute or relative path. In this case, we are going to call it newer_file.txt. It did it. Say ls -la,. We can now see the newer file there and cat newer_file and we see that it copied the content as well. So it's that easy.

It really is...

Copying files and directories
Video duration: 3m 7s 6h 35m Beginner

Viewers:

Copying files and directories provides you with in-depth training on IT. Taught by Kevin Skoglund as part of the Unix for Mac OS X Users

Subject:
IT
Software:
Mac OS X Unix
Author:
please wait ...