Archive for the ‘Software’ Category.

Subversion+websvn on Debian

To get subversion+apache2 work on Debian is not very difficult. Basically including the following steps (ref: this post): Continue reading ‘Subversion+websvn on Debian’ »

通过Samba在VirtualBox的guest和host间共享目录

Virtualbox支持客户机和宿主机之间共享目录,但是根据版本不同,会有些问题。例如对于3.1.x版本,windows XP host和Debian guest组合下,VBox自己的共享目录(写入)性能极差甚至报错(本人遇到)。其实,在客户机和宿主机之间共享文件的还有一些其他方式,例如可以通过ftp或samba,二者都支持所有操作系统下的共享,但是相比之下samba更具优点,因为在Windows和Linux下都可以把Samba共享目录映射为本地磁盘目录。

Continue reading ‘通过Samba在VirtualBox的guest和host间共享目录’ »

Where to download xulrunner-1.8.1.3 (or older version)?

The download link of this version on the Mozilla webpage has broken.
But you can find it here.

Bash下的目录回退

Bash下可以使用”cd -”来实现在当前目录和上一次访问的路径间切换。 如果我们需要回退多级目录怎么实现呢?

Continue reading ‘Bash下的目录回退’ »

Control file extensions of Notepad2

By default Notepad2 add a .txt extension to the file name when you save a newly created file. For files already having extensions, this will not be done. However, this is sometimes annoying if you often create files which do not use txt as extension although they are actually plain text files. I think this is almost a daily work for programmers. To cancel this feature, there are two ways. First, when you save the newly created file, simply add quote symbols around the file name like “new_file”, then the file will be save without an extension or with any extension you give. This trick also works for the Windows Notepad program. Another hack is to modify notepad2.ini, there you can create a new section (if it’s not there already) named “[settings2]“. The settings given in this section will override the default behavior. Then add an entry “DefaultExtension=”, yeah just leave nothing behind the equal sign, no suffix will be appended automatically then. There are more options for the customized section, see here.

Continue reading ‘Control file extensions of Notepad2’ »

Killer apps to tidy up html files and make Ebook

I’ve tried to download many freeware or trial versions in order to convert lots of html files downloaded from internet into some Ebook format, such as chm or pdf. Unfortunately and surprisingly none of them is satisfactory. Some cracked commercial software do exist, but I don’t like to be a victim of Trojan.

Continue reading ‘Killer apps to tidy up html files and make Ebook’ »

Get random numbers under BASH and DOS

Both Linux Bash and Windows DOS support random number generation. The random number is ‘stored’ in a system environment variable named “RANDOM” (I believe this variable links to a script to generate the actual random numbers on both systems), use it in the same way as you use other ENV variables.  E.g.

Continue reading ‘Get random numbers under BASH and DOS’ »

SSH tunneling and example Python client-server codes

This document demonstrates how we could run client-server software via SSH. The main purpose of using this technique relies on that on most HPC servers most of the IP ports are nromally blocked except for the SSH port 22.

  1. SSH tunneling settings in PuTTY
    In this case, the server port 8888 is mapped to the local port 7777. The meaing of this is simple: once connected to the server using PuTTY, any data on the server sent/received at port 8888 will be redirect to the port 7777 of the local machine (the computer you are using PuTTY at the moment). As a result, any client software running on the client computer can communicate with the server program via the local port 7777.
    Continue reading ‘SSH tunneling and example Python client-server codes’ »

LAMMPS has no API document

According to this thread, LAMMPS has no API document available for developers, which is a pity! Similar discuss can be found for Gromacs here, which tells there is no API document neither. Both of them are powerful simulation codes and can be used as libraries, but apparently this is not the encouraged usage. Although in the official user manuals, extending methods are discussed more or less, but those are far from enough to fully get the ideas of the design and architecture of the sophisticated packages. People (developers) often have to turn to the mailing lists and hope to get peer help from other users, which can be misleading without the help from the original software designers. On the other hand, if complete API documents are available for the end users, I believe the community and the software itself will thrive rapidly and become much stronger.

Drag URL to Bookmark bar in Firefox 3.5+

After changing to Firefox 3.5, I could not bookmark an URL simply by dragging  and dropping it onto the bookmark bar, which was the way I liked. In fact, this functionality is still there. But only when you know it you will find it’s so simple. This post tells the trick. You just have to drag the little icon next the URL instead of dragging the URL itself. See the following picture:

Continue reading ‘Drag URL to Bookmark bar in Firefox 3.5+’ »