Google

Archives

Gallery

locationasia DSCN2242 DSCN2246 beijing-subway

Figure format conversion in Linux

EPS 2 PNG
Manual conversion

Open the file in the GIMP (make sure you have ghostscript installed! — Windows Ghostscript installation instructions)

Enter 500 in the “resolution” input box
You may need to uncheck “try bounding box”, since the bounding box sometimes cuts off part of the image.

Enter large values for Height and Width if not using the bounding box

Select color
Select strong anti-aliasing for [...]

Commands for Compress and Decompress

Commands for Compress and Decompress

.tar

解包: tar xvf FileName.tar
打包:tar cvf FileName.tar DirName
(注:tar是打包,不是压缩!)
———————————————

.gz

解压1:gunzip FileName.gz
解压2:gzip -d FileName.gz
压缩:gzip FileName
.tar.gz
解压:tar zxvf FileName.tar.gz
压缩:tar zcvf FileName.tar.gz DirName

———————————————

.bz2

解压1:bzip2 -d FileName.bz2
解压2:bunzip2 FileName.bz2
压缩: bzip2 -z FileName
.tar.bz2
解压:tar jxvf FileName.tar.bz2
压缩:tar jcvf FileName.tar.bz2 DirName

———————————————

.bz

解压1:bzip2 -d FileName.bz
解压2:bunzip2 FileName.bz
压缩:未知
.tar.bz
解压:tar jxvf FileName.tar.bz
压缩:未知
———————————————

.Z

解压:uncompress FileName.Z
压缩:compress FileName
.tar.Z
解压:tar Zxvf FileName.tar.Z
压缩:tar Zcvf FileName.tar.Z DirName

———————————————

.tgz

解压:tar zxvf FileName.tgz
压缩:未知
.tar.tgz
解压:tar zxvf FileName.tar.tgz
压缩:tar zcvf FileName.tar.tgz FileName
———————————————

.zip

解压:unzip FileName.zip
压缩:zip FileName.zip DirName
———————————————

.rar

解压:rar a [...]

backup and sync with lftp

lftp is an amazing  command line ftp tool, which lets you operate remote files just like in a local filesystem in a terminal (bash).  If you work a lot with command line, I bet you would like it.  A frequently used functionality with lftp is backup or sync a remote directory with a local one.

Here is [...]

vi/vim command summary

vi/vim command summary

The following tables contain all the basic vi commands.
Starting vi

Command
Description

vi file
start at line 1 of file

vi +n file
start at line n of file

vi + file
start at last line of file

vi +/pattern file
start at pattern in file

vi -r file
recover file after a system crash

Saving files and quitting vi

Command
Description

:e file
edit file (save current file with :w first)

:w
save (write out) the file being edited

:w file
save as file

:w! file
save as an existing file

:q
quit vi

:wq
save the file and [...]

Download Whole Website or Directories by using wget in Linux

Download Whole Website or Directories by using wget in Linux

You might have googled a software for downloading a specified website or directory on either Windows or Linux platform . Yes, a bunch of tools can do this for you. Actually, we can do this by using a simple command, wget, on Linux platform. It is [...]