add coc_update.sh for linux

This commit is contained in:
Le Tan 2020-11-29 22:29:08 +08:00
parent 9a5e8693f4
commit fb9962d013
2 changed files with 30 additions and 0 deletions

30
scripts/coc_update.sh Executable file
View File

@ -0,0 +1,30 @@
#!/bin/sh
if [ -n "$1" ]; then
echo Qt include directory: $1
else
echo Please specify the Qt include directory.
exit
fi
ccls_file=".ccls"
echo clang > $ccls_file
echo -fcxx-exceptions >> $ccls_file
echo -std=c++14 >> $ccls_file
echo -Isrc/core >> $ccls_file
echo -Isrc >> $ccls_file
echo -Ilibs/vtextedit/src/editor/include >> $ccls_file
echo -Ilibs/vtitlebar/src >> $ccls_file
echo -I$1 >> $ccls_file
echo -I$1/QtCore >> $ccls_file
echo -I$1/QtWebEngineWidgets >> $ccls_file
echo -I$1/QtSvg >> $ccls_file
echo -I$1/QtPrintSupport >> $ccls_file
echo -I$1/QtWidgets >> $ccls_file
echo -I$1/QtWebEngineCore >> $ccls_file
echo -I$1/QtGui >> $ccls_file
echo -I$1/QtWebChannel >> $ccls_file
echo -I$1/QtNetwork >> $ccls_file
echo -I$1/QtTest >> $ccls_file
cp -f .ccls compile_flags.txt