Cheatsheets

共 57 篇文章。

For those who just migrate from RedHat Linux...

• Cheatsheets

Just for fun:

Add the following to your /etc/csh.cshrc:
setenv LSCOLORS ExGxFxdxCxegedabagExEx
setenv CLICOLOR yes
set prompt = ‘[%B%n@%m%b] %B%~%b%# ’
set autolist
bindkey “^W” backward-delete-word
bindkey -k up history-search-backward
bindkey -k down history-search-forward

And execute:
sed -i.bak -E s/set\ prompt/#set\ prompt/g /root/.cshrc

Then re login.

参与评论

Useful sed(1) regular expressions

• Cheatsheets

Source code cleanup:

sed -i '' -E s/\ \	/\	/g *.c *.h
sed -i '' -E s/^\ \ \ \ \ \ \ \ /\	/g *.c *.h
sed -i '' -E s/\	\ \ \ \ \ \ \ \ /\	\	/g *.c *.h
sed -i '' -E s/\ +\$//g *.c *.h
阅读全文… ( 本文约 76 字,阅读大致需要 1 分钟 )

Two Powerful UNIX(R) command lines

• Cheatsheets

Top ten established HTTP connection from IP to our box: (IP=127.0.0.1)

netstat -na | grep “127\.0\.0\.1\.80 " | grep ESTABLISHED | cut -c43- |cut -f1-4 -d’.’ | sort | uniq -c | sort -nr | head -10

Merge FreeBSD-CURRENT changes to delphijfork:
retag `cvs -d /home/fcvs rdiff -rHEAD -rDELPHIJ_FORK_LASTMERGE src | grep Index: | awk ‘{print $2;}’ | grep src`

参与评论

Resolution of Windows Update 0x80000007d Exception

• Cheatsheets

A Dell Latitude D600 computer with Windows 2003 Server Enterprise Edition is experiencing problem when installing Windows Update from website. By downloading the hotfix, and trying to install it, it fails with “Data Error, 0x8000007d”

阅读全文… ( 本文约 109 字,阅读大致需要 1 分钟 )

My personal mutt configuration

• Cheatsheets

Mutt is a text driven Mail User Agent (MUA). It supports many useful features, including IMAP/POP3 (even TLS) support, and it is very neat.

Here is my configuration file.

阅读全文… ( 本文约 381 字,阅读大致需要 1 分钟 )