关于Vi语法高亮显示的问题

系统安装、升级讨论
版面规则
我们都知道新人的确很菜,也喜欢抱怨,并且带有浓厚的Windows习惯,但既然在这里询问,我们就应该有责任帮助他们解决问题,而不是直接泼冷水、简单的否定或发表对解决问题没有任何帮助的帖子。乐于分享,以人为本,这正是Ubuntu的精神所在。
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

关于Vi语法高亮显示的问题

#1

帖子 Beyond2008 » 2008-06-11 21:01

Vi语法高亮显示的问题,我是初学者,请教各位大虾,怎么在ubuntu中设置Vi为高亮显示啊???
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#2

帖子 leeaman » 2008-06-11 21:07

google 一下 .vimrc 。在那个文件添加syntax on 就可以了吧
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#3

帖子 Beyond2008 » 2008-06-11 21:12

我搜了一下,是不是还要执行sudo apt-get install vim-full这个啊!!
但是我执行上面的命令的时候总是提示我has no installation candidate 为什么呢??
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#4

帖子 leeaman » 2008-06-11 21:15

Beyond2008 写了:我搜了一下,是不是还要执行sudo apt-get install vim-full这个啊!!
但是我执行上面的命令的时候总是提示我has no installation candidate 为什么呢??
你的源有问题 or 没有更新?是要装那个vim-full才支持语法高亮的
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#5

帖子 Beyond2008 » 2008-06-11 21:27

我好像以前更新过的啊!!
下载了200多个更新,你说的更新得怎么更新啊??
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#6

帖子 leeaman » 2008-06-11 21:29

update upgrade 然后再装看看,不行就贴你的源文件看看
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#7

帖子 Beyond2008 » 2008-06-11 21:34

还是不行的啊~~能说得详细一点嘛,我刚接触不太熟练啊~~~~
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#8

帖子 leeaman » 2008-06-11 21:39

代码: 全选

sudo apt-get update
sudo apt-get install vim-full
看看是什么样子
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#9

帖子 Beyond2008 » 2008-06-11 21:44

luo@luo-desktop:~$ sudo apt-get update
Ign cdrom://Ubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016) gutsy/main Translation-en_US
Ign cdrom://Ubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016) gutsy/restricted Translation-en_US
Get:1 http://archive.ubuntu.com gutsy-updates Release.gpg [191B]
Ign http://archive.ubuntu.com gutsy-updates/restricted Translation-en_US
Ign http://archive.ubuntu.com gutsy-updates/main Translation-en_US
Hit http://archive.ubuntu.com gutsy-updates Release
Hit http://archive.ubuntu.com gutsy-updates/restricted Packages
Get:2 http://security.ubuntu.com gutsy-security Release.gpg [191B]
Ign http://security.ubuntu.com gutsy-security/restricted Translation-en_US
Ign http://security.ubuntu.com gutsy-security/main Translation-en_US
Hit http://archive.ubuntu.com gutsy-updates/main Packages
Hit http://security.ubuntu.com gutsy-security Release
Hit http://security.ubuntu.com gutsy-security/restricted Packages
Hit http://security.ubuntu.com gutsy-security/main Packages
Fetched 2B in 4s (0B/s)
Reading package lists... Done
luo@luo-desktop:~$ sudo apt-get install vim-full
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package vim-full is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package vim-full has no installation candidate
luo@luo-desktop:~$



还是提示一样的错误!!
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#10

帖子 leeaman » 2008-06-11 21:47

你装的是不是7.10的?你的源是7.10的,估计是源的问题吧?
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#11

帖子 Beyond2008 » 2008-06-11 21:54

对的,我装的是7.10的,就是在网上免费从南非邮送的,那问题得怎么解决呀??
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#12

帖子 Beyond2008 » 2008-06-11 21:54

我装了好多包都提示的这个问题,可郁闷了呢!!
头像
leeaman
帖子: 30702
注册时间: 2007-02-02 18:14
系统: debian sid

#13

帖子 leeaman » 2008-06-11 21:56

Beyond2008 写了:我装了好多包都提示的这个问题,可郁闷了呢!!
把你的sources.list贴出来看看,估计是你的源不全
醉了星星,醉月亮●●●●●The Long Way To Go(*^_^*)
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#14

帖子 Beyond2008 » 2008-06-11 22:04

deb cdrom:[Ubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016)]/ gutsy main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.

# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy main restricted
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy main restricted

## Major bug fix updates produced after the final release of the
## distribution.
# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates main restricted
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## universe WILL NOT receive any review or updates from the Ubuntu security
## team.
# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy universe
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy universe
# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates universe
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy multiverse
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy multiverse
# Line commented out by installer because it failed to verify:
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates multiverse
# Line commented out by installer because it failed to verify:
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy-updates multiverse

## Uncomment the following two lines to add software from the 'backports'
## repository.
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
# deb http://cn.archive.ubuntu.com/ubuntu/ gutsy-backports main restricted universe multiverse
# deb-src http://cn.archive.ubuntu.com/ubuntu/ gutsy-backports main restricted universe multiverse

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository. This software is not part of Ubuntu, but is
## offered by Canonical and the respective vendors as a service to Ubuntu
## users.
# deb http://archive.canonical.com/ubuntu gutsy partner
# deb-src http://archive.canonical.com/ubuntu gutsy partner

# Line commented out by installer because it failed to verify:
# deb http://security.ubuntu.com/ubuntu gutsy-security main restricted
# Line commented out by installer because it failed to verify:
# deb-src http://security.ubuntu.com/ubuntu gutsy-security main restricted
# Line commented out by installer because it failed to verify:
# deb http://security.ubuntu.com/ubuntu gutsy-security universe
# Line commented out by installer because it failed to verify:
# deb-src http://security.ubuntu.com/ubuntu gutsy-security universe
# Line commented out by installer because it failed to verify:
# deb http://security.ubuntu.com/ubuntu gutsy-security multiverse
# Line commented out by installer because it failed to verify:
deb http://archive.ubuntu.com/ubuntu/ gutsy-updates restricted main
deb http://security.ubuntu.com/ubuntu/ gutsy-security restricted main
# deb-src http://security.ubuntu.com/ubuntu gutsy-security multiverse
Beyond2008
帖子: 19
注册时间: 2008-06-08 20:55

#15

帖子 Beyond2008 » 2008-06-11 22:07

http://wiki.ubuntu.org.cn/index.php?tit ... 7.E5.8D.97


我找到了这个网站,也是这个论坛的,不过我想问个问题,就是如果我在.list文件中贴了多个源的话(如果其中有重复的)那会有什么后果呢,因为我不知道缺的是那个源,所以我想在.list文件中多贴几个
回复