$HOME/.bashrc 追加下面的函数,这样就可以直接在代码下面使用 hoge-cscope 生成对应的 cscope 索引文件。


function hoge-cscope {
    find . -name "*.[chsS]" |grep  -v "\.pc"> cscope.files
    cscope -b -icscope.files
}