LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-20-2004, 05:49 PM   #1
paschim
Member
 
Registered: Apr 2004
Location: UK, south london
Posts: 51

Rep: Reputation: 15
what is vi and emacs?


can anyone pls help me to understand without link what is vi and emacs. i know they are editor but what are they used for? how do you start them? any commands how you save?
 
Old 09-20-2004, 06:01 PM   #2
dylbyrt45
Member
 
Registered: Sep 2003
Location: Dallas
Distribution: Suse 9.1 pro
Posts: 37

Rep: Reputation: 15
From the command line type vi or vim either one will work. This will start the editor in that window. If you type vimtutor, this will start a very easy to use tutorial on vi. The same goes for emacs, type it at the command line and a new window will open for the emacs editor, complete with tutorial.
 
Old 09-20-2004, 08:33 PM   #3
servnov
Member
 
Registered: Sep 2004
Distribution: Slackware 10.2
Posts: 276

Rep: Reputation: 30
emacs is a much more than a text editor, its a big editing suite. Many people dont like it cause its so bulky. Vi is the orginal and standard UNIX text editor. Whatever editor you choose is up to you, but you prolly gonna need to know vi either way.
 
Old 09-20-2004, 08:51 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Vi is just an over-hyped front-end to ed, the REAL
unix editor ;)


Cheers,
Tink
 
Old 09-21-2004, 02:38 AM   #5
gjo
Member
 
Registered: Aug 2004
Location: South India
Distribution: Fedora3,Xandros,WinXP
Posts: 53

Rep: Reputation: 15
start here...go to linux konsole and type vi or vi with filename
e.g. #vi
or
#vi test.txt
(for 1st eg we can give the file name at the time of saving)
for vi editor there are 3 modes
for writing text u have change it as insert mode. to do this just press 'i' then u can start typing

to save & quit,first change the mode .to do this press 'Esc'
then press ':' (shift+ and wq
eg. the end of file will now looklike
:wq

or u can type 'x' instead of wq

for giving file name give like:
:w filename

this is just an intro. ok.
 
Old 09-21-2004, 02:58 AM   #6
MartinN
Member
 
Registered: Nov 2003
Location: Ronneby, Sweden
Posts: 555

Rep: Reputation: 30
I wrote this little emacs tutorial in a thread just a couple of days ago, but since you demanded a "link free zone" I'll copy & paste it here

Quick tutorial for emacs beginners:

C-x means Control-x
M-x means Meta-x (which, on a PC keyboard, is Alt-x)


To open a file: C-x C-f
To save a file: C-x C-s
To save as: C-x C-w
To get out of the minibuffer (for example, if you press C-x C-w and change your mind): C-g

To start marking text: C-space
To copy from mark to cursor: M-w
To cut from mark to cursor: C-w
To insert text: C-y

If you open a second file, then you have two active buffers. To switch between active buffers: C-b
A tab here gives a list of possible buffers to switch between

To kill a buffer: C-k

Want more?
M-x help (that is 'M-x' and then type 'help' <RET> )
enters the help system.

Before leaving, make sure to try
M-x tetris
Use arrows and space to control and C-k to exit

To shut down emacs: C-x C-c


Enjoy the world of emacs!
Martin
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
where is the .emacs file in the emacs source code tarball? aizkorri Programming 2 01-13-2007 02:05 PM
emacs not responding to .emacs file in Mandriva 2005 LE. Please help LaptopLinux Mandriva 1 06-08-2005 08:36 AM
Emacs. shayan_tabrizi Linux - Software 1 07-23-2004 07:02 AM
edb (emacs database) won't open file - emacs 20 & 21 tip184 Linux - Software 0 04-03-2004 07:31 AM
Emacs HELP! sathyan Programming 6 07-18-2003 02:55 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration