By Carlos J. Mazieri
The Qt Project Tool (qpt)
The "qpt" (Qt Project Tool) is a command line utility that aims to extract information
from Qt projects (qmake managed .pro files) making it easy to use project set of files and settings as input to
other command line tools.
As example other tools can be: Static Analyzers, Code Counters and others.
When "qpt" is used with Static Analyzer tools it also can work as a Qt Creator plugin,
making it easy and fast to change source code inside Qt Creator. In other hand qpt can also be used in
automated builds/tests like "Continuous Integration" tools.
So far it is known to work and comes configured for:
astyle http://astyle.sourceforge.net/astyle.html an Automatic Code Formatter
cloc http://cloc.sourceforge.net a Code Lines Counter
It was written for Qt and uses Qt of course, works with Qt4 or Qt5, see https://www.qt.io
To build on Unix/Linux:
$ cd qpt
$ qmake && make ## copy qpt to a suitable path
$ cd config && sh install.sh ## to install xml external tools for QtCreator, on Windows the installer does that.
## optional, build customized astyle
$ cd qpt
$ cd astyle_customized_for_Qt_and_cpplint
$ qmake && make ## copy astyle to a suitable path
Documentation is available in the "doc" directory:
Many thanks to J??rgen Quereng??sser <firstname.lastname@example.org> who did:
* modified the code in order to have 0.7 version working on Windows.
He also provided a compiled 0.7 Windows version.
Many thanks to Serhiy Moroz who did:
* added support for Project files TEMPLATE = subdirs in the 1.0 version.
Many thanks to Roman Telezhynskyi <email@example.com> who did:
* fixed a bug (version 1.1) related to when the Static Analyzer tool generates a big number of issues.
* provided a patch to support variables in the SUBDIRS projects (version 1.2)
* provided a patch to clean QtCreator issues pane before running a new cppecheck session (version 1.2)
Many thanks to philippe.foubert <firstname.lastname@example.org>
* provided a patch in Util::quoteWhenContainSpaces() from version 1.4 which generated version 1.5.
* provided pacthes to allow spaces in the command line for version 1.6