Monday, May 24, 2010

How do you put a file in a file in UNIX. Ex. In directory Water project is file menu, and in file menu...?

How do you put a file in a file in UNIX. Ex. In directory Water Project is file Menu, and in file Menu is files Add, Remove, and modify? I only know how to put files in directories.





Also is there a command to make a file specifically a date file and not just a text file, i.e $%26gt; vi filename.

How do you put a file in a file in UNIX. Ex. In directory Water project is file menu, and in file menu...?
Not sure exactly what you mean. If you simply want to concatenate three text files named Add, Remove and modify and put the result in a file called Menu, you can use "cat Add Remove modify %26gt;Menu".





If you want to archive and compress them like with zip files on windows, you can use the tar command:





tar -zcvf Menu.tar.gz Add Remove modify





Then to extract them again:





tar -zxvf Menu.tar.gz





Regarding the command to make a file a 'date' file rather than just a text file, I can't really help since I don't know what you mean by a 'date' file.





But ls -l will list files in a way that shows their last modification time/date if you mean that.
Reply:If I understand your question right, you want to create a subdirectory. Generally in the "Save As" dialog, there will be an option for creating a new subdirectory (folder) and then you can put the file in there.





I am not sure what you mean by a date file. You can use the touch command to create an empty file which will have a datestamp of when you ran the command. You can then see the date using "ls -l"





I hope this helps

mothers day cards

No comments:

Post a Comment