This wikiHow teaches you how to save different types of files from the Linux command line. If you're using an app that has a graphical user interface (GUI), saving files is easy—you'll usually just need to click the File menu and select Save.
Learn how to save files in Linux using the vi editor, with step-by-step instructions on standard saving, renaming files, and overwriting read-only files.
In short, you can use any one of the following commands to save a file in Unix: Now you know various options. Let us explorer them with examples showing you how to save a file in Unix systems. 1. Creating and saving a file using Unix echo command. $ echo "This is a test. Some data" > foo.txt. $ printf "This is a test. Some data\n" > foo.txt.