Archive for the ‘Tool’ Category

Latex中文配置

星期一, 10月 20th, 2008
  • Linux

从源里面安装Texlive2007(apt就是好啊),之后下载YueWang zhfonts 。解压到$HOME下的.texmf-config.texmf-var文件。
搞定。

  • Windows

还是用CTEX套装吧,别瞎折腾了。

参考
http://forum.ubuntu.org.cn/viewtopic.php?f=35&t=84013

Powered by ScribeFire.

dhcp与静态ip切换

星期六, 10月 11th, 2008

实验室用的是dhcp,寝室用的是静态ip地址,每次切换起来比较烦人,于是上网搜了一下写了个脚本。

  • Windows

寝室设置[静态ip地址]

netsh interface ip set address “本地连接” static IP 地址 子网 网关 跃点数(一般为1)
netsh interface ip set dns “本地连接”
dns地址

实验室[动态IP地址]

netsh interface ip set address “本地连接”  dhcp
netsh interface ip set address “本地连接”  dhcp

参考:

  1. 如何使用 Netsh.exe 工具和命令行开关 http://support.microsoft.com/kb/242468
  2. 如何使用 NETSH 命令在 Windows 2000 中将静态 IP 地址更改为 DHCP 地址 http://support.microsoft.com/kb/257748
  • Linux
  • 等用了再说

Technorati 标签: , , ,

git

星期六, 10月 4th, 2008

git是一种分布式的版本控制软件。前段时间完成GSoC的时候用过一段时间,非常强悍!下面是一些资源以及一些常用的命令。

 

Resources

  • 中文教程

http://www.bitsun.com/documents/gittutorcn.htm

  • gitHub上的guide (强列推荐)基本上你想问的问题都有了

http://github.com/guides/Home

  • 上面的精简版

http://www.sourcemage.org/Git_Guide

  • Kernel Hackers’ Guide to git

http://linux.yyz.us/git-howto.html 最后,最重要的还有官方文档。

 

Useful Commands

Day of GIT

    $ git clone http://xxx
    $ git branch gsoc           # new branch
    $ git log #浏览历史
    $ git show 12798172e98f1    #显示相应的版本
    $ git-tag old 12798172e98f1 #为版本命名
    $ git diff a..old a..gsoc   #比较两个版本

 

Revert

回到上次的commit状态(撤除现有的所有修改) $ git reset –hard 回到某个commit状态 $ git revert $id

 

Merge

合并两个branch $ git merge $id

 

remote

push一个branch [code]$ git push origin branch-name[/code]

删除一个branch [code]$ git push origin :branch-name[/code]

Misc

这样一个场景

        repos in web
        /               \
repos1          repos2
 |
 branch-my

现在要把原来在branch-my移到repos2下,可以通过patch来完成。

To Be Continued…