Now we're going to finally create some files which we'll pretend represent our friends out in the real world.
There are a lot of ways to create a file:
- An application you run might generate files
- You might use a text editor to create a new file and put something in it
- You can download a file
- You can copy a file from elsewhere
And so on. Let's use the "text editor" option because that will allow us to knock down two bottles with one stone:
I'm going to switch to a screenshot here so I can show you the results I get.
This is the
nano editor. It ships with Ubuntu and quite user friendly. We can type into this window and add contents to the file. Maybe type this (but type anything you like, really):
Now type this key combination: Ctrl+O
This triggers the "Write Out" command, which you can see along the bottom. It means, "Write what I've typed to the file, on my file system, so that the work I've done is saved." You'll be asked what the filename is, and it should already say
jeff.txt because we provided that when we typed
nano jeff.txt. Press Enter
Now type Ctrl+X to leave
nano. We can now see we have our first file (friend?) if we do:
1 2 3 4
A friend! We have a new file/friend called
jeff.txt and it's owned by us (me:
68 in size (
68 bytes) and was created on
March 18th at
We can now move around the file system and create files.