nixCraft Linux Forum

nixCraft

Linux / UNIX Tech Support Forum

how to use editor like vi or mcedit

This is a discussion on how to use editor like vi or mcedit within the Getting started tutorials forums, part of the Linux Getting Started category; I gone through several basic Linux commands and i starts to next level of shell scripting there they accentuates editor ...

Register free or login to your existing account and remove all advertisements.


Go Back   nixCraft Linux Forum > Linux Getting Started > Getting started tutorials

Linux answers from nixCraft.


Getting started tutorials So much to read, so little time! If that is your problem, we have solution. Read our FAQ and tutorials to help you cut through the clutter of information overload. Only members of "contributors" group can post new tutorials. Other members can just reply to thread.

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-28-2008, 10:36 AM
Junior Member
User
 
Join Date: Mar 2008
OS: Debian
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
chandrasekar is on a distinguished road
Default how to use editor like vi or mcedit

I gone through several basic Linux commands and i starts to next level of shell scripting there they accentuates editor like vi or mcedit and i hadn't learn the commands so please any body help me
Reply With Quote
  #2 (permalink)  
Old 04-07-2008, 07:53 PM
Junior Member
User
 
Join Date: Apr 2008
OS: Fedora
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
RamPD is on a distinguished road
Default

Hi here is some comman comands when using Vi text editor:
if you have to edit a file like ram.sh you put this command
$ vi ram.sh
now u can edit the file ...
if you want to creat a new file with vi in this case the file name is ram follow the steps i writing here:
$ vi ram
now it open text editor to insert the text esc+i
to save the text esc + : + w
to quit from text editor esc + : + q
Reply With Quote
  #3 (permalink)  
Old 04-09-2008, 02:36 PM
Junior Member
User
 
Join Date: Feb 2008
OS: Linux
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
chal.arun is on a distinguished road
Default

Hey install the vim rpm and just run the "vimtutor" to get the knowledge of how to use the vi editor.
Reply With Quote
  #4 (permalink)  
Old 02-11-2009, 02:42 AM
Junior Member
User
 
Join Date: Feb 2009
Location: earth
OS: Fedora
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
PatJr is on a distinguished road
Default

I am not to good with Linux.
I always use the nano editor now.
It's way easy to use.

Pat Jr.
Reply With Quote
  #5 (permalink)  
Old 07-31-2009, 02:24 PM
Junior Member
User
 
Join Date: Jul 2009
OS: Debian/Zenwalk
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
Elverion is on a distinguished road
Default

Hi,

Actually, Vim is a very powerful editor and can be (if configured) an IDE (Integrated Development Editor).

It supports syntax highlightning, line numbering, a language corrector and much more...

The tutorials on vim's website are clear and easy to understand.

I only use Vim for programming.

Cheers,
Elverion
Reply With Quote
  #6 (permalink)  
Old 09-04-2009, 01:04 PM
giri's Avatar
Junior Member
User
 
Join Date: Nov 2008
OS: Red Hat
Posts: 10
Thanks: 1
Thanked 0 Times in 0 Posts
Rep Power: 0
giri is on a distinguished road
Default VI editor

hey guys,

VI is a powerful tool and is very convenient following are the commands

1)To create a file
vi
2)to go into insert mod
we can type letters
i,a,o,A,O.....

i takes to the insert mode
a------ we can insert word next to the current cursor position(ccp)
A------we can insert word at the end of the line
o-----we can insert line or words in the next line to ccp
O-----we can insert line or words in the before line to ccp
3)some of the commonly used

type esc ---- you will come out of the insert mode
w ----- to save
q-------to quit
wq-----save and quit
wq!---- save and quit forcefully
q!-------quit forcefully without saving
g------you will go towards the starting of the file
shift+g------you will go towards the end of the file

4)if you wana search for a word in a file

type / nad hit on enter

5)if you wana number the lines type
: se nu

there are many more pls refer "to man" if any doubts i will try to resolve it
Reply With Quote
  #7 (permalink)  
Old 09-04-2009, 06:27 PM
jaysunn's Avatar
Powered By Linux
User
 
Join Date: Apr 2009
Location: 41.332032,-73.089775
OS: RHEL - OSX
Posts: 597
Thanks: 61
Thanked 78 Times in 70 Posts
Rep Power: 10
jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold
Default Hello

Vi is a wonderful editor that takes time to master. Trust me I learn new commands daily. I like this document cause it is a pdf. However this site has great vi write ups.

https://docs.rice.edu/confluence/dow....pdf?version=1

The vi editor story – an interview with Bill Joy

Learning and Mastering the Linux VI / VIM editor


UNIX / Linux: vi / vim perform search and replace operation

When I first started with VI I printed a cheat sheet and taped it below my keyboard as a quick reference.

HTH,

Jaysunn
__________________
Have a look at what I have been working on
http://www.shellasaurus.com
Reply With Quote
  #8 (permalink)  
Old 09-04-2009, 07:12 PM
nixcraft's Avatar
Never say die
User
 
Join Date: Jan 2005
Location: BIOS
OS: RHEL
Scripting language: Bash and Python
Posts: 2,683
Thanks: 11
Thanked 241 Times in 181 Posts
Rep Power: 10
nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute
Default

the Vim tutor
Code:
vimtutor
__________________
Vivek Gite
Linux Evangelist
Be proud RHEL user, and let the world know about your enterprise choices! Join RedHat user group.
Always use CODE tags for posting system output and commands!
Do you run a Linux? Let's face it, you need help
Reply With Quote
  #9 (permalink)  
Old 09-04-2009, 09:23 PM
Junior Member
User
 
Join Date: Jul 2009
OS: CentOS 5.3 x86_64
Posts: 29
Thanks: 1
Thanked 0 Times in 0 Posts
Rep Power: 0
Leszek.T is on a distinguished road
Default

The idea is to make Your life easier so Nano and Pico are good for that. However a sysadmin has to be flexible and that means being ready to manage a system without nano. Vim is statistically present on most systems by default or installed by an admin that got used to it. For a person that would get to know it it's a handy and powerful tool.
Reply With Quote
  #10 (permalink)  
Old 11-17-2009, 11:06 PM
dreamer's Avatar
Junior Member
User
 
Join Date: Nov 2009
Location: LK , Kandy
OS: REHL / DREAM / ...etc
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
dreamer is on a distinguished road
Send a message via Yahoo to dreamer
Post hmmmmmm

touch filename.txt
vi filename.txt
Reply With Quote
Reply

Tags
learn unix text editor , learn vi , learn vim , linux , mcedit , unix , vim , vim tutorial , vimtutor


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

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 On
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
vim editor jithendra Linux software 1 09-05-2008 03:09 PM


All times are GMT +5.5. The time now is 01:12 AM.


Powered by vBulletin® Version 3.8.4 - Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
©2005-2009 nixCraft. All rights reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38