Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

Tuesday, March 06, 2007

FVWM-Crystal

I have tried some window managers these days, such as Beryl and FVWM. The 3D effect of Beryl is really astonishing but its requirement is too high. Finally I found fvwm-crystal. It is both nice looking and light-weighted. I like it.

However, I found the fvwm-crystal project is not well documented. Here are some tips for the configuration of fvwm-crystal.

* fvwm-crystal is actually a nice configuration of fvwm with some handy small tools. So almost all the configuration for fvwm can be used directly on fvwm-crystal.

* The user configuration file is stored in ~/.fvwm-crystal/userconfig (for fvwm-crystal 3.0.4 and above). The configuration file for fvwm-crystal 3.0.3 and below is still in ~/.fvwm/ .

* The most default key bindings are Meta- or Meta-Shift- which conflict with Emacs key bindings. So I have to disable them all like this:
Key 1 A MS - # disable M-S-1
Key X A M - # disable M-x

The default key bindings are in /usr/local/share/fvwm-crystal/fvwm/components/bindings/ .

* Font set. The default font is Verdana. So the multibyte characters are not able to be displayed correctly. I have to change it to font like Vera Sans YuanTi. The window title bar font configuration is:
Style * Font "Shadow=1 1:StringEncoding=gbk-0:xft:Vera Sans YuanTi:Bold:pixelsize=12:minspace=True:encoding=iso10646-1"

* I think 8 virtual desktops are too many. So change it to 6:
DeskTopSize 6x1

* The "suspend" in the main menu doesn't work quite well. It will logout and then suspend to memory. I use Fn+F4 on my ThinkPad instead. This works fine. Maybe you need to install xscreensaver.

* Removable devices can't be auto mounted as in GNOME. You can install ivman and put the following line into ~/.bashrc:
ivman --nofork > /dev/null 2>&1 &
Here is some more information about how to auto mount removable devices.

* KDE applications such as Amarok and Kopete don't stay in trayer. You may need to start Amarok this way:
amarok
dcop kded kded loadModule kdetrayproxy
After that, other kde apps like Kopete will stay in trayer as well. However, I have tried to put the second line in to InitFunction or StartFunction but it doesn't work.

* Some startup applications. You can add startup apps like this:
AddToFunc InitFunction
+ I Exec exec dcop kded kded loadModule kdetrayproxy
+ I Test (x gkrellm) Exec pidof gkrellm || exec gkrellm
+ I Test (x update-notifier) Exec exec update-notifier
+ I Test (x gdeskcal) X gdeskcal

***

Monday, July 17, 2006

Free Linux CDs


TheLinuxStore.ca 正在进行一项新的计划,将 Linux和开源软件传送到全世界。你将可以免费获得你所喜欢的Linux光盘包括SUSE, Fedora, Mandriva, Gentoo, Debian, Knoppix。其他的软件(当然是开源的)也可以写上。当然愿意的话你也可以捐助几美元来获取它。

Related links:
solidot新闻


del.icio.us Tags:

Monday, May 08, 2006

Install Firefox 1.5 on Ubuntu

在ubuntu上安装或升级Firefox

Firefox不能用apt-get install来安装(bt, 为什么不行)。所以要从Mozilla.com上下载Firefox. 由于编译的gcc版本不同,导致这个Firefox和中文输入法SCIM有冲突。wiki.ubuntu.com上推荐下载源码并重新编译Firefox。我试过之后发现启动Firefox的时候,提示缺少一个库,有错误产生。

在Ubuntu中文wiki上倒是有很好的解决方法
译注:由于scim可能导致使用libstdc++5的GTK程序出现"段错误",如果出现新装的firefox1.5无法运行,可修改 export GTK_IM_MODULE="scim"为GTK_IM_MODULE="xim" 来绕过,这句一般在/etc/X11/Xsession.d/95xinput中.(catinsnow)

安装完后的配置极其方便,只要把windows里的配置文件(C:\Documents and Settings\user_name\Application Data\Mozilla\Firefox\Profiles\xxxxxxxx.default)直接复制到Linux里就可以了(~/.mozilla/firefox/profiles)。所有的收藏夹、扩展、及其配置全部都有了,甚至包括原先保存的密码。当然复制之前可以先清除cookie减小体积。



del.icio.us Tags:

Friday, May 05, 2006

干掉和重建Grub

干掉和重建Grub

装了ubuntu,Grub是装在MBR的。有一次从Windows XP休眠,再次开机后就无法进入Windows,情况是:在Grub list 选择Windows,然后回到Grub list。进入ubuntu没有问题。

当时手头有张Win XP恢复盘(德语),比较土,以前没有用过。从光盘启动后,没有任何停顿,没有任何选项,开始嘎叽嘎叽地安装了。新的Windows是装在D盘的。我不想有两个XP,安装过程中强行关机了。再次开机后只有windows自己的boot list了。选了老的那个,直接把D的windows目录删除,再把C盘下的boot.ini改成只有C盘的Windows。重启后一切正常,只不过开机过程中的语言成了德语。比较郁闷,这个语言是在哪里改的?

用ubuntu安装盘重装Grub。没有Suse的recovery那么简单。
  • 在boot提示行输入rescue
  • 之后就好像要重新安装ubuntu一样,选择语言、地区、键盘等。
  • 然后是配置网络,设置主机名,这些都可以随便设。
  • 然后出来一个分区表,选择原先的ubuntu分区,格式是 dev/discs/disc0/partX. X是1到n,可以一个个试过来,如果不是linux分区,会有错误提示,然后返回。选择linux分区之后进入# 命令行。
  • 输入 # grub-install /dev/sda 重装Grub,有些机器是/dev/hda (?)。
  • 之后有个警告,可以去 /boot/grub/device.map 查看原先是把grub装在哪里的。
  • 最后 # exit,重启,Grub菜单又回来了。
整个过程不到10分钟。

后来又重试了几次,发现windows休眠后的重启仍然正常。又试了一下fdisk /MBR,对于windows启动来说是绝对安全的。比较BT的是,用XP安装盘的恢复模式进入DOS命令行(实际上不是dos?)没有fdisk这个命令。要fdisk /MBR 只能用其他的dos启动盘。
del.icio.us Tags:

Thursday, May 04, 2006

一些Linux应用程序

一些Linux应用程序

来源:王垠的《完全用Linux工作& 处理日常事务的 Linux 程序和它们的配置
  • Shell: bash。它结合了 csh 和 ksh 的优点,并且有 readline 功能,你可以随意绑定自己的键盘。
  • 编辑器: VIM, Emacs。
  • 程序开发: GCC, make, ld, Scheme48, j2sdk, Perl, Python, Tcl/Tk ...
  • 论文,幻灯工具:LaTeX, ConTeXt
  • 绘图工具:MetaPost。这个语言太强了,以至于我只用它了。你不熟悉的话可以用xfig, dia 来画一些流程图之类的图片。
  • 图像处理:ImageMagick。其中的 import 程序可以屏幕抓图,convert 程序可以转换图像格式,display 可以显示图片和简单编辑(缩放,换质量,转格式,简单绘图,简单虑镜)。通常我就这么点需要。如果你要更强大的图像工具可以用 Gimp, 它几乎和Photoshop差不多。
  • 自动管理工具:make。我可以用make来自动编译程序,自动编译文档,自动更新插图…… 全自动,而且不会重复劳动。
  • 数值计算程序:SciLab。这个程序基本上可以代替 Matlab。
  • 代数计算程序:MAXIMA。这个程序基于世界上最老的计算机代数系统之一: 由美国能源部(DOE)发行的 MIT Macsyma 系统。它是用 Common Lisp 实现的。很多现在的符号计算程序比如 Maple 都从 MAXIMA 身上学到很多东西。它现在经过 DOE 批准以GPL发行,永远是一个自由软件。
  • 加密程序:GnuPG。我的 PGP 密钥就是它搞出来的。
  • 打包,压缩程序。什么都有: tar, gzip, bzip2, zip, rar, ...
  • 虚拟光驱程序。Linux 不需要虚拟光驱程序,直接 mount 就行了。
  • ftp 服务器:proftpd, vsftpd。proftpd 功能很强,但是我只用了最简单的一种设置。
  • WWW 服务器:apache。(我一般没有开)
  • ftp 客户程序:lftp,ncftp。它们都是文本方式操作的,但是比起图形界面的方便的多。比如 lftp 几乎具有 bash 的所有方便功能,Tab 补全,bookmark, queue, 后台下载,镜像…… Linux 也有图形界面的 ftp 客户程序,但是大多不稳定,有很多问题。这就是很多人抱怨 Linux 不如 Windows 的一个小原因。还有很多人用 Wine 模拟 Windows 的leapftp,其实 lftp 比 leapftp 好很多,你需要的只是适应一下。
  • 自动下载工具:wget。它非常稳定,有一次我下载一个程序,用 IE 和 Mozilla 下载回来的文件都是坏的,最后还是 wget 可靠的传输了数据。用它甚至可以镜像整个网站,比起WebZip 这样的 Windows 程序强多了,而且不会因为你不付钱就在下载回来的网页里强制插入广告。
  • 虚拟终端:rxvt, xterm, gnome-terminal, mlterm, ...
  • X server: XFree86
  • 窗口管理器:FVWM。编译加入了 libstroke。
  • 中文输入:XSIM。被我修改过以适应 FVWM 的需要。另外推荐你还可以用 SCIM。
  • email 处理:Mutt + Postfix + fetchmail
  • 看 PDF, PS, DJVU 文件:Acrobat Reader, xpdf, GhostScript, gv, djvu工具包和netscape 插件。
  • 看CAJ文档。我从来不看CAJ之类的文档,如果找不到PDF或PS,直接去图书馆借最好。
  • 看网页:Mozilla, Phoenix, lynx。Mozilla-Xft 的显示效果比IE 好很多。
  • 英汉字典:IBM智能词典,星际译王。
  • 编辑网页:我用VIM 直接写 HTML。你如果想要图形方式的可以用其它的比如screem, BlueFish。
  • 登录其它 UNIX, Linux 机器:openSSH, telnet。 我喜欢用 openSSH 把其它机器的X 程序通过 ssh 加密的隧道传到我机器上显示。
  • 登录 Windows2000 server 的 display service: rdesktop,...我有一天试了一下,不错。后来就没有用过了。
  • 同步程序:rsync。我用 rsync 通过 ssh 来跟某些机器同步数据,或者做自己机器上不同目录间的同步。
  • 上BBS:rxvt(或任何一种终端) + telnet + chatbot(helloooo 机器人的程序)
  • QQ, ICQ: 我没有 QQ 或 ICQ。不过你可以用 Gaim, 它同时支持 QQ, ICQ 和很多其它的即时通信方式。ICQ 用户也可以用 Licq。
  • 放录像:MPlayer, RealPlayer。MPlayer 太好了,直接就可以放 VCD, DVD, divx, wma, wmv ... 用 Windows 的同学都很羡慕我,说 Windows 要放这个需要大堆插件。rm 最好还是用 realplayer 放,它也是免费的。
  • 放音乐: xmms(mp3,ogg都可以), mpg321(放mp3), ogg123(放ogg)。mpg321 不如xmms管理音乐文件那么方便,但是有时我还是用 mpg321 放 mp3 作为背景音乐,因为懒得开一个xmms窗口:-)
  • 游戏:我觉得 KDE 的那个 ksokoban(推箱子),很好玩 :-)
  • 看 Word 文档。请 Word 用户把文档全部转为 PDF 或 PS 再给我,文档里没有特殊的格式干脆就用文本吧,何必那么麻烦。以前很奇怪的是,通知里本来没有什么特殊的格式居然还要发doc附件的email。现在好 了,我们系发通知都用文本,PDF,甚至图片了。
  • 其它程序:还有很多我需要用而你不一定用得着的。比如,Doctor Scheme,
  • Scheme48, Scsh, kawa...这些程序只有 Doctor Scheme 有Windows版本。还有很多幕后工作但是你一般不察觉的:xinetd, telnetd, sshd, crond, atd, lpd, ... 他们都比 Windows 的对应者强的多,或者根本没有对应者。
后续
del.icio.us Tags:

Tuesday, May 02, 2006

Proxy setting for ubuntu 5.10 GUI Update Manager

Proxy setting for ubuntu 5.10 Update Manager:

Set proxies in Gnome "Network Proxy Setting", or in /etc/bash.bashrc, or /etc/wget.rc won't apply to Update Manager.
You had to put a line like this in /etc/apt/apt.conf

Acquire::http::Proxy "http://proxy.mydomain.com:8080"


In "Breezy Badger" you must edit apt.conf as follows:

Acquire
{
http::proxy "http://proxy.mydomain.com:8080"
}
del.icio.us Tags: