Vim: Difficulty setting up ctags. Source in subdirectories don't see tags file in project root

后端 未结 5 1037
伪装坚强ぢ
伪装坚强ぢ 2021-01-29 19:25

I\'m trying to get setup with (exuberant) ctags on Vim today and am having difficulty getting it to work properly. I generate my ctags file on the command line with with:

<
5条回答
  •  既然无缘
    2021-01-29 19:45

    Create a .sh file with below code. And run .sh file where you want tags. That will work for sure.

    #!/bin/sh`enter code here`
    filelist=`mktemp`
    find . -name \*.h >> ${filelist}
    find . -name \*.c >> ${filelist}
    find . -name \*.cc >> ${filelist}
    find . -name \*.cpp >> ${filelist}
    find . -name \*.hpp >> ${filelist}
    if [ "$SDKTARGETSYSROOT" != "" ]; then
    find $SDKTARGETSYSROOT/usr/include -name \*.h >> ${filelist}
    fi
    cat ${filelist} | ctags -L -
    

提交回复
热议问题