install VI and remove VIM

If none of the more specific forums is the right place to ask

install VI and remove VIM

Postby mfaridi » 2015-07-09 17:58

I want remove VIM and install VI , what I must do ?
life is linux and debian is live
mfaridi
 
Posts: 141
Joined: 2005-04-21 07:48
Location: Afghanistan

Re: install VI and remove VIM

Postby Head_on_a_Stick » 2015-07-09 18:12

Code: Select all
# apt-get purge vim

vi should already be installed.
I suffer from depression and may lash out occasionally, try not to take it personally.
User avatar
Head_on_a_Stick
 
Posts: 8175
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: install VI and remove VIM

Postby aicardi » 2015-07-09 18:29

vi should already be installed.

I think it's actually tiny-vim

You will only get a "vi" clone in Linux.
Jessie/Xfce
User avatar
aicardi
 
Posts: 388
Joined: 2009-11-18 01:30
Location: Chicago

Re: install VI and remove VIM

Postby GarryRicketson » 2015-07-09 18:32

This would depend on what version of Debian, if the OP is using Debian,
on my Wheezy, " vi " is the default, that came with the installation, and runs s "vim" but,
if I enter "vim",
Code: Select all
$ vim
bash: vim: command not found
 


But interesting, on Jessie I typed "vi" at the prompt, and got this:
[quote] Vim-vi improved , running in vi compatable mode [/code]
and if I type in "vi" I get the "command not found,...
I don't know that it would be wise to remove "Vim" from Jessie, the vi editor might not run.
H_O_A_S know more about this then me, my main point is we don't know what version
of debian the OP is using ,(or at least I don't) since they did not include that info.
And it appears, the vi is default in wheezy, but vim is being used in Jessie.
User avatar
GarryRicketson
 
Posts: 5166
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: install VI and remove VIM

Postby Head_on_a_Stick » 2015-07-09 18:35

@Garry -- what is the output of:
Code: Select all
ls -l $(which vi)

In your systems?

I'm in OpenBSD atm so I can't check...
I suffer from depression and may lash out occasionally, try not to take it personally.
User avatar
Head_on_a_Stick
 
Posts: 8175
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: install VI and remove VIM

Postby GarryRicketson » 2015-07-09 18:41

This the output: On the Jessie
Code: Select all
garry@debian8:~$ ls -l $(which vi)
lrwxrwxrwx 1 root root 20 Jun  6 20:04 /usr/bin/vi -> /etc/alternatives/vi
User avatar
GarryRicketson
 
Posts: 5166
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: install VI and remove VIM

Postby Head_on_a_Stick » 2015-07-09 18:44

Hmmm....

What happens if you:
Code: Select all
# update-alternatives --config vi

What choices does it give you?
I suffer from depression and may lash out occasionally, try not to take it personally.
User avatar
Head_on_a_Stick
 
Posts: 8175
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: install VI and remove VIM

Postby mfaridi » 2015-07-09 18:47

when I run this commad
Code: Select all
ls -l $(which vi)

I see this
Code: Select all
root@debian-mfaridi:/home/mostafa# ls -l $(which vi)
lrwxrwxrwx 1 root root 20 May 13 10:32 /usr/bin/vi -> /etc/alternatives/vi
life is linux and debian is live
mfaridi
 
Posts: 141
Joined: 2005-04-21 07:48
Location: Afghanistan

Re: install VI and remove VIM

Postby GarryRicketson » 2015-07-09 18:49

interesting :
Code: Select all
garry@debian8:~$ update-alternatives --config vi
There is only one alternative in link group vi (providing /usr/bin/vi): /usr/bin/vim.tiny
Nothing to configure.
garry@debian8:~$
 

The command "vim" will not work, "vi" does
Code: Select all
garry@debian8:~$ vi
garry@debian8:~$ vim
bash: vim: command not found
 

and here is what the editer says:
Code: Select all
               VIM - Vi IMproved                               
~                                                                               
~                               version 7.4.576                                 
~                           by Bram Moolenaar et al.                           
~           Modified by pkg-vim-maintainers@lists.alioth.debian.org             
~                 Vim is open source and freely distributable                   
~                                                                               
~                           Sponsor Vim development!                           
~                type  :help sponsor<Enter>    for information                 
~                                                                               
~                type  :q<Enter>               to exit                         
~                type  :help<Enter>  or  <F1>  for on-line help                 
~                type  :help version7<Enter>   for version info                 
~                                                                               
~                        Running in Vi compatible mode                         
~                type  :set nocp<Enter>        for Vim defaults                 
~                type  :help cp-default<Enter> for info on this     
User avatar
GarryRicketson
 
Posts: 5166
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: install VI and remove VIM

Postby Head_on_a_Stick » 2015-07-09 18:57

^ So in jessie, vim.tiny is used for `vi` & vim proper is needed for `vim`

Therefore: @OP -- my original command will do what you want (ie, remove vim and leave vim.tiny as a `vi` substitute).

The situation is similar to /bin/sh -- this is provided by DASH (in Debian) or BASH (other distributions) in GNU/Linux but the BSDs get the "real thing"...

BSD rocks!
:P

EDIT: Try nvi -- this is a clone of the original BSD vi editor.
I suffer from depression and may lash out occasionally, try not to take it personally.
User avatar
Head_on_a_Stick
 
Posts: 8175
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: install VI and remove VIM

Postby aicardi » 2015-07-09 19:05

GarryRicketson wrote:This would depend on what version of Debian, if the OP is using Debian,
on my Wheezy, " vi " is the default, that came with the installation, and runs s "vim" but,
if I enter "vim",
Code: Select all
$ vim
bash: vim: command not found
 

"vi" is just an alias to the vi clone.
Try entering vim-gtk, or vim-gnome
The original UNIX visual editor "vi" was closed source, so clones were created. Just pick the one you want.
If you are looking for one that is closest to the original UNIX visual editor "vi", then nvi would be it.
Here are some of the others.
nvi
elvis
vile
vim
Jessie/Xfce
User avatar
aicardi
 
Posts: 388
Joined: 2009-11-18 01:30
Location: Chicago

Re: install VI and remove VIM

Postby aicardi » 2015-07-09 19:13

Head_on_a_Stick wrote: BSDs get the "real thing"...

BSD rocks!


Most likely you have nvi.
That's what NetBSD has.

Edit: Actually OpenBSD uses bvi. bvi-1.4.0 – binary visual display editor, based on vi
Jessie/Xfce
User avatar
aicardi
 
Posts: 388
Joined: 2009-11-18 01:30
Location: Chicago

Re: install VI and remove VIM

Postby Head_on_a_Stick » 2015-07-09 19:20

^ Ah, thank you.

I'm still pretty n00b with the BSDs...
I suffer from depression and may lash out occasionally, try not to take it personally.
User avatar
Head_on_a_Stick
 
Posts: 8175
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: install VI and remove VIM

Postby aicardi » 2015-07-09 19:30

Head_on_a_Stick wrote:^ Ah, thank you.

I'm still pretty n00b with the BSDs...


All are the real thing. They are based on the original closed source visual editor called vi.
Personally I like vim (vi improved) vim-gtk. Lots of nice features.
However I just use the default nvi on NetBSD.
Jessie/Xfce
User avatar
aicardi
 
Posts: 388
Joined: 2009-11-18 01:30
Location: Chicago


Return to General Questions

Who is online

Users browsing this forum: No registered users and 5 guests

fashionable