scripts/gen-ctags.sh

17 lines
436 B
Bash
Executable File

#!/bin/sh
extract_ctags()
{
LIBRARY=$1
pacman -Ql $LIBRARY | grep -E -o '/usr/include/.*\.(h|hpp)' | grep -v "/usr/include/${LIBRARY}/typeof/" > ~/.vim/tags/$LIBRARY-filelist
ctags --sort=foldcase --c++-kinds=+p --fields=+iaS --extra=+q -f --language-force=C++ ~/.vim/tags/$LIBRARY -L ~/.vim/tags/$LIBRARY-filelist
}
echo "Generating CTAGS..."
#extract_ctags boost
#extract_ctags sdl2
#extract_ctags opencv
extract_ctags mesa