Simple Commands
I am very new to linux, but I have been able to do alot so far. This may be a stupid question, but how do I create a new file. I have looked at many sites with a list of commands, but I can't seem to find a very simple command to create a new file.
I am trying to do this: add a file named swat in your /etc/xinetd.d directory How do I add a file, I have looked at many commands, but none say how to just create a new file. Sorry for the dumb question... |
you can just open a text editor and when your done adding
its contents, you can just save the file as "swat" in that directory. or if you want to create the empty file before adding anything you can type : touch swat within the folder you want the file to be located. |
oh, text editor, seems so simple now... Thanx
|
If the file just needs to be present you can use the touch command (i.e. touch swat). It creates an empty file with the name specified. If you use touch on an existing file it sets the file's modification time to the current time. It just kind of...touches it :)
|
All times are GMT -5. The time now is 02:23 AM. |