Results 1 to 6 of 6
I need to edit a word in a file in the terminal.What do you type so you can read the text?...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 07-20-2006 #1
What the command?
- 07-20-2006 #2
There are lots of commands you can use. You said you wanted to be able to edit a file, so you'll probably find these available on your system:
nano somefile.txt pico somefile.txt emacs somefile.txt vi somefile.txt
cat somefile.txt | lessRegistered Linux user #270181
TechieMoe's Tech Rants
- 07-20-2006 #3Code:
# cat filename.txt
To edit it you will need an editor. Common console based editors are 'nano', 'vi', 'vim' and 'emacs'. To run these you use:
# programname filename.txt
# cat <<EOF> filename.txtCode:
# cat <<EOF>> filename.txt
EDIT: I was too late....
- 07-20-2006 #4
- Join Date
- Dec 2005
you can also use gedit (if you have gnome desktop)
sudo gedit <enter filename here>
***note*** sudo is only required if you need root access to edit the file (such as grub)
- 07-20-2006 #5
Also, if cat isn't feasible because the file's too big, less would probably be a better choice.Flies of a particular kind, i.e. time-flies, are fond of an arrow.
Registered Linux User #408794
- 07-20-2006 #6