有人说Emacs和VI是一种信仰,也有人说世界上有三种程序员,用Emacs的,用VIM的,还有就是用其他编辑器的。
首先,肯定了Emacs和VIM仅仅是一种Editor而已,而非IDE,如果你偏要说是IDE,那我也没有办法了,你说的肯定是结合各种外部工具和脚本插件,但是即使这样,Emacs和VIM真的比Eclipse这样现代的IDE好用吗?我看不见得,有人把Emacs和VIM神化了,觉得它们真的是无所不能,可我还是要说,选择最合适你的编辑器而别迷信而虐待自己。就Editor功能而言,它们如果用熟了,可以完全脱离鼠标工作,用VIM用了很多年了,基本上处理日常的编辑工作没有问题,做系统管理时VIM是唯一的选择,服务器上都没有X Windows的,说到这里,又想起一句话,有人说真正的系统管理员只用命令行,而真正的程序员都只用VIM和Emacs。但是对于现代计算机的运行速度,双核CPU,2G以上内存,告诉硬盘的计算机,用Eclipse就真的性能那么不可接受?我看也不见得,而Eclipse之类的IDE的智能感知功能,这可不是Emacs或者VIM可以做得“好”的,也许有人要说高手不用智能感知,甚至嫌智能感知慢,麻烦,那这肯定是高高手了,我佩服;可是对于Java,Python这种有强大类库的语言,要记住所有库函数,得要做多久才可以记住?如果有智能感知功能,作开发,特别是遇到不熟悉的函数调用,那简直是一种享受,这也可以大大加速对于新语言类库的熟悉,所以做java之类的开发还是不要逼着自己用Emacs,VIM之类吧。我发出这样的感言是源于我最近在学习Emacs,VIM用得多了之后,虽然感觉很好,但是对于必须要ctags才能生成函数列表的功能让我有些不满意,所以想学一下Emacs,可是搜遍了网络,自动补全的效果也不是很理想,所以决定不在在这个问题上纠缠了,多写两行代码吧
2008年9月18日星期四
2008年9月5日星期五
Freetds on Arch Linux
今天把一个在ubuntu服务器上运行得很好的报表程序拖回到我的Arch Linux上发现运行不了,pymssql报错,首先以为是pymssql的问题,重新编译了还是不行,怀疑是freetds的问题,以为是更新了gcc和glibc造成问题,遂重新编译了freetds,用tsql测试也不行。问题就应该是出在freetds上了.仔细看了freetds的文档,知道了freetds默认的协议版本是5.0,可以在编译时通过--with-tdsver指定,也可以通过freetds.conf或者环境变量$TDSVER设置。我连接的是sql server 2000,TDSVER设置到8.0,果然好了。看来用Arch Linux还是等多动个心眼。
2008年9月4日星期四
注意Arch Linux服务的启动顺序
Arch Linux的启动脚本设计得非常简单,也很有意思,所有的配置在全部在rc.conf里面做了,在设置上没有传统Linux的启动分级的概念了,这点比gentoo还简化了,gentoo虽然做了简化,但也还分了boot和default。还有就是Arch Linux启动脚本的顺序需要你在rc.conf里面做好,它按照你在DAEMONS里面写的顺序启动,而不是像传统的Linux一样通过在脚本前面加数字前缀来决定启动顺序的,这点如果不注意的话容易造成问题。我们通常习惯一直在DEAMONS后面加下去,而不是自己知道这个顺序。我自己就由于添加了解服务CUPS放在GDM后面启动了,所以造成启动后,窗口上有个黑点去不掉,想来想去就是这点改动了,调了一下顺序就好了。所以以后千万要主义了,还好这些是没有关联的服务,对于有严格顺序的关联服务如果不注意就可能启动不了。
我是越来越喜欢这个Linux,从Ubuntu转过来,确实花了不少时间,很多的配置都是参照Ubutnu做的,比如字体配置,hal磁盘挂载,真是应了一句话“用Ubuntu的人用了Arch,才知道Arch比Ubuntu确实快不少;用Arch的人用Ubutnu,才知道Ubuntu帮我们做了多少不简单的事”。原来担心它的软件没有ubuntu库里面多,但是AUR里面基本上什么都包含了,不过很多没有跟随着更新,还好Arch的ABS机制很简单,所以自己修改一下PKGBUILD也就没有问题了。这里提几个我自己遇到的,配置打印机时,HP larserJet 1000要用到的foo2zjs,PKGBUILD中md5sum错了,要改了才能继续编译,splashy的依赖错了,要自己改到directfb-1.2,具体要改splashy.initcpio_install,还有一个zlib的问题,arch中libz.so放在/usr/lib/而不是/lib中,也需要在上面文件中改一下。
我是越来越喜欢这个Linux,从Ubuntu转过来,确实花了不少时间,很多的配置都是参照Ubutnu做的,比如字体配置,hal磁盘挂载,真是应了一句话“用Ubuntu的人用了Arch,才知道Arch比Ubuntu确实快不少;用Arch的人用Ubutnu,才知道Ubuntu帮我们做了多少不简单的事”。原来担心它的软件没有ubuntu库里面多,但是AUR里面基本上什么都包含了,不过很多没有跟随着更新,还好Arch的ABS机制很简单,所以自己修改一下PKGBUILD也就没有问题了。这里提几个我自己遇到的,配置打印机时,HP larserJet 1000要用到的foo2zjs,PKGBUILD中md5sum错了,要改了才能继续编译,splashy的依赖错了,要自己改到directfb-1.2,具体要改splashy.initcpio_install,还有一个zlib的问题,arch中libz.so放在/usr/lib/而不是/lib中,也需要在上面文件中改一下。
2008年8月31日星期日
Quick Arch Configuration Note
There are some steps to make Arch Linux work better for you:
----------------------------
#locale
(1) Edit /etc/locale.gen to enable the locales you need
(2) run locale-gen as root to generate locales
#fontconfig
(1) install the required TTF fonts
(2) edit /etc/fonts/local.conf, add your favorite settings
(3) edit java fontconfig setting in /opt/java/jre/lib/fontconfig.properties
#disk mount in GUI
add youself to the storage, optical group
#solve the Chinese problem of USB disk mount
add iocharset=utf8 in the gconf-/system/storage/default-options/vfat
#alsa config
(1) alsactl store to save the alsa setting
(2) add alsa to the rc.conf daemon section
#HAL configuration
#config HAL to only automount removable disks
#file /usr/share/hal/fdi/policy/10osvender/ignore-fixed-drivers.fdi
<device>
<match key="storage.hotpluggable" bool="false">
<match key="storage.removable" bool="false">
<merge key="storage.automount_enabled_hint" type="bool">false</merge>
</match>
</match>
</device>
----------------------------
#locale
(1) Edit /etc/locale.gen to enable the locales you need
(2) run locale-gen as root to generate locales
#fontconfig
(1) install the required TTF fonts
(2) edit /etc/fonts/local.conf, add your favorite settings
(3) edit java fontconfig setting in /opt/java/jre/lib/fontconfig.properties
#disk mount in GUI
add youself to the storage, optical group
#solve the Chinese problem of USB disk mount
add iocharset=utf8 in the gconf-/system/storage/default-options/vfat
#alsa config
(1) alsactl store to save the alsa setting
(2) add alsa to the rc.conf daemon section
#HAL configuration
#config HAL to only automount removable disks
#file /usr/share/hal/fdi/policy/10osvender/ignore-fixed-drivers.fdi
<device>
<match key="storage.hotpluggable" bool="false">
<match key="storage.removable" bool="false">
<merge key="storage.automount_enabled_hint" type="bool">false</merge>
</match>
</match>
</device>
2008年8月8日星期五
使用Gentoo2008作为系统维护盘
以前一直习惯使用Gentoo作为系统维护盘,不管是Linux还是Windows维护,不管是修复系统还是备份数据。但是以前的Gentoo Live CD不可以操作NTFS分区,所以遇到XP系统等使用NTFS分区的系统就无能为力了。我期间使用过Ubuntu,Puppy Linux代替过。但是总是觉得不爽,Ubuntu启动到桌面太久了,Puppy Linux有的时候会遇到兼容性的问题,有些电脑启动不起来,也挂不了硬盘。今天帮朋友恢复装Vista SP1损坏的系统,他用的HP的机器,所有的数据都默认在C盘了,System Restore没有作用,还原点不能用,只有可能恢复到出厂模式,但是这样就必须先把C盘上的数据先导出来。首先还是尝试了手头上就有的Ubuntu Desktop CD,但是太慢,简直不可接受。好久没有关注Gentoo的动态了,从网站上一查,得知Gentoo 2008 Live CD已经支持了NTFS读写了,太爽了。又可以用熟悉的Gentoo做系统恢复盘了。并且由于不要图形界面,可以节省大量的内存,所以拷贝文件比Ubuntu快多了,实在是救了我,他有120G的数据需要备份出来,看来我这次等帮他重新分一下区才可以。否则,下次,最好是没有下次了,简直太难受了。这么多数据,我的移动硬盘一个区只有40G,老鼠搬家了3次才把数据转移完。
2008年8月4日星期一
The new life with Arch
Arch linux is good for me, the bigest advantage of Arch Linux is that, it can upgrade the system to another version very smoothly, just like gentoo. I really love gentoo, but the compilation is painful.
Here is my software list:
Gnome - the desktop environment
openoffice - for the office application
gnome-terminal - a muti-language terminal emulator
file-roller - the GUI frontend of zip and unzip
audacious - it can support chinese mp3 tag
totem-xine - for videos and movies
Brasero - the CD burner
Firefox - the browser
Filezilla - the FTP client
FreeMind - the mind map tool
ArgoUML - the UML drawing tool
Komodo Edit 4 - the web development
gThumb - the picture management tool
GIMP - the *photoshop* of linux
LinuxQQ - realesed in 2008.7.31, by Tencent, this is the first offical Linux QQ
Emesene - I think it's the best MSN client in gnome.
Acroread - the PDF viewer from Adobe, but it cann't be found in Arch's repositories, I have to create this package by myself.
-----
Thanks to all the bright programers who created these wonderful programs.
Here is my software list:
Gnome - the desktop environment
openoffice - for the office application
gnome-terminal - a muti-language terminal emulator
file-roller - the GUI frontend of zip and unzip
audacious - it can support chinese mp3 tag
totem-xine - for videos and movies
Brasero - the CD burner
Firefox - the browser
Filezilla - the FTP client
FreeMind - the mind map tool
ArgoUML - the UML drawing tool
Komodo Edit 4 - the web development
gThumb - the picture management tool
GIMP - the *photoshop* of linux
LinuxQQ - realesed in 2008.7.31, by Tencent, this is the first offical Linux QQ
Emesene - I think it's the best MSN client in gnome.
Acroread - the PDF viewer from Adobe, but it cann't be found in Arch's repositories, I have to create this package by myself.
-----
Thanks to all the bright programers who created these wonderful programs.
2008年8月3日星期日
Tryed the KDE for a while and I am back to Gnome again
To the KDE users: This post is just based on my experience, may be I am not very familiar with the KDE, so please keep calm :)
Since I have been a Linux user, Gnome is always the desktop evironment of my computer, the exception is on one of my old machine, I use fvwm instead. That's not suprise, because gnome is the defaut desktop evrionment of most of big linux distributions, including Red hat, Ubuntu. Red Hat is the first linux system on my computer, about 5 years ago, and then I have used gentoo as my desktop system for about 3 years, and after graduation I used ubuntu.
Gnome is always the default desktop environment, so I never thought about to make some changes, or dedicate some of my time to another desktop environment, I mean KDE, even I known it since I tasted linux at the first bite. I even have ever tried KDE sevral times, but every time just for a glance or "play with". When I have to get start to work, I restart the GDM and enter my familiar environment - Gnome.
I tried Arch linux this week, because I want to install it to my laptop, whose CPU is not so fast. KDE4 is out, as they say, KDE4 is a great gift to the opensource community, So I think I should give me a change to try it. Anywhere, I just want to only one desktop environment installed. I tried KDE first, it beautiful, I thought I would love it. "The desktop of 21 centry", ah ha, now I have it.
But one day later, I changed my mind, because I found some problem which is rather important for me.I am a java programer, In most of my work time, I use eclipse, netbeans and some other java (develop) programs, freemind, argouml, etc. In gnome, I can get a native look and feel when I use these java programs, but in KDE, they only show the strange face to me, the java look and feel. As for as I know, in the java world, for linux, gtk is the only supported GUI lib. if you use SWT based programers you still can get a beatiful look and feel from GTK, if you have configurated the GTKRC, but with Swing, you can only get the strange java look and feel, that makes me feel uncomfortable. For the KDE4, I think it still need time to be really mature, there are so many KDE applications only available for the KDE3, e.g., I want use KMyMoney for my finance management, but it's not available for the KDE4 at this stage. I will not try to use KDE3 now, I found in KDE, the Chinese characters are not renderd clearly engough just as in Gnome.
Finally, after some carefully consideration, I decided to back to Gnome.
Since I have been a Linux user, Gnome is always the desktop evironment of my computer, the exception is on one of my old machine, I use fvwm instead. That's not suprise, because gnome is the defaut desktop evrionment of most of big linux distributions, including Red hat, Ubuntu. Red Hat is the first linux system on my computer, about 5 years ago, and then I have used gentoo as my desktop system for about 3 years, and after graduation I used ubuntu.
Gnome is always the default desktop environment, so I never thought about to make some changes, or dedicate some of my time to another desktop environment, I mean KDE, even I known it since I tasted linux at the first bite. I even have ever tried KDE sevral times, but every time just for a glance or "play with". When I have to get start to work, I restart the GDM and enter my familiar environment - Gnome.
I tried Arch linux this week, because I want to install it to my laptop, whose CPU is not so fast. KDE4 is out, as they say, KDE4 is a great gift to the opensource community, So I think I should give me a change to try it. Anywhere, I just want to only one desktop environment installed. I tried KDE first, it beautiful, I thought I would love it. "The desktop of 21 centry", ah ha, now I have it.
But one day later, I changed my mind, because I found some problem which is rather important for me.I am a java programer, In most of my work time, I use eclipse, netbeans and some other java (develop) programs, freemind, argouml, etc. In gnome, I can get a native look and feel when I use these java programs, but in KDE, they only show the strange face to me, the java look and feel. As for as I know, in the java world, for linux, gtk is the only supported GUI lib. if you use SWT based programers you still can get a beatiful look and feel from GTK, if you have configurated the GTKRC, but with Swing, you can only get the strange java look and feel, that makes me feel uncomfortable. For the KDE4, I think it still need time to be really mature, there are so many KDE applications only available for the KDE3, e.g., I want use KMyMoney for my finance management, but it's not available for the KDE4 at this stage. I will not try to use KDE3 now, I found in KDE, the Chinese characters are not renderd clearly engough just as in Gnome.
Finally, after some carefully consideration, I decided to back to Gnome.
订阅:
博文 (Atom)
